Skip to content

Commit 1899de7

Browse files
authored
Update GitHub Actions workflows. (#1059)
This PR was automatically generated by the update-workflows-ecosystem-providers workflow in the pulumi/ci-mgmt repo, from commit 87a49339e512f38177d9b4f4c9138a91d9855fe2.
1 parent 8eb6fca commit 1899de7

File tree

12 files changed

+97
-82
lines changed

12 files changed

+97
-82
lines changed

.github/actions/download-codegen/action.yml

Lines changed: 0 additions & 17 deletions
This file was deleted.
Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
name: Download the code generator binary
2+
description: Downloads the code generator binary to `bin/`.
3+
4+
runs:
5+
using: "composite"
6+
steps:
7+
- name: Download the prerequisites bin
8+
uses: actions/download-artifact@fa0a91b85d4f404e444e00e005971372dc801d16 # v4.1.8
9+
with:
10+
name: prerequisites-bin
11+
path: bin
12+
13+
- name: Restore executable permissions
14+
shell: bash
15+
run: chmod +x $(< bin/executables.txt)
16+
17+
- name: Remove executables list
18+
shell: bash
19+
run: rm bin/executables.txt
20+
21+
- name: Download schema-embed.json
22+
uses: actions/download-artifact@fa0a91b85d4f404e444e00e005971372dc801d16 # v4.1.8
23+
with:
24+
# Use a pattern to avoid failing if the artifact doesn't exist
25+
pattern: schema-embed.*
26+
# Avoid creating directories for each artifact
27+
merge-multiple: true
28+
path: provider/cmd/pulumi-resource-cloudflare

.github/actions/setup-tools/action.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,7 @@ runs:
7878

7979
- name: Setup Java
8080
if: inputs.tools == 'all' || contains(inputs.tools, 'java')
81-
uses: actions/setup-java@7a6d8a8234af8eb26422e24e3006232cccaa061b # v4.6.0
81+
uses: actions/setup-java@3a4f6e1af504cf6a31855fa899c6aa5355ba6c12 # v4.7.0
8282
with:
8383
cache: gradle
8484
distribution: temurin
Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
name: Upload SDK asset
2+
description: Upload the SDK for a specific language as an asset for the workflow.
3+
4+
runs:
5+
using: "composite"
6+
steps:
7+
- name: Capture executable permissions
8+
shell: bash
9+
run: find bin -type f -executable > bin/executables.txt
10+
11+
- name: Upload prerequisites bin
12+
uses: actions/upload-artifact@65c4c4a1ddee5b72f698fdd19549f0f0fb45cf08 # v4.6.0
13+
with:
14+
name: prerequisites-bin
15+
path: bin/*
16+
retention-days: 30
17+
18+
- name: Upload schema-embed.json
19+
uses: actions/upload-artifact@65c4c4a1ddee5b72f698fdd19549f0f0fb45cf08 # v4.6.0
20+
with:
21+
name: schema-embed.json
22+
path: provider/cmd/pulumi-resource-cloudflare/schema-embed.json
23+
retention-days: 30

.github/workflows/build_provider.yml

Lines changed: 3 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -47,15 +47,10 @@ jobs:
4747
tools: pulumictl, go
4848
- name: Prepare local workspace before restoring previously built
4949
run: make prepare_local_workspace
50-
- name: Download schema-embed.json
51-
uses: actions/download-artifact@fa0a91b85d4f404e444e00e005971372dc801d16 # v4.1.8
52-
with:
53-
# Use a pattern to avoid failing if the artifact doesn't exist
54-
pattern: schema-embed.*
55-
# Avoid creating directories for each artifact
56-
merge-multiple: true
57-
path: provider/cmd/pulumi-resource-cloudflare
50+
- name: Restore prerequisites
51+
uses: ./.github/actions/download-prerequisites
5852
- name: Restore makefile progress
53+
# This mirrors the targets completed in the prerequisites job
5954
run: make --touch provider schema
6055

6156
- name: Build provider

.github/workflows/build_sdk.yml

Lines changed: 2 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -62,18 +62,10 @@ jobs:
6262
tools: pulumictl, pulumicli, ${{ matrix.language }}
6363
- name: Prepare local workspace
6464
run: make prepare_local_workspace
65-
- name: Download codegen
66-
uses: ./.github/actions/download-codegen
65+
- name: Download prerequisites
66+
uses: ./.github/actions/download-prerequisites
6767
- name: Update path
6868
run: echo "${{ github.workspace }}/bin" >> "$GITHUB_PATH"
69-
- name: Download schema-embed.json
70-
uses: actions/download-artifact@fa0a91b85d4f404e444e00e005971372dc801d16 # v4.1.8
71-
with:
72-
# Use a pattern to avoid failing if the artifact doesn't exist
73-
pattern: schema-embed.*
74-
# Avoid creating directories for each artifact
75-
merge-multiple: true
76-
path: provider/cmd/pulumi-resource-cloudflare
7769
- name: Restore makefile progress
7870
run: make --touch provider schema
7971
- name: Build SDK

.github/workflows/lint.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ jobs:
5050
continue-on-error: true
5151
run: make prepare_local_workspace
5252
- name: golangci-lint
53-
uses: golangci/golangci-lint-action@ec5d18412c0aeab7936cb16880d708ba2a64e1ae # v6
53+
uses: golangci/golangci-lint-action@e60da84bfae8c7920a47be973d75e15710aa8bd7 # v6
5454
with:
5555
version: v1.60
5656
working-directory: provider

.github/workflows/prerequisites.yml

Lines changed: 2 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -99,16 +99,5 @@ jobs:
9999
100100
Maintainer note: consult the [runbook](https://github.com/pulumi/platform-providers-team/blob/main/playbooks/tf-provider-updating.md) for dealing with any breaking changes.
101101
102-
- name: Upload codegen binary for cloudflare
103-
uses: actions/upload-artifact@65c4c4a1ddee5b72f698fdd19549f0f0fb45cf08 # v4.6.0
104-
with:
105-
name: pulumi-tfgen-cloudflare
106-
path: ${{ github.workspace }}/bin/pulumi-tfgen-cloudflare
107-
retention-days: 30
108-
109-
- name: Upload schema-embed.json
110-
uses: actions/upload-artifact@65c4c4a1ddee5b72f698fdd19549f0f0fb45cf08 # v4.6.0
111-
with:
112-
name: schema-embed.json
113-
path: provider/cmd/pulumi-resource-cloudflare/schema-embed.json
114-
retention-days: 30
102+
- name: Upload artifacts
103+
uses: ./.github/actions/upload-prerequisites

.github/workflows/test.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ jobs:
5858
- name: Prepare local workspace
5959
run: make prepare_local_workspace
6060
- name: Download bin
61-
uses: ./.github/actions/download-bin
61+
uses: ./.github/actions/download-provider
6262
- name: Download SDK
6363
uses: ./.github/actions/download-sdk
6464
with:

0 commit comments

Comments
 (0)