Skip to content

Commit 2232038

Browse files
committed
ci(workflows): update kitchen.windows.yml
1 parent 8b2d182 commit 2232038

File tree

2 files changed

+19
-54
lines changed

2 files changed

+19
-54
lines changed

.github/workflows/kitchen.windows.yml

Lines changed: 12 additions & 41 deletions
Original file line numberDiff line numberDiff line change
@@ -17,27 +17,15 @@ jobs:
1717
fail-fast: false
1818
matrix:
1919
instance:
20-
- default-windows-2022-latest-py3
20+
- default-windows-2022-latest
2121
steps:
2222
- name: 'Check out code'
23-
uses: 'actions/checkout@v2'
24-
- name: 'Install Chef'
25-
uses: 'actionshub/[email protected]'
23+
uses: 'actions/checkout@v4'
24+
- name: 'Set up Ruby'
25+
uses: ruby/setup-ruby@v1
2626
with:
27-
project: 'chef'
28-
version: '16.10.8'
29-
- name: 'Add Chef bindir to PATH'
30-
uses: 'myci-actions/export-env-var-powershell@1'
31-
with:
32-
name: 'PATH'
33-
value: "C:\\opscode\\chef\\bin;\
34-
C:\\opscode\\chef\\embedded\\bin;$env:PATH"
35-
- name: 'Set up Bundler cache'
36-
uses: 'actions/cache@v1'
37-
with:
38-
path: 'vendor/bundle'
39-
key: "${{ runner.os }}-gems-${{ hashFiles('**/Gemfile.lock') }}"
40-
restore-keys: "${{ runner.os }}-gems-"
27+
ruby-version: '3.1.6'
28+
bundler-cache: true
4129
- name: 'Set up test user'
4230
run: |
4331
$password = ConvertTo-SecureString $env:machine_pass -AsPlainText -Force
@@ -59,27 +47,15 @@ jobs:
5947
fail-fast: false
6048
matrix:
6149
instance:
62-
- default-windows-2019-latest-py3
50+
- default-windows-2019-latest
6351
steps:
6452
- name: 'Check out code'
65-
uses: 'actions/checkout@v2'
66-
- name: 'Install Chef'
67-
uses: 'actionshub/[email protected]'
68-
with:
69-
project: 'chef'
70-
version: '16.10.8'
71-
- name: 'Add Chef bindir to PATH'
72-
uses: 'myci-actions/export-env-var-powershell@1'
53+
uses: 'actions/checkout@v4'
54+
- name: 'Set up Ruby'
55+
uses: ruby/setup-ruby@v1
7356
with:
74-
name: 'PATH'
75-
value: "C:\\opscode\\chef\\bin;\
76-
C:\\opscode\\chef\\embedded\\bin;$env:PATH"
77-
- name: 'Set up Bundler cache'
78-
uses: 'actions/cache@v1'
79-
with:
80-
path: 'vendor/bundle'
81-
key: "${{ runner.os }}-gems-${{ hashFiles('**/Gemfile.lock') }}"
82-
restore-keys: "${{ runner.os }}-gems-"
57+
ruby-version: '3.1.6'
58+
bundler-cache: true
8359
- name: 'Set up test user'
8460
run: |
8561
$password = ConvertTo-SecureString $env:machine_pass -AsPlainText -Force
@@ -88,10 +64,5 @@ jobs:
8864
- name: 'Set up WinRM'
8965
run: |
9066
Set-WSManQuickConfig -Force
91-
- name: 'Run Bundler'
92-
run: |
93-
ruby --version
94-
bundle config path vendor/bundle
95-
bundle install --jobs 4 --retry 3
9667
- name: 'Run Test Kitchen'
9768
run: 'bundle exec kitchen verify ${{ matrix.instance }}'

kitchen.windows.yml

Lines changed: 7 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -11,21 +11,15 @@ driver:
1111

1212
provisioner:
1313
salt_install: bootstrap
14-
salt_bootstrap_options: -pythonVersion 3 -version 3004.1-1
15-
# yamllint disable rule:line-length
14+
salt_bootstrap_url: "https://github.com/saltstack/salt-bootstrap\
15+
/releases/latest/download/bootstrap-salt.ps1"
16+
salt_call_command: C:\Program Files\Salt Project\Salt\salt-call
1617
init_environment: |
17-
salt-call --local state.single file.managed `
18+
'"C:\Program Files\Salt Project\Salt\salt-call" --local state.single file.managed `
1819
C:\Users\kitchen\AppData\Local\Temp\kitchen\srv\salt\win\repo-ng\salt-minion.sls `
1920
source=https://github.com/saltstack/salt-winrepo-ng/raw/master/salt-minion.sls `
20-
skip_verify=True makedirs=True
21-
# yamllint enable rule:line-length
21+
skip_verify=True makedirs=True'
2222
2323
platforms:
24-
- name: windows-2022-latest-py3
25-
verifier:
26-
inputs:
27-
saltmajorversion: 3004
28-
- name: windows-2019-latest-py3
29-
verifier:
30-
inputs:
31-
saltmajorversion: 3004
24+
- name: windows-2022-latest
25+
- name: windows-2019-latest

0 commit comments

Comments
 (0)