Skip to content

deploy-auth

deploy-auth #2

Workflow file for this run

name: deploy-auth
on:
push:
branches:
- main
paths:
- "packages/auth/**"
workflow_dispatch:
inputs:
logLevel:
description: "Log level"
required: true
default: "debug"
type: choice
options:
- info
- warning
- debug
environment:
description: "Environment to run tests against"
type: environment
required: true
defaults:
run:
working-directory: packages/auth
jobs:
build:
runs-on: ubuntu-latest
environment:
name: ${{inputs.environment}}
env:
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
steps:
- uses: actions/checkout@master
- run: npm install
- run: npm run build
env:
PRODUCTION_DOMAIN: ${{ vars.PRODUCTION_DOMAIN }}
- name: Deploy
uses: jakejarvis/s3-sync-action@master
with:
args: --acl public-read --follow-symlinks --delete
env:
AWS_S3_BUCKET: ${{ vars.AWS_S3_BUCKET }}
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
AWS_REGION: ${{ vars.AWS_DEFAULT_REGION }}
SOURCE_DIR: "packages/auth/dist"
DEST_DIR: "auth/latest"