Skip to content

Merge pull request #26 from devblin/main #24

Merge pull request #26 from devblin/main

Merge pull request #26 from devblin/main #24

Workflow file for this run

name: Deploy
on:
push:
branches:
- production
jobs:
deploy:
runs-on: ubuntu-latest
environment: production
env:
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
TF_VAR_AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
TF_VAR_AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
TF_VAR_ENV: ${{ vars.ENV }}
steps:
- name: Checkout code
uses: actions/checkout@v2
- name: Setup terraform
uses: hashicorp/setup-terraform@v1
- name: Initialise terraform
run: |
terraform init
- name: Validate terraform
run: |
terraform validate
- name: Apply terraform
run: |
terraform apply -auto-approve