-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Update docs to reflect change, rename
terraform-iac/
to terraform/
Docs needed to be updated either way. I know we've done some bikeshedding on the directory name before. I didn't previously care whether it was called terraform/, iac/, terraform-iac/ or anything else. Nowadays, I have a tiny reason to prefer the name terraform/: it plays nicely with automatic folder icons. The other options don't.
- Loading branch information
Showing
21 changed files
with
20 additions
and
21 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -5,11 +5,11 @@ on: | |
branches: [dev, stg, prd] | ||
types: [opened, reopened, synchronize, edited] | ||
paths: | ||
- 'terraform-iac/**' | ||
- 'terraform/**' | ||
- '.github/workflows/ci-iac.yml' | ||
|
||
env: | ||
tf_version: "1.7.0" # must match value in terraform-iac/app/main.tf | ||
tf_version: "1.7.0" # must match value in terraform/app/main.tf | ||
|
||
jobs: | ||
env: | ||
|
@@ -80,7 +80,7 @@ jobs: | |
terraform_version: ${{ env.tf_version }} | ||
|
||
- name: Terraform Format | ||
working-directory: terraform-iac | ||
working-directory: terraform | ||
run: terraform fmt -check -recursive | ||
|
||
plan: | ||
|
@@ -112,26 +112,26 @@ jobs: | |
terraform_version: ${{ env.tf_version }} | ||
|
||
- name: Terraform Init | ||
working-directory: terraform-iac/app | ||
working-directory: terraform/app | ||
run: terraform init -backend-config=${{ matrix.env.environment_name }}.s3.tfbackend | ||
|
||
- name: Terraform Plan | ||
working-directory: terraform-iac/app | ||
working-directory: terraform/app | ||
run: terraform plan -var-file=${{ matrix.env.environment_name }}.tfvars -var 'image_tag=ci_test' -input=false -out plan -lock=false | ||
|
||
- name: Comment Terraform Plan | ||
uses: byu-oit/github-action-tf-plan-comment@v1 | ||
with: | ||
github-token: ${{ secrets.GITHUB_TOKEN }} | ||
working-directory: terraform-iac/app | ||
working-directory: terraform/app | ||
terraform-plan-file: plan | ||
|
||
- name: Analyze Terraform Plan | ||
uses: byu-oit/github-action-tf-plan-analyzer@v2 | ||
if: github.repository_owner == 'byu-oit' | ||
# If you're at BYU, but outside the byu-oit GitHub org, you may be able to obtain credentials by contacting [email protected] | ||
with: | ||
working-directory: terraform-iac/app | ||
working-directory: terraform/app | ||
terraform-plan-file: plan | ||
divvycloud-username: ${{ secrets.DIVVYCLOUD_USERNAME }} | ||
divvycloud-password: ${{ secrets.DIVVYCLOUD_PASSWORD }} | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -10,7 +10,7 @@ on: | |
- '.gitignore' | ||
env: | ||
node_version: "18.x" | ||
tf_version: "1.7.0" # must match value in terraform-iac/app/main.tf | ||
tf_version: "1.7.0" # must match value in terraform/app/main.tf | ||
FORCE_COLOR: 3 | ||
concurrency: ${{ github.ref }} | ||
jobs: | ||
|
@@ -183,7 +183,7 @@ jobs: | |
terraform_version: ${{ env.tf_version }} | ||
|
||
- name: Terraform Format | ||
working-directory: terraform-iac | ||
working-directory: terraform | ||
run: terraform fmt -check -recursive | ||
|
||
build_and_deploy: | ||
|
@@ -242,19 +242,19 @@ jobs: | |
terraform_wrapper: false | ||
|
||
- name: Terraform Init | ||
working-directory: terraform-iac/app | ||
working-directory: terraform/app | ||
run: terraform init -backend-config=${{ matrix.env.environment_name }}.s3.tfbackend | ||
|
||
- name: Terraform Plan | ||
working-directory: terraform-iac/app | ||
working-directory: terraform/app | ||
run: terraform plan -var-file=${{ matrix.env.environment_name }}.tfvars -var 'image_tag=${{ steps.date.outputs.timestamp }}' -input=false -out=plan | ||
|
||
- name: Analyze Terraform Plan | ||
uses: byu-oit/github-action-tf-plan-analyzer@v2 | ||
if: github.repository_owner == 'byu-oit' | ||
# If you're at BYU, but outside the byu-oit GitHub org, you may be able to obtain credentials by contacting [email protected] | ||
with: | ||
working-directory: terraform-iac/app | ||
working-directory: terraform/app | ||
terraform-plan-file: plan | ||
divvycloud-username: ${{ secrets.DIVVYCLOUD_USERNAME }} | ||
divvycloud-password: ${{ secrets.DIVVYCLOUD_PASSWORD }} | ||
|
@@ -268,12 +268,12 @@ jobs: | |
template-id: ${{ matrix.env.rfc_template_id }} | ||
|
||
- name: Terraform Apply | ||
working-directory: terraform-iac/app | ||
working-directory: terraform/app | ||
run: terraform apply plan | ||
|
||
- name: Get Terraform Outputs | ||
id: terraform-outputs | ||
working-directory: terraform-iac/app | ||
working-directory: terraform/app | ||
run: | | ||
echo "codedeploy_app_name=$(terraform output -raw codedeploy_app_name)" >> $GITHUB_OUTPUT | ||
echo "codedeploy_deployment_group_name=$(terraform output -raw codedeploy_deployment_group_name)" >> $GITHUB_OUTPUT | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.