aboutsummaryrefslogtreecommitdiffstats
path: root/.github/workflows/deploy.yml
diff options
context:
space:
mode:
authorAlex <git@ajschof.me>2024-09-03 16:07:37 +0100
committerGitHub <noreply@github.com>2024-09-03 16:07:37 +0100
commitce30178558cc8222e9975273eb5d08a93ae92fcc (patch)
tree4152f9efe54364a5d6a6cc969befb6cea9015a5b /.github/workflows/deploy.yml
parente4e360630c90d7e801d99097b3e46e8299ab901d (diff)
parent3b8e89968e3d3d3527ea76b4517b0d7278512530 (diff)
downloadde-project-bentley-ce30178558cc8222e9975273eb5d08a93ae92fcc.tar.gz
de-project-bentley-ce30178558cc8222e9975273eb5d08a93ae92fcc.zip
Merge branch 'development' into test/tests_transform_lambda
Diffstat (limited to '.github/workflows/deploy.yml')
-rw-r--r--.github/workflows/deploy.yml42
1 files changed, 42 insertions, 0 deletions
diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml
new file mode 100644
index 0000000..5672048
--- /dev/null
+++ b/.github/workflows/deploy.yml
@@ -0,0 +1,42 @@
+name: deploy-terraform
+
+on:
+ pull_request:
+ branches:
+ - main
+ push:
+ branches:
+ - main
+
+
+jobs:
+ deploy-terraform:
+ name: Deploy Terraform
+ runs-on: ubuntu-latest
+ #needs: run-checks (must ref on-commit.yml file)
+ environment: production
+ steps:
+ - name: Checkout Repo
+ uses: actions/checkout@v4
+
+ - name: Install Terraform
+ uses: hashicorp/setup-terraform@v3
+
+ - name: Configure AWS Credentials
+ uses: aws-actions/configure-aws-credentials@v4
+ with:
+ aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }}
+ aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
+ aws-region: ${{ secrets.AWS_REGION }}
+
+ - name: Terraform Init
+ working-directory: terraform
+ run: terraform init
+
+ - name: Terraform Plan
+ working-directory: terraform
+ run: terraform plan
+
+ - name: Terraform Apply
+ working-directory: terraform
+ run: terraform apply --auto-approve
git.ajschof.me — hosted by ajschofield — powered by cgit