Skip to content

ci: build and push production image via GitHub Actions#349

Merged
oioki merged 1 commit into
masterfrom
alextarasov/reload-gha-image-build
Jun 15, 2026
Merged

ci: build and push production image via GitHub Actions#349
oioki merged 1 commit into
masterfrom
alextarasov/reload-gha-image-build

Conversation

@oioki

@oioki oioki commented Jun 15, 2026

Copy link
Copy Markdown
Member

Build the reload production image in GitHub Actions instead of Cloud Build.

Cloud Build cannot unpack the dhi-mirror (Docker Hardened Image) base layers and fails with archive/tar: invalid tar header. This builds the image with BuildKit via getsentry/action-build-and-push-images — the same path vroom/snuba/release-registry already took.

The action tags with the full github.sha, which is exactly what GoCD deploys by (GO_REVISION_RELOAD_REPO), and pushes to both registries:

  • us-central1-docker.pkg.dev/sentryio/reload/image (single-region, what GoCD deploys from today)
  • us-docker.pkg.dev/sentryio/reload-mr/image (multi-region mirror)

Auth uses the gha-gcr-push service account via Workload Identity Federation, authorized in getsentry/security-as-code#3128 (merged + applied).

This intentionally lands while Cloud Build is still authoritative so the new build can be verified in parallel — GoCD still gates on the Cloud Build check until the follow-up PR switches it over. After merge, confirm the workflow pushes …/reload/image:<sha> and …/reload-mr/image:<sha> before merging the GoCD gate flip.

Cloud Build cannot unpack the dhi-mirror (Docker Hardened Image) base
layers and fails with "archive/tar: invalid tar header". Build the
image in GitHub Actions instead, using BuildKit via
getsentry/action-build-and-push-images (the same path vroom/snuba took).

The action tags with the full github.sha, matching what GoCD deploys by
(GO_REVISION_RELOAD_REPO), and pushes to both the single-region registry
GoCD currently deploys from and the multi-region mirror.

This lands while Cloud Build is still authoritative so the new build can
be verified in parallel; the GoCD gate is switched over in a follow-up.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Comment thread .github/workflows/image.yml Outdated
Comment thread .github/workflows/image.yml Outdated
@oioki oioki force-pushed the alextarasov/reload-gha-image-build branch from f5751ea to 041dadc Compare June 15, 2026 22:36
@oioki oioki requested a review from a team June 15, 2026 22:41
@oioki oioki merged commit 8909834 into master Jun 15, 2026
26 checks passed
@oioki oioki deleted the alextarasov/reload-gha-image-build branch June 15, 2026 22:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants