Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 8 additions & 3 deletions .github/workflows/release-ghcr-version-tag.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,13 +16,18 @@ jobs:
password: ${{ secrets.GITHUB_TOKEN }}

- name: Tag release version
env:
REF_NAME: ${{ github.ref_name }}
GITHUB_SHA: ${{ github.sha }}

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reserved GITHUB_SHA variable cannot be overridden in env

Low Severity

GITHUB_SHA is a reserved default environment variable in GitHub Actions, and GitHub's docs state that GITHUB_* variables cannot be overwritten. The env: GITHUB_SHA declaration may be silently ignored, with $GITHUB_SHA in the run block resolving to the built-in default instead. This happens to have the same value for release events, so no breakage occurs today, but the override is misleading. A non-reserved name like COMMIT_SHA would be more reliable and accurate.

Additional Locations (1)
Fix in Cursor Fix in Web

Reviewed by Cursor Bugbot for commit b21b06a. Configure here.

run: |
docker buildx imagetools create --tag \
ghcr.io/getsentry/chartcuterie:${{ github.ref_name }} \
ghcr.io/getsentry/chartcuterie:${{ github.sha }}
ghcr.io/getsentry/chartcuterie:"$REF_NAME" \
ghcr.io/getsentry/chartcuterie:"$GITHUB_SHA"

- name: Tag latest version
env:
GITHUB_SHA: ${{ github.sha }}
run: |
docker buildx imagetools create --tag \
ghcr.io/getsentry/chartcuterie:latest \
ghcr.io/getsentry/chartcuterie:${{ github.sha }}
ghcr.io/getsentry/chartcuterie:"$GITHUB_SHA"
Loading