Skip to content

Commit a4199a4

Browse files
committed
ci: migrate integration tests to exec driver on ubuntu-latest
This change moves all CI integration tests to run directly on the GitHub Actions host using the 'exec' driver. This avoids issues with nested virtualization on standard Azure-hosted runners while still providing a full systemd environment for testing the docker cookbook. - Update .github/workflows/ci.yml to use ubuntu-latest and kitchen.exec.yml - Remove VirtualBox/Vagrant setup from CI - Consolidate integration suites in CI - Update kitchen.exec.yml with all test suites - Remove kitchen.dokken.yml
1 parent ac14817 commit a4199a4

File tree

3 files changed

+107
-175
lines changed

3 files changed

+107
-175
lines changed

.github/workflows/ci.yml

Lines changed: 10 additions & 95 deletions
Original file line numberDiff line numberDiff line change
@@ -19,120 +19,35 @@ jobs:
1919

2020
integration:
2121
needs: lint-unit
22-
runs-on: ubuntu-24.04
22+
runs-on: ubuntu-latest
2323
strategy:
2424
matrix:
25-
os:
26-
- almalinux-9
27-
- almalinux-10
28-
- amazonlinux-2023
29-
- centos-stream-9
30-
- centos-stream-10
31-
- debian-12
32-
- debian-13
33-
- "ubuntu-2204"
34-
- "ubuntu-2404"
35-
3625
suite:
3726
- "installation-package"
3827
- "installation-tarball"
28+
- "installation-script"
3929
- "install-and-stop"
40-
fail-fast: false
41-
steps:
42-
- name: Check out code
43-
uses: actions/checkout@v6
44-
45-
- name: Test Kitchen
46-
uses: ./.github/actions/test-kitchen
47-
with:
48-
kitchen-yaml: kitchen.dokken.yml
49-
suite: ${{ matrix.suite }}
50-
os: ${{ matrix.os }}
51-
license-id: ${{ secrets.CHEF_LICENSE_KEY }}
52-
53-
installation-script:
54-
needs: lint-unit
55-
runs-on: ubuntu-24.04
56-
strategy:
57-
matrix:
58-
os:
59-
- centos-stream-9
60-
- centos-stream-10
61-
- debian-12
62-
- debian-13
63-
- "ubuntu-2204"
64-
- "ubuntu-2404"
65-
66-
suite: ["installation-script"]
67-
fail-fast: false
68-
steps:
69-
- name: Check out code
70-
uses: actions/checkout@v6
71-
72-
- name: Test Kitchen
73-
uses: ./.github/actions/test-kitchen
74-
with:
75-
kitchen-yaml: kitchen.dokken.yml
76-
suite: ${{ matrix.suite }}
77-
os: ${{ matrix.os }}
78-
license-id: ${{ secrets.CHEF_LICENSE_KEY }}
79-
80-
swarm:
81-
needs: lint-unit
82-
runs-on: ubuntu-24.04
83-
strategy:
84-
matrix:
85-
os: ["ubuntu-2204"]
86-
suite: ["swarm"]
87-
fail-fast: false
88-
steps:
89-
- name: Check out code
90-
uses: actions/checkout@v6
91-
92-
- name: Setup VirtualBox & Vagrant
93-
uses: ./.github/actions/virtualbox-setup
94-
95-
- name: Test Kitchen
96-
uses: ./.github/actions/test-kitchen
97-
with:
98-
kitchen-yaml: kitchen.yml
99-
suite: ${{ matrix.suite }}
100-
os: ${{ matrix.os }}
101-
license-id: ${{ secrets.CHEF_LICENSE_KEY }}
102-
103-
smoke:
104-
needs: lint-unit
105-
runs-on: ubuntu-latest
106-
strategy:
107-
matrix:
108-
os:
109-
- "almalinux-9"
110-
- "almalinux-10"
111-
- "debian-12"
112-
- "debian-13"
113-
- "ubuntu-2204"
114-
- "ubuntu-2404"
115-
116-
suite:
30+
- "resources"
31+
- "network"
32+
- "volume"
33+
- "registry"
34+
- "swarm"
11735
- "smoke"
11836
fail-fast: false
11937
steps:
12038
- name: Check out code
12139
uses: actions/checkout@v6
12240

123-
- name: Setup VirtualBox & Vagrant
124-
uses: ./.github/actions/virtualbox-setup
125-
12641
- name: Test Kitchen
12742
uses: ./.github/actions/test-kitchen
12843
with:
129-
kitchen-yaml: kitchen.yml
44+
kitchen-yaml: kitchen.exec.yml
13045
suite: ${{ matrix.suite }}
131-
os: ${{ matrix.os }}
46+
os: "ubuntu-latest"
13247
license-id: ${{ secrets.CHEF_LICENSE_KEY }}
13348

13449
final:
135-
needs: [lint-unit, installation-script, integration, swarm, smoke]
50+
needs: [lint-unit, integration]
13651
runs-on: ubuntu-latest
13752
steps:
13853
- name: Complete

kitchen.dokken.yml

Lines changed: 0 additions & 78 deletions
This file was deleted.

kitchen.exec.yml

Lines changed: 97 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,102 @@
11
---
2-
driver: { name: exec }
3-
transport: { name: exec }
2+
driver:
3+
name: exec
4+
5+
transport:
6+
name: exec
7+
8+
provisioner:
9+
name: chef_infra
10+
product_name: <%= ENV['CHEF_PRODUCT_NAME'] || 'chef' %>
11+
product_version: <%= ENV['CHEF_VERSION'] || 'latest' %>
12+
enforce_idempotency: true
13+
multiple_converge: 2
14+
deprecations_as_errors: true
15+
chef_license: accept-no-persist
16+
17+
verifier:
18+
name: inspec
419

520
platforms:
21+
- name: ubuntu-latest
622
- name: macos-latest
723
- name: windows-latest
24+
25+
suites:
26+
- name: installation_script
27+
run_list:
28+
- recipe[docker_test::installation_script]
29+
30+
- name: installation_package
31+
run_list:
32+
- recipe[docker_test::installation_package]
33+
34+
- name: installation_tarball
35+
run_list:
36+
- recipe[docker_test::installation_tarball]
37+
38+
- name: install_and_stop
39+
run_list:
40+
- recipe[docker_test::install_and_stop]
41+
42+
- name: resources
43+
provisioner:
44+
enforce_idempotency: false
45+
multiple_converge: 1
46+
run_list:
47+
- recipe[docker_test::default]
48+
- recipe[docker_test::image]
49+
- recipe[docker_test::container]
50+
- recipe[docker_test::exec]
51+
- recipe[docker_test::plugin]
52+
- recipe[docker_test::image_prune]
53+
- recipe[docker_test::volume_prune]
54+
55+
- name: network
56+
provisioner:
57+
enforce_idempotency: false
58+
multiple_converge: 1
59+
run_list:
60+
- recipe[docker_test::default]
61+
- recipe[docker_test::network]
62+
63+
- name: volume
64+
provisioner:
65+
enforce_idempotency: false
66+
multiple_converge: 1
67+
run_list:
68+
- recipe[docker_test::default]
69+
- recipe[docker_test::volume]
70+
- recipe[docker_test::volume_prune]
71+
72+
- name: registry
73+
provisioner:
74+
enforce_idempotency: false
75+
multiple_converge: 1
76+
run_list:
77+
- recipe[docker_test::default]
78+
- recipe[docker_test::registry]
79+
80+
- name: swarm
81+
provisioner:
82+
enforce_idempotency: false
83+
multiple_converge: 1
84+
attributes:
85+
docker:
86+
swarm:
87+
init:
88+
advertise_addr: '127.0.0.1'
89+
listen_addr: '0.0.0.0:2377'
90+
rotate_token: true
91+
service:
92+
name: 'web'
93+
image: 'nginx:latest'
94+
publish: ['80:80']
95+
replicas: 2
96+
run_list:
97+
- recipe[docker_test::swarm]
98+
- recipe[docker_test::swarm_service]
99+
100+
- name: smoke
101+
run_list:
102+
- recipe[docker_test::smoke]

0 commit comments

Comments
 (0)