Skip to content

Commit 53ff8d3

Browse files
feat(ci): Phase 1: Cutover to gha for prod images (#471)
* publish to ar from gha
1 parent 761160b commit 53ff8d3

File tree

1 file changed

+44
-0
lines changed

1 file changed

+44
-0
lines changed

.github/workflows/image.yml

Lines changed: 44 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -61,6 +61,50 @@ jobs:
6161
ghcr.io/getsentry/taskbroker:${{ github.event.pull_request.head.sha || github.sha }}-amd64 \
6262
ghcr.io/getsentry/taskbroker:${{ github.event.pull_request.head.sha || github.sha }}-arm64
6363
64+
build-production:
65+
runs-on: ubuntu-24.04
66+
if: github.ref_name == github.event.repository.default_branch
67+
name: Build and push production images
68+
permissions:
69+
contents: read
70+
id-token: write
71+
steps:
72+
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
73+
74+
- name: Build and push taskbroker image
75+
uses: getsentry/action-build-and-push-images@a53f146fc1ea3cb404f2dcf7378f5b60dd98d3ca
76+
with:
77+
image_name: 'taskbroker'
78+
platforms: linux/amd64
79+
dockerfile_path: './Dockerfile'
80+
build_args: TASKBROKER_GIT_REVISION=${{ github.sha }}
81+
ghcr: false
82+
google_ar: true
83+
tag_nightly: false
84+
tag_latest: true
85+
# TODO: remove this once we cut over GoCD to using gha for prod images
86+
tag_suffix: -gha
87+
google_ar_image_name: us-central1-docker.pkg.dev/sentryio/taskbroker/image
88+
google_workload_identity_provider: projects/868781662168/locations/global/workloadIdentityPools/prod-github/providers/github-oidc-pool
89+
google_service_account: gha-gcr-push@sac-prod-sa.iam.gserviceaccount.com
90+
91+
- name: Build and push taskworker image
92+
uses: getsentry/action-build-and-push-images@a53f146fc1ea3cb404f2dcf7378f5b60dd98d3ca
93+
with:
94+
image_name: 'taskworker'
95+
platforms: linux/amd64
96+
dockerfile_path: './python/Dockerfile'
97+
build_context: './python'
98+
ghcr: false
99+
google_ar: true
100+
tag_nightly: false
101+
tag_latest: true
102+
# TODO: remove this once we cut over GoCD to using gha for prod images
103+
tag_suffix: -gha
104+
google_ar_image_name: us-central1-docker.pkg.dev/sentryio/taskworker/image
105+
google_workload_identity_provider: projects/868781662168/locations/global/workloadIdentityPools/prod-github/providers/github-oidc-pool
106+
google_service_account: gha-gcr-push@sac-prod-sa.iam.gserviceaccount.com
107+
64108
self-hosted-end-to-end:
65109
needs: [assemble-taskbroker-image]
66110
runs-on: ubuntu-latest

0 commit comments

Comments
 (0)