-
Notifications
You must be signed in to change notification settings - Fork 0
46 lines (42 loc) · 1.11 KB
/
_terraform-upgrade.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
on:
workflow_call:
inputs:
account:
description: The AWS account being deployed
type: string
required: true
workspace:
description: The Terraform workspace being deployed
type: string
required: true
scope:
description: The Terraform scope being deployed
type: string
required: true
permissions:
id-token: write
contents: read
actions: write
env:
ACCOUNT: ${{ inputs.account }}
WORKSPACE: ${{ inputs.workspace }}
CACHE_NAME: ${{ inputs.workspace }}-${{ inputs.account }}-${{ inputs.scope }}
SCOPE: ${{ inputs.scope }}
CI_ROLE_NAME: ${{ secrets.CI_ROLE_NAME }}
jobs:
parse-secrets:
runs-on: [self-hosted, ci]
steps:
- id: parse-secrets
run: |
echo "::add-mask::${{ secrets.CI_ROLE_NAME }}"
terraform--init--upgrade:
needs: [parse-secrets]
runs-on: [self-hosted, ci]
steps:
- uses: ./.github/actions/terraform/
with:
command: init--upgrade
account: ${{ env.ACCOUNT }}
workspace: ${{ env.WORKSPACE }}
scope: ${{ env.SCOPE }}