From 850bf959708e460a5631fa38fe6f9a7d60611c62 Mon Sep 17 00:00:00 2001 From: Ricardo Pinto Date: Fri, 6 Jun 2025 16:37:03 +0100 Subject: [PATCH] Changed ci/cd to support second pub/sub topic ref https://linear.app/ghost/issue/PROD-1953 - Changed ci/cd to support the second pub/sub topic. Includes deployments to two new services: ghost-queue and fedify-queue. --- .github/workflows/cicd.yml | 43 +++++++++++++++++++++++++++++++++++++- 1 file changed, 42 insertions(+), 1 deletion(-) diff --git a/.github/workflows/cicd.yml b/.github/workflows/cicd.yml index f098e0336..db034db21 100644 --- a/.github/workflows/cicd.yml +++ b/.github/workflows/cicd.yml @@ -306,7 +306,8 @@ jobs: export TF_VAR_primary_region_name=netherlands export TF_VAR_migrations_image=europe-docker.pkg.dev/ghost-activitypub/activitypub/migrations:pr-${{ github.event.pull_request.number }} export TF_VAR_api_image=europe-docker.pkg.dev/ghost-activitypub/activitypub/activitypub:pr-${{ github.event.pull_request.number }} - export TF_VAR_queue_image=europe-docker.pkg.dev/ghost-activitypub/activitypub/activitypub:pr-${{ github.event.pull_request.number }} + export TF_VAR_fedify_queue_image=europe-docker.pkg.dev/ghost-activitypub/activitypub/activitypub:pr-${{ github.event.pull_request.number }} + export TF_VAR_ghost_queue_image=europe-docker.pkg.dev/ghost-activitypub/activitypub/activitypub:pr-${{ github.event.pull_request.number }} terraform apply -auto-approve - name: "Deploy Migrations to Cloud Run" @@ -439,6 +440,26 @@ jobs: labels: |- commit-sha=${{ github.sha }} + - name: "Deploy ActivityPub Fedify Queue to Cloud Run" + uses: google-github-actions/deploy-cloudrun@v2 + with: + image: europe-docker.pkg.dev/ghost-activitypub/activitypub/activitypub:${{ needs.build-test-push.outputs.activitypub_docker_version }} + region: ${{ matrix.region }} + service: stg-${{ matrix.region_name }}-activitypub-fedify-queue + skip_default_labels: true + labels: |- + commit-sha=${{ github.sha }} + + - name: "Deploy ActivityPub Ghost Queue to Cloud Run" + uses: google-github-actions/deploy-cloudrun@v2 + with: + image: europe-docker.pkg.dev/ghost-activitypub/activitypub/activitypub:${{ needs.build-test-push.outputs.activitypub_docker_version }} + region: ${{ matrix.region }} + service: stg-${{ matrix.region_name }}-activitypub-ghost-queue + skip_default_labels: true + labels: |- + commit-sha=${{ github.sha }} + - name: "Deploy ActivityPub Queue to Cloud Run" uses: google-github-actions/deploy-cloudrun@v2 with: @@ -503,6 +524,26 @@ jobs: labels: |- commit-sha=${{ github.sha }} + - name: "Deploy ActivityPub Fedify Queue to Cloud Run" + uses: google-github-actions/deploy-cloudrun@v2 + with: + image: europe-docker.pkg.dev/ghost-activitypub/activitypub/activitypub:${{ needs.build-test-push.outputs.activitypub_docker_version }} + region: ${{ matrix.region }} + service: prd-${{ matrix.region_name }}-activitypub-fedify-queue + skip_default_labels: true + labels: |- + commit-sha=${{ github.sha }} + + - name: "Deploy ActivityPub Ghost Queue to Cloud Run" + uses: google-github-actions/deploy-cloudrun@v2 + with: + image: europe-docker.pkg.dev/ghost-activitypub/activitypub/activitypub:${{ needs.build-test-push.outputs.activitypub_docker_version }} + region: ${{ matrix.region }} + service: prd-${{ matrix.region_name }}-activitypub-ghost-queue + skip_default_labels: true + labels: |- + commit-sha=${{ github.sha }} + - name: "Deploy ActivityPub Queue to Cloud Run" uses: google-github-actions/deploy-cloudrun@v2 with: