-
Notifications
You must be signed in to change notification settings - Fork 0
47 lines (41 loc) · 1.26 KB
/
pulumi.yaml
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
47
name: Deploy IaC with Pulumi
on:
push:
branches:
- master
workflow_dispatch:
jobs:
pulumi:
permissions:
id-token: write
contents: read
name: Pulumi
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: google-github-actions/auth@v2
with:
project_id: ${{ vars.GCP_PROJECT_ID }}
workload_identity_provider: projects/491900032446/locations/global/workloadIdentityPools/github-pool/providers/my-repo
- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: '3.10'
- name: Install dependencies
run: pip3 install -r requirements.txt
- name: Preview infra 🔍
uses: pulumi/actions@v5
with:
command: preview
stack-name: ${{ vars.PULUMI_ORG }}/${{ vars.PULUMI_STACK }}
plan: pulumi_plan.json
env:
PULUMI_ACCESS_TOKEN: ${{ secrets.PULUMI_ACCESS_TOKEN }}
- name: Update infra 🚀
if: ${{ github.event_name == 'workflow_dispatch' }}
uses: pulumi/actions@v5
with:
command: update
stack-name: ${{ vars.PULUMI_ORG }}/${{ vars.PULUMI_STACK }}
env:
PULUMI_ACCESS_TOKEN: ${{ secrets.PULUMI_ACCESS_TOKEN }}