Merge branch 'develop' into 3157-reparse-meta-additions #213
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
########################################################################### | |
# GitHub Action Workflow | |
# On push changing terraform files or infrastructure pipelines, triggers the | |
# terraform deploy pipeline for the appropriate cf space. | |
# | |
# Step 0: make changes to non-documentation files in terraform/ or | |
# .circleci/infrastructure/ and push/merge changes. | |
# | |
# Step 1: Makes a request to the V2 CircleCI API to initiate the project, | |
# which will filter based upon terraform: true flag | |
# to run the workflow/jobs listed here: | |
# build-and-test:[ | |
# enable-versioning-for-s3-buckets | |
# ] | |
# | |
# Leverages the open source GitHub Action: | |
# https://github.com/promiseofcake/circleci-trigger-action | |
########################################################################### | |
name: Run Infrastructure Pipeline When Terraform or Infrastructure Files Change | |
on: | |
push: | |
branches-ignore: #handled in CircleCI | |
- main | |
- master | |
- 'release/**' | |
paths: | |
- 'terraform/**' | |
- '.circleci/infrastructure/**' | |
jobs: | |
run_infrastructure_deployment: | |
runs-on: ubuntu-latest | |
name: Deploy Infrastructure | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Circle CI Deployment Trigger | |
id: curl-circle-ci | |
uses: promiseofcake/circleci-trigger-action@v1 | |
with: | |
user-token: ${{ secrets.CIRCLE_CI_V2_TOKEN }} | |
project-slug: ${{ github.repository }} | |
branch: ${{ github.ref_name }} | |
payload: '{ | |
"deploy_infrastructure": true, | |
"triggered": true | |
}' | |