Skip to content

Commit

Permalink
ci: Deploy main on approval
Browse files Browse the repository at this point in the history
  • Loading branch information
oliversalzburg committed Nov 23, 2023
1 parent 12119ea commit 1a7bada
Show file tree
Hide file tree
Showing 2 changed files with 36 additions and 1 deletion.
34 changes: 34 additions & 0 deletions .github/workflows/infra-deploy.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
name: Deploy Infrastructure

on:
push:
branches:
- main

permissions:
contents: read
id-token: write

jobs:
deploy:
environment:
name: Production
url: https://kitten-science.com
runs-on: ubuntu-22.04
steps:
- name: Checkout
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4

- name: Configure AWS credentials
uses: aws-actions/configure-aws-credentials@010d0da01d0b5a38af31e9c3470dbfdabdecca3a # v4
with:
role-to-assume: arn:aws:iam::022327457572:role/ks-infrastructure-maintainer
aws-region: eu-west-1

- name: Terraform Init
run: terraform init
working-directory: terraform

- name: Terraform Apply
run: terraform apply -auto-approve
working-directory: terraform
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
name: Deploy Infrastructure
name: QA

on:
push:
branches:
- main
- renovate/*

permissions:
contents: read
Expand Down

0 comments on commit 1a7bada

Please sign in to comment.