forked from amendlik/gitstack-pillar
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path.kitchen.yml
More file actions
118 lines (113 loc) · 3.36 KB
/
.kitchen.yml
File metadata and controls
118 lines (113 loc) · 3.36 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
<% root_path='/tmp/kitchen' %>
<% @test_configs = ['legacy_singlestack', 'legacy_multistack', 'multirepo'] %>
<% @salt_versions = [
['stable', '2016.11.9'],
['stable', '2016.11.10'],
['stable', '2017.7.4'],
['stable', '2017.7.5'],
['stable', '2017.7.6'],
['stable', '2017.7.7'],
['stable', '2017.7.8'],
['stable', '2018.3.0'],
['stable', '2018.3.1'],
['stable', '2018.3.2'],
['stable', '2018.3.3'],
['stable', '2018.3.4'],
['stable', '2019.2.0']
] %>
driver:
name: docker
use_sudo: false
privileged: true
platforms:
- name: debian
provisioner:
name: salt_solo
is_file_root: true
root_path: <%= root_path %>
salt_copy_filter:
- .git
- .gitignore
- .kitchen
- .kitchen.yml
- .bundle
- Gemfile
- Gemfile.lock
- README.md
- LICENSE
- vendor
- docs
state_top:
base:
'*':
- tests.sandbox
pillars:
kitchen.sls:
kitchen:
provisioner:
root_path: <%= root_path %>
test_key: 'test_value'
legacy_singlestack_config.sls:
gitstack_config:
ext_pillar:
- gitstack:
stack: _stack/stack1.cfg
repo: file://<%= root_path %>/srv/salt/tests/repo_a
branch: master
- git:
- master file://<%= root_path %>/srv/salt/tests/repo_a
legacy_multistack_config.sls:
gitstack_config:
ext_pillar:
- gitstack:
stack:
- _stack/stack1.cfg
- _stack/stack2.cfg
repo: file://<%= root_path %>/srv/salt/tests/repo_a
branch: master
- git:
- master file://<%= root_path %>/srv/salt/tests/repo_a
multirepo_config.sls:
gitstack_config:
ext_pillar:
- gitstack:
- master file://<%= root_path %>/srv/salt/tests/repo_a:
- stack:
- _stack/stack1.cfg
- _stack/stack2.cfg
- master file://<%= root_path %>/srv/salt/tests/repo_b:
- stack: _stack/stack.cfg
- root: pillar1
- name: repo_b1
- master file://<%= root_path %>/srv/salt/tests/repo_b:
- stack: _stack/stack.cfg
- root: pillar2
- name: repo_b2
- git:
- master file://<%= root_path %>/srv/salt/tests/repo_a
- master file://<%= root_path %>/srv/salt/tests/repo_b:
- root: pillar1
- name: repo_b1
- master file://<%= root_path %>/srv/salt/tests/repo_b:
- root: pillar2
- name: repo_b2
suites:
<% @salt_versions.each do |version| %>
<% @test_configs.each do |config| %>
<% unless version[1].start_with?('2016.11.') && config == 'multirepo' %>
- name: <%= "#{version[1].gsub('.', '-')}-#{config}" %>
provisioner:
salt_bootstrap_options: -X -n -p git -p python-pygit2 <%= version[0] %> <%= version[1] %>
pillars:
top.sls:
base:
'*':
- kitchen
- <%= config %>_config
<% end %>
<% end %>
<% end %>
verifier:
name: shell
remote_exec: false
command: ssh -o UserKnownHostsFile=/dev/null -o StrictHostKeyChecking=no -o IdentitiesOnly=yes -o LogLevel=ERROR -i ${KITCHEN_SSH_KEY} -p ${KITCHEN_PORT} ${KITCHEN_USERNAME}@${KITCHEN_HOSTNAME} sh <%= root_path %>/srv/salt/tests/suites/${KITCHEN_SUITE##*-}/verify.sh