-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path.gitlab-ci.yml
More file actions
57 lines (51 loc) · 1.29 KB
/
.gitlab-ci.yml
File metadata and controls
57 lines (51 loc) · 1.29 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
image: ruby:2.3
stages:
- prepare
- deploy
- test
- destroy
before_script:
- echo -n "$kitchen_ci_key" | tr -d '\r' > ./id_rsa
- chmod 600 ./id_rsa
- "sed -i \"s/openstack_api_key.*/openstack_api_key: $kitchen_ci_pass/g\" .kitchen.yml"
- gem install test-kitchen
- gem install kitchen-puppet
- gem install kitchen-openstack
- gem install puppet
- gem install librarian-puppet
- librarian-puppet init
- librarian-puppet install
prepare:
stage: prepare
artifacts:
paths:
- .kitchen/
expire_in: 20 mins
script:
- rm -rf .kitchen || true
- kitchen create
deploy:
stage: deploy
script:
- kitchen converge
# Test GUI
test:
before_script:
- "true"
stage: test
script:
# wait until cdo is ready
- sleep 600
- "(cat < /dev/tcp/134.60.64.196/2036 &) && sleep 1 && pkill cat"
destroy:
before_script:
- echo -n "$kitchen_ci_key" | tr -d '\r' > ./id_rsa
- chmod 600 ./id_rsa
- "sed -i \"s/openstack_api_key.*/openstack_api_key: $kitchen_ci_pass/g\" .kitchen.yml"
- gem install test-kitchen
- gem install kitchen-puppet
- gem install kitchen-openstack
stage: destroy
script:
- kitchen destroy
when: always