Skip to content

New Crowdin updates (#104) #312

New Crowdin updates (#104)

New Crowdin updates (#104) #312

Workflow file for this run

name: GitHub Pages
on:
push:
branches:
- main
env:
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
AWS_DEFAULT_REGION: "us-east-1"
jobs:
deploy:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Setup Node.js
uses: actions/setup-node@v2
with:
node-version: '16'
- name: Install dependencies
run: npm install
- name: Build
run: npm run build:prod
- name: Deploy
run: aws s3 rm s3://${{ secrets.AWS_S3_BUCKET_NAME }} --recursive && aws s3 sync ./dist/zapddit/ s3://${{ secrets.AWS_S3_BUCKET_NAME }}
- name: "Create AWS Cloudfront Invalidation"
run: aws cloudfront create-invalidation --distribution-id ${{ secrets.AWS_CLOUDFRONT_DISTRIBUTION_ID }} --paths "/*"
# - name: Deploy
# if: success()
# uses: peaceiris/actions-gh-pages@v3
# with:
# github_token: ${{ secrets.ZAPPEDIT_TOKEN }}
# publish_dir: dist/zapddit
# enable_jekyll: true