Skip to content

Merge branch 'master' into develop #46

Merge branch 'master' into develop

Merge branch 'master' into develop #46

Workflow file for this run

name: Deploy to Beta
permissions:
id-token: write
contents: read
on:
workflow_dispatch:
push:
branches:
- 'develop'
jobs:
build:
runs-on: ubuntu-latest
environment: Beta
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Setup Node
uses: actions/setup-node@master
with:
node-version: '14'
- name: Configure AWS Credentials
uses: aws-actions/configure-aws-credentials@v1
with:
aws-region: ${{ secrets.AWS_REGION }}
aws-access-key-id: ${{ secrets.BETA_AWS_ACCESS_KEY_ID }}
aws-secret-access-key: ${{ secrets.BETA_AWS_SECRET_ACCESS_KEY }}
- name: set keys and deploy
env:
AWS_MAX_ATTEMPTS: 10
ALGOLIA_ADMIN_KEY: ${{secrets.ALGOLIA_ADMIN_KEY}}
DIST_ID: ${{secrets.BETA_DIST_ID}}
RELIC_ACCOUNT_ID: ${{secrets.RELIC_ACCOUNT_ID}}
RELIC_TRUST_KEY: ${{secrets.RELIC_TRUST_KEY}}
RELIC_AGENT_ID: ${{secrets.RELIC_AGENT_ID}}
RELIC_LICENSE_KEY: ${{secrets.RELIC_LICENSE_KEY}}
RELIC_APPLICATION_ID: ${{secrets.RELIC_APPLICATION_ID}}
PM_TECH: ${{secrets.PM_TECH}}
run: |
npm install
GATSBY_ACTIVE_ENV=development && npm run build
aws s3 sync ./public/ s3://${{secrets.BETA_BUCKET_NAME}}/ --delete
- name: invalidate the CDN
uses: chetan/invalidate-cloudfront-action@v2
env:
PATHS: '/*'
AWS_REGION: '${{ secrets.AWS_REGION }}'
DISTRIBUTION: ${{ secrets.BETA_DIST_ID }}
AWS_ACCESS_KEY_ID: ${{ secrets.BETA_AWS_ACCESS_KEY_ID }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.BETA_AWS_SECRET_ACCESS_KEY }}