deploy: fix deploy script (#57) #8
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Deploy | |
on: | |
push: | |
branches: | |
- main | |
workflow_dispatch: | |
permissions: | |
id-token: write | |
contents: read | |
jobs: | |
release: | |
runs-on: ubuntu-latest | |
if: github.repository_owner == 'tilt-dev' | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Install dependencies | |
run: | | |
git submodule init | |
git submodule update | |
# Deploy api.tilt.dev | |
- name: Configure AWS credentials to access api.tilt.dev | |
uses: aws-actions/configure-aws-credentials@v3 | |
with: | |
role-to-assume: arn:aws:iam::710015040892:role/prod-collaboration-api.tilt.dev-20250228142654966700000001 | |
aws-region: us-east-1 | |
- name: Create website api.tilt.dev | |
run: | | |
make build-docs | |
- name: Deploy website api.tilt.dev | |
run: | | |
aws s3 sync build/docs s3://prod-collaboration-api.tilt.dev/ --region us-east-1 --delete | |
- name: Invalidate CloudFront cache for api.tilt.dev | |
run: | | |
aws cloudfront create-invalidation --distribution-id E2ZQJPGT02CCGI --paths "/*" |