Skip to content

Tests

Tests #16

Workflow file for this run

name: Deploy
# Runs when "Tests" workflow completes successfully
on:
workflow_run:
workflows: [ "Tests" ]
types:
- completed
jobs:
deploy-dev:
if: ${{ github.event.workflow_run.conclusion == 'success' }}
runs-on: ubuntu-latest
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
DEFAULT_SENTRY_DSN: ${{ secrets.DEFAULT_SENTRY_DSN }}
DEFAULT_TELEGRAM_TOKEN: ${{ secrets.DEFAULT_TELEGRAM_TOKEN }}
DEFAULT_VARS_FILE: tf/default.tfvars
steps:
- name: Checkout repo
uses: actions/checkout@v2
- name: Create tfvars files
run: |
echo "sentry_dsn = \"${DEFAULT_SENTRY_DSN}\"" > ${DEFAULT_VARS_FILE}
echo "telegram_token = \"${DEFAULT_TELEGRAM_TOKEN}\"" >> ${DEFAULT_VARS_FILE}
- name: Deploy service to AWS
run: |
make install-ci
cd tf; terraform init
make deploy