chore: align image labels with OCI image spec#437
Merged
Conversation
- Replace deprecated LABEL maintainer with org.opencontainers.image.authors.
- Add org.opencontainers.image.{vendor,documentation,base.name} in both
Dockerfiles' final stages — these aren't emitted by docker/metadata-action.
- Drop redundant LABEL maintainer from builder stages (only the final FROM's
labels reach the published image).
- Override the Nginx image's title/description in build-images.yml so it
stops inheriting the source-repo defaults; metadata-action's --label
flags win over Dockerfile LABELs, hence the workflow rather than the
Dockerfile.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
tuj
approved these changes
May 7, 2026
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
Brings the API and Nginx Dockerfiles into line with the OCI image spec, drops the deprecated
LABEL maintainer, and fixes the Nginx image's mislabeled title/description (which was inheritingdisplay-api-servicefrom the source repo).docker/metadata-action@v6already injects 8 of the 14 pre-definedorg.opencontainers.image.*keys at build time (title,description,url,source,version,created,revision,licenses). This PR adds the four it doesn't emit (authors,vendor,documentation,base.name) directly in the Dockerfiles, and overrides the Nginx-specifictitle/descriptionin the workflow becausemetadata-action's--labelflags win over DockerfileLABELs.Files Changed
infrastructure/display-api-service/Dockerfile— dropLABEL maintainerfromassets_builderandapi_app_builder(builder-stage labels never reach the published image); replace the final stage'sLABEL maintainerwith a consolidated OCI block.infrastructure/nginx/Dockerfile— same treatment,base.name=nginxinc/nginx-unprivileged:alpine..github/workflows/build-images.yml— add alabels:input to the Nginxmetadata-actionstep so the published Nginx image getstitle=display-api-service-nginxinstead of the source-repo default.CHANGELOG.md— entry under[Unreleased].Out of scope (intentional)
org.opencontainers.image.base.digest— meaningless until base images are pinned by digest (TODO already present in the API Dockerfile). Couple with that change.composer.jsonlicense vs.LICENSEfile mismatch (proprietaryvs. MPL-2.0).metadata-actionreads from GitHub so the published label is correct, but the source files disagree — separate triage.Test Plan
docker buildx build -f infrastructure/display-api-service/Dockerfile --build-context repository-root=. -t oci-check ./infrastructure/display-api-service/docker inspect oci-check --format '{{json .Config.Labels}}' | jq— expectorg.opencontainers.image.authors,vendor,documentation,base.namepresent; nomaintainer.base.name=nginxinc/nginx-unprivileged:alpine.ghcr.io/os2display/display-api-service-nginx:<branch-tag>and confirmtitle=display-api-service-nginx(notdisplay-api-service).🤖 Generated with Claude Code