Skip to content

Commit 5d42c94

Browse files
committed
chore(ci): pin dependencies for plugin test workflow
Update plugin test workflow to use the latest hashicorp/setup-packer workflow version. Pin the workflow dependency. Change workflow parameters to match the new workflow version. Signed-off-by: Ville Vesilehto <ville.vesilehto@upcloud.com>
1 parent 6a4f93d commit 5d42c94

File tree

2 files changed

+21
-24
lines changed

2 files changed

+21
-24
lines changed

.github/workflows/integration-test.yml

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,21 @@
11
name: integration-test
22

33
on:
4-
pull_request_review:
5-
types: [submitted]
4+
pull_request:
65
paths:
76
- '**.go'
87
- 'go.mod'
98
- 'go.sum'
109
- '.github/workflows/integration-test.yaml'
10+
- 'Makefile'
11+
workflow_dispatch:
1112

1213
permissions:
1314
contents: read
1415

16+
concurrency:
17+
group: integration-test
18+
1519
jobs:
1620
integration-test:
1721
if: github.event.review.state == 'approved'
@@ -40,4 +44,4 @@ jobs:
4044
UPCLOUD_USERNAME: ${{ secrets.UPCLOUD_API_USER }}
4145
UPCLOUD_PASSWORD: ${{ secrets.UPCLOUD_API_PASSWORD }}
4246
PACKER_ACC: 1
43-
run: make test_integration
47+
run: make test_integration
Lines changed: 14 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
# This is a manually triggered action workflow.
22
# It uses Packer at latest version to init, validate and build
33
# an example configuration in a folder.
4-
# This action is compatible with Packer v1.7.0 or later.
54
name: test plugin example
65

76
on:
@@ -26,30 +25,24 @@ jobs:
2625
env:
2726
UPCLOUD_API_USER: ${{ secrets.UPCLOUD_API_USER }}
2827
UPCLOUD_API_PASSWORD: ${{ secrets.UPCLOUD_API_PASSWORD }}
28+
PACKER_LOG: ${{ github.event.inputs.logs }}
2929
steps:
3030
- name: Checkout Repository
3131
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
3232

33-
- name: Init
34-
uses: hashicorp/packer-github-actions@master
33+
- name: Setup Packer
34+
uses: hashicorp/setup-packer@1aa358be5cf73883762b302a3a03abd66e75b232 # v3.1.0
3535
with:
36-
working_directory: ${{ github.event.inputs.folder }}
37-
command: init
36+
version: "latest"
3837

39-
- name: Validate
40-
uses: hashicorp/packer-github-actions@master
41-
with:
42-
working_directory: ${{ github.event.inputs.folder }}
43-
command: validate
44-
arguments: -var="ssh_public_key=/dev/null"
45-
env:
46-
PACKER_LOG: ${{ github.event.inputs.logs }}
38+
- name: Run Packer Init
39+
working-directory: ${{ github.event.inputs.folder }}
40+
run: packer init .
4741

48-
- name: Build
49-
uses: hashicorp/packer-github-actions@master
50-
with:
51-
working_directory: ${{ github.event.inputs.folder }}
52-
command: build
53-
arguments: -var="ssh_public_key=/dev/null"
54-
env:
55-
PACKER_LOG: ${{ github.event.inputs.logs }}
42+
- name: Run Packer Validate
43+
working-directory: ${{ github.event.inputs.folder }}
44+
run: packer validate -var="ssh_public_key=/dev/null" .
45+
46+
- name: Run Packer Build
47+
working-directory: ${{ github.event.inputs.folder }}
48+
run: packer build -var="ssh_public_key=/dev/null" .

0 commit comments

Comments
 (0)