Skip to content

Commit

Permalink
[nc] test terraform-actions plan workflow
Browse files Browse the repository at this point in the history
Signed-off-by: Nic Cheneweth <nchenewe@thoughtworks.com>
  • Loading branch information
ncheneweth committed May 20, 2024
1 parent f93c6cb commit 4e28247
Show file tree
Hide file tree
Showing 3 changed files with 38 additions and 5 deletions.
29 changes: 29 additions & 0 deletions .github/actions/before-init/action.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
# yamllint disable rule:line-length
---
name: setup environment

description: load values from 1password vault

inputs:

instance:
description: input value that can be used to control which actions are run
required: false
default: ""

runs:
using: "composite"

steps:

- name: run step if instance matches
if: ${{ inputs.instance != 'prod' }}
uses: 1password/load-secrets-action@581a835fb51b8e7ec56b71cf2ffddd7e68bb25e0 # v2.0.0
with:
export-env: true
env:
TFE_TOKEN: op://empc-lab/svc-terraform-cloud/team-api-token
GREN_GITHUB_TOKEN: op://empc-lab/svc-github/access-token
SLACK_BOT_TOKEN: op://empc-lab/svc-slack/post-bot-token
AWS_ACCESS_KEY_ID: op://empc-lab/aws-dps-2/PSKProdServiceAccount-aws-access-key-id
AWS_SECRET_ACCESS_KEY: op://empc-lab/aws-dps-2/PSKProdServiceAccount-aws-secret-access-key
11 changes: 8 additions & 3 deletions .github/workflows/development-build.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,11 @@ jobs:
tflint-provider: aws
tflint-provider-version: 0.31.0
trivy-scan: true
terrascan-scan: true
terrascan-iac-type: terraform
terrascan-policy-type: aws

plan:
name: terraform plan
uses: ThoughtWorks-DPS/terraform-action/.github/workflows/plan.yaml@main
with:
tfc-workspace: "psk-aws-platform-eks-base-sandbox-i01-aws-us-east-1"
tfc-organization: twdps
checkov-scan: true
3 changes: 1 addition & 2 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,2 +1 @@
# psk-aws-platform-eks-base

# psk-aws-platform-eks-base

0 comments on commit 4e28247

Please sign in to comment.