Skip to content

Commit

Permalink
Trigger TF (#224)
Browse files Browse the repository at this point in the history
This should trigger a change in TF/testnet on a successful build of `main`.


Fixes #201
  • Loading branch information
mkysel authored Oct 15, 2024
1 parent 53e0598 commit 02c16df
Showing 1 changed file with 23 additions and 0 deletions.
23 changes: 23 additions & 0 deletions .github/workflows/build-xmtpd.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,8 @@ jobs:
packages: write
env:
DOCKER_METADATA_PR_HEAD_SHA: true
outputs:
digest: ${{ steps.push.outputs.digest }}
steps:
- name: Checkout
uses: actions/checkout@v4
Expand Down Expand Up @@ -48,3 +50,24 @@ jobs:
tags: ${{ steps.meta.outputs.tags }}
labels: ${{ steps.meta.outputs.labels }}
build-args: "GIT_COMMIT=${{ github.event_name != 'pull_request' && github.sha || github.event.pull_request.head.sha }}"

deploy:
name: Deploy new images to infra
runs-on: ubuntu-latest
needs: push_to_registry
if: github.ref == 'refs/heads/main'
steps:
- name: Print Digest
id: print
run: echo "digest ${{ needs.push_to_registry.outputs.digest }}"
- name: Deploy (dev)
uses: xmtp-labs/terraform-deployer@v1
timeout-minutes: 45
with:
timeout: 45m
terraform-token: ${{ secrets.TERRAFORM_TOKEN }}
terraform-org: xmtp
terraform-workspace: testnet
variable-name: xmtpd_server_docker_image
variable-value: "ghcr.io/xmtp/xmtpd@${{ needs.push_to_registry.outputs.digest }}"
variable-value-required-prefix: "ghcr.io/xmtp/xmtpd@sha256:"

0 comments on commit 02c16df

Please sign in to comment.