FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

CORE-4588 - add deployment labels to docker image by monotek · Pull Request #155 · Staffbase/gitops-github-action · GitHub

CORE-4588 - add deployment labels to docker image - #155

Merged
monotek merged 1 commit into
mainfrom
docker-labels
Aug 6, 2026
Merged

CORE-4588 - add deployment labels to docker image#155
monotek merged 1 commit into
mainfrom
docker-labels

Conversation

monotek commented Jul 10, 2026
edited
Loading

Copy link
Copy Markdown
Member

Type of Change

  • Bugfix
  • Enhancement / new feature
  • Refactoring
  • Documentation

Description

Deployment-tracking image labels + configurable metadata namespace

Adds deployment-tracking labels on the built Docker image, mirroring the existing GitOps manifest annotations, and makes both independently toggleable and their key namespace configurable.

What changed
  • New deployment-labels input (default true): stamps com.staffbase.deploy.repositoryFullName / commitSha / version onto the built image, using the same values as the annotations.
  • New deployment-annotations input (default true): the existing annotation behavior, now opt-out.
  • New deployment-domain input (default deploy.staffbase.com): single source of truth for the key namespace — applied verbatim to annotation keys (<domain>/…) and reversed to reverse-DNS for label keys (com.staffbase.deploy.…).
Implementation
  • reverse_domain helper in common.sh; dedicated generate-label-prefix.sh + step (keeps generate-tags.sh tag-only).
  • Labels gated per-line in the Build step expression; annotations gated in gitops-functions.sh.
Notes
  • Labels are baked in at build time, so release/custom retag runs keep the source branch build's labels.
  • 95/95 bats tests pass (+7), shellcheck clean.

Docs updated in README.md.

Checklist

  • Write tests
  • Make sure all tests pass
  • Update documentation
  • Review the Contributing Guideline and sign CLA
  • Reference relevant issue(s) and close them after merging

Signed-off-by: André Bauer <andre.bauer@staffbase.com>
monotek marked this pull request as ready for review August 5, 2026 15:16
monotek requested review from a team as code owners August 5, 2026 15:16
monotek merged commit 863665d into main Aug 6, 2026
10 checks passed
monotek deleted the docker-labels branch August 6, 2026 11:15
github-actions Bot locked and limited conversation to collaborators Aug 6, 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 subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants


Back | FazBrowse Home | New Git URL