Update deploy.yml #3
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 sitaraa.html to S3 + CloudFront | |
| on: | |
| push: | |
| branches: | |
| - main | |
| jobs: | |
| deploy: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@v4 | |
| - name: Configure AWS credentials (Access Keys) | |
| uses: aws-actions/configure-aws-credentials@v4 | |
| with: | |
| aws-access-key-id: ${{ secrets.ACCESS_KEY_ID }} | |
| aws-secret-access-key: ${{ secrets.SECRET_ACCESS_KEY }} | |
| aws-region: us-east-1 | |
| - name: Upload sitaraa.html to S3 | |
| run: | | |
| aws s3 cp sitaraa.html s3://siddharth-gupta-test/sitaraa.html \ | |
| --cache-control "max-age=0,no-cache,no-store,must-revalidate" \ | |
| --content-type "text/html" | |
| - name: Invalidate CloudFront cache | |
| run: | | |
| aws cloudfront create-invalidation \ | |
| --distribution-id E3AI1EJPXOOK6Z \ | |
| --paths "/*" |