build: clear the Dockerfile build-check warnings - #6768
Merged
Conversation
A FROM instruction already resolves to $TARGETPLATFORM, so pinning it explicitly is a no-op that trips the RedundantTargetPlatform check in the image build. The multi-arch build still resolves runtime-utils to the target architecture.
The legacy "ENV key value" form is deprecated and reported by the LegacyKeyValueFormat build check.
|
Claude finished @otavio's task in 46s —— View job Code Review CompleteReviewed 3 files across code quality, security, testing, language patterns, and architecture — no new issues found. The code looks good as-is. Verified the key correctness claim: dropping To request another review round, comment |
otavio
enabled auto-merge (rebase)
July 30, 2026 15:08
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.
Description
CI surfaced a
RedundantTargetPlatformwarning on the agent image build. Runningdocker build --checkacross every Dockerfile in the repo turned up two more instances of a second warning, so this clears all of them.Two commits, one per warning type:
build(agent): drop the redundant target platform on the runtime stage—FROMalready resolves to$TARGETPLATFORM, soFROM --platform=$TARGETPLATFORMis a no-op. Dropped it along with the two comments that only restated it.build: use the key=value form for ENV instructions— replaces the deprecatedENV key valueform inagent/,openapi/, andui/.Testing
docker build --checkreports "no warnings found" for all three changed files;cli/,server/, andgateway/were already clean.No behavior change:
build-agent.ymlpasses--platformexplicitly to everybuildx build(the amd64 scan build, the 5-arch push, and the per-arch rootfs export), andruntime-utilsstill resolves to the target architecture in each.trivy-imagematrix insecurity.ymlbuilds without aplatforms:input, so it targets the runner platform as before.ENV k=vis semantically identical toENV k v, so theGOPROXY/NPM_CONFIG_REGISTRYbuild args passed by compose and CI are unaffected.Notes
agent/Dockerfile.teststill tripsSecretsUsedInArgOrEnvon itsARG PASSWORD. That is a deliberate throwaway credential for the test image, which no workflow builds, so it is left as-is.