Skip to content

Commit

Permalink
Add automated github deployments again
Browse files Browse the repository at this point in the history
  • Loading branch information
Jumbub committed May 9, 2023
1 parent 6d1a349 commit 6ad9fd5
Showing 1 changed file with 27 additions and 0 deletions.
27 changes: 27 additions & 0 deletions .github/workflows/master.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
name: Master pipeline

on:
push:
branches:
- master

jobs:
test-and-deploy:
runs-on: ubuntu-latest
name: Test and deploy
steps:
- name: Checkout branch
uses: actions/checkout@v2

- name: Configure AWS credentials
uses: aws-actions/configure-aws-credentials@v1
with:
aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }}
aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
aws-region: ap-southeast-2

- name: Upload to S3
run: aws s3 sync . s3://jamiebray-ui --delete

- name: Invalidate CloudFront cache
run: aws cloudfront create-invalidation --distribution-id ${{ secrets.AWS_CLOUDFRONT_DISTRIBUTION }} --paths "/*"

0 comments on commit 6ad9fd5

Please sign in to comment.