Added French & Spanish Translations #20
This file contains 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 Front end in S3 | |
on: | |
push: | |
branches: | |
- main | |
paths: | |
- web/** | |
jobs: | |
deploy_front_end: | |
runs-on: ubuntu-latest | |
env: | |
REACT_APP_BACKEND: https://api.carbreg.org | |
REACT_APP_COUNTRY_NAME: 'UNDP Digital Public Good National' | |
REACT_APP_COUNTRY_FLAG_URL: 'https://carbon-common-prod.s3.amazonaws.com/flag.png' | |
COUNTRY_CODE: 'NG' | |
REACT_APP_MAPBOXGL_ACCESS_TOKEN: ${{ secrets.MAPBOXGL_ACCESS_TOKEN }} | |
REACT_APP_MAP_TYPE : "Mapbox" | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Cache modules | |
uses: actions/cache@v1 | |
id: yarn-cache | |
with: | |
path: node_modules | |
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }} | |
restore-keys: ${{ runner.os }}-yarn- | |
- 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: us-east-1 | |
- name: Use Node.js ${{ matrix.node-version }} | |
uses: actions/setup-node@v3 | |
with: | |
node-version: ${{ matrix.node-version }} | |
- name: Install dependencies | |
working-directory: ./web | |
run: CI=false yarn | |
- name: Build | |
working-directory: ./web | |
run: CI=false yarn build | |
- name: Deploy | |
run: aws s3 sync ./web/build s3://carbon-www-prod |