Skip to content

Commit 85c4004

Browse files
authored
Update GitHub Actions workflows. (#604)
This PR was automatically generated by the update-workflows-ecosystem-providers workflow in the pulumi/ci-mgmt repo, from commit e4f15688017ee624e9014edafffee8e5634edd49.
1 parent 7cc01da commit 85c4004

File tree

9 files changed

+250
-120
lines changed

9 files changed

+250
-120
lines changed

.github/workflows/build_provider.yml

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,8 @@ jobs:
3737
uses: ./.github/actions/setup-tools
3838
with:
3939
tools: pulumictl, go
40+
- name: Prepare local workspace before restoring previously built
41+
run: make prepare_local_workspace
4042
- name: Download schema-embed.json
4143
uses: actions/download-artifact@v4
4244
with:
@@ -45,9 +47,11 @@ jobs:
4547
# Avoid creating directories for each artifact
4648
merge-multiple: true
4749
path: provider/cmd/pulumi-resource-postgresql/schema-embed.json
48-
- name: Prepare for build
49-
# This installs plugins and prepares upstream
50-
run: make upstream
50+
- name: Restore makefile progress
51+
uses: actions/download-artifact@v4
52+
with:
53+
name: prerequisites.make
54+
path: .make
5155
- name: Build & package provider
5256
run: make provider_dist-${{ matrix.platform.os }}-${{ matrix.platform.arch }}
5357
- name: Upload artifacts

.github/workflows/build_sdk.yml

Lines changed: 13 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -54,12 +54,17 @@ jobs:
5454
uses: ./.github/actions/setup-tools
5555
with:
5656
tools: pulumictl, pulumicli, ${{ matrix.language }}
57+
- name: Prepare local workspace
58+
run: make prepare_local_workspace
5759
- name: Download bin
5860
uses: ./.github/actions/download-bin
59-
- name: Install plugins
60-
run: make install_plugins
6161
- name: Update path
6262
run: echo "${{ github.workspace }}/bin" >> "$GITHUB_PATH"
63+
- name: Restore makefile progress
64+
uses: actions/download-artifact@v4
65+
with:
66+
name: prerequisites.make
67+
path: .make
6368
- name: Build SDK
6469
run: make build_${{ matrix.language }}
6570
- name: Check worktree clean
@@ -75,3 +80,9 @@ jobs:
7580
uses: ./.github/actions/upload-sdk
7681
with:
7782
language: ${{ matrix.language }}
83+
- name: Save makefile progress
84+
uses: actions/upload-artifact@v4
85+
with:
86+
name: build_${{ matrix.language }}.make
87+
path: .make
88+
include-hidden-files: true

.github/workflows/master.yml

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -144,15 +144,19 @@ jobs:
144144
uses: ./.github/actions/setup-tools
145145
with:
146146
tools: pulumictl, pulumicli, ${{ matrix.language }}
147+
- name: Prepare local workspace
148+
run: make prepare_local_workspace
147149
- name: Download bin
148150
uses: ./.github/actions/download-bin
149-
- name: Add NuGet source
150-
if: matrix.language == 'dotnet'
151-
run: dotnet nuget add source ${{ github.workspace }}/nuget
152151
- name: Download SDK
153152
uses: ./.github/actions/download-sdk
154153
with:
155154
language: ${{ matrix.language }}
155+
- name: Restore makefile progress
156+
uses: actions/download-artifact@v4
157+
with:
158+
name: build_${{ matrix.language }}.make
159+
path: .make
156160
- name: Update path
157161
run: echo "${{ github.workspace }}/bin" >> "$GITHUB_PATH"
158162
- name: Install Python deps

.github/workflows/prerelease.yml

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -86,15 +86,19 @@ jobs:
8686
uses: ./.github/actions/setup-tools
8787
with:
8888
tools: pulumictl, pulumicli, nodejs, python, dotnet, go, java
89+
- name: Prepare local workspace
90+
run: make prepare_local_workspace
8991
- name: Download bin
9092
uses: ./.github/actions/download-bin
91-
- name: Add NuGet source
92-
if: matrix.language == 'dotnet'
93-
run: dotnet nuget add source ${{ github.workspace }}/nuget
9493
- name: Download SDK
9594
uses: ./.github/actions/download-sdk
9695
with:
9796
language: ${{ matrix.language }}
97+
- name: Restore makefile progress
98+
uses: actions/download-artifact@v4
99+
with:
100+
name: build_${{ matrix.language }}.make
101+
path: .make
98102
- name: Update path
99103
run: echo "${{ github.workspace }}/bin" >> "$GITHUB_PATH"
100104
- name: Install Python deps

.github/workflows/prerequisites.yml

Lines changed: 10 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -56,20 +56,16 @@ jobs:
5656
path: |
5757
.pulumi/examples-cache
5858
key: ${{ runner.os }}-${{ hashFiles('provider/go.sum') }}
59-
- name: Prepare upstream code
60-
run: make upstream
6159
- name: Setup tools
6260
uses: ./.github/actions/setup-tools
6361
with:
6462
tools: go, pulumictl, pulumicli, schema-tools
65-
- name: Build schema generator binary
66-
run: make tfgen_build_only
67-
- name: Install plugins
68-
run: make install_plugins
63+
- name: Prepare local workspace before restoring previously built files
64+
run: make prepare_local_workspace
6965
- name: Generate schema
70-
run: make tfgen_no_deps
66+
run: make schema
7167
- name: Build provider binary
72-
run: make provider_no_deps
68+
run: make provider
7369
- name: Unit-test provider code
7470
run: make test_provider
7571
- if: inputs.is_pr
@@ -81,6 +77,12 @@ jobs:
8177
schema-tools compare -r github://api.github.com/pulumi -p postgresql -o "${{ inputs.default_branch }}" -n --local-path=provider/cmd/pulumi-resource-postgresql/schema.json;
8278
echo "$EOF";
8379
} >> "$GITHUB_ENV"
80+
- name: Save makefile progress
81+
uses: actions/upload-artifact@v4
82+
with:
83+
name: prerequisites.make
84+
path: .make
85+
include-hidden-files: true
8486
- if: inputs.is_pr && inputs.is_automated == false
8587
name: Comment on PR with Details of Schema Check
8688
uses: thollander/actions-comment-pull-request@v2

.github/workflows/release.yml

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -92,15 +92,19 @@ jobs:
9292
uses: ./.github/actions/setup-tools
9393
with:
9494
tools: pulumictl, pulumicli, ${{ matrix.language }}
95+
- name: Prepare local workspace
96+
run: make prepare_local_workspace
9597
- name: Download bin
9698
uses: ./.github/actions/download-bin
97-
- name: Add NuGet source
98-
if: matrix.language == 'dotnet'
99-
run: dotnet nuget add source ${{ github.workspace }}/nuget
10099
- name: Download SDK
101100
uses: ./.github/actions/download-sdk
102101
with:
103102
language: ${{ matrix.language }}
103+
- name: Restore makefile progress
104+
uses: actions/download-artifact@v4
105+
with:
106+
name: build_${{ matrix.language }}.make
107+
path: .make
104108
- name: Update path
105109
run: echo "${{ github.workspace }}/bin" >> "$GITHUB_PATH"
106110
- name: Install Python deps

.github/workflows/run-acceptance-tests.yml

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -141,15 +141,19 @@ jobs:
141141
uses: ./.github/actions/setup-tools
142142
with:
143143
tools: pulumictl, pulumicli, ${{ matrix.language }}
144+
- name: Prepare local workspace
145+
run: make prepare_local_workspace
144146
- name: Download bin
145147
uses: ./.github/actions/download-bin
146-
- name: Add NuGet source
147-
if: matrix.language == 'dotnet'
148-
run: dotnet nuget add source ${{ github.workspace }}/nuget
149148
- name: Download SDK
150149
uses: ./.github/actions/download-sdk
151150
with:
152151
language: ${{ matrix.language }}
152+
- name: Restore makefile progress
153+
uses: actions/download-artifact@v4
154+
with:
155+
name: build_${{ matrix.language }}.make
156+
path: .make
153157
- name: Update path
154158
run: echo "${{ github.workspace }}/bin" >> "$GITHUB_PATH"
155159
- name: Install Python deps

.gitignore

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,3 +30,7 @@ sdk/java/gradlew.bat
3030

3131

3232
sdk/python/venv
33+
34+
35+
# Ignore local build tracking directory
36+
.make

0 commit comments

Comments
 (0)