feat(build): expose env_required/env_optional in build-manifest.json#259
Merged
Conversation
CI deploy tooling needs the structured env-var union (skills + channels + model provider) that already feeds secrets.yaml, without scraping YAML comments. Emit it from the same AgentSpec.Requirements lists.
a4d9ef9 to
287c527
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
forge buildnow writes the image's declared env-var union (env_required/env_optional) intobuild-manifest.json, sourced from the sameAgentSpec.Requirementslists that already feedsecrets.yaml.tmpl— skills'requirements.env∪ channel env vars ∪ model-provider keys.Why
CI deploy tooling (the new
initializCLI, initializ/cli-next) needs the structured env contract of the image it just built, to preflight required-var coverage before deploying. Today the only machine-readable trace isk8s/secrets.yaml, where required-vs-optional is encoded as a# optionalYAML comment — not parseable robustly. The manifest stage runs after AgentSpecStage/K8sStage, so the data is already onbc.Spec.Requirements; this is a pure addition to the manifest map.Testing
go test ./forge-cli/build/— newTestManifestStage_EnvRequirements+ existing suite passgolangci-lint run ./forge-cli/build/...— 0 issues🤖 Generated with Claude Code