-
Notifications
You must be signed in to change notification settings - Fork 0
/
.kitchen.yml
62 lines (58 loc) · 1.47 KB
/
.kitchen.yml
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
---
driver:
name: docker
#enble to true if you are not s root on your workstation
use_sudo: false
#binary: /usr/bin/docker
#docker: /usr/bin/docker
#socket: tcp://localhost:2376
provision_command:
- sudo mkdir -p /tmp/kitchen
- sudo chown kitchen. /tmp/kitchen
platforms:
- name: ubuntu-20.04
driver:
#image: rndmh3ro/docker-ubuntu1404-ansible:latest
image: ansible:20.04
platform: ubuntu
lifecycle:
pre-verify:
- remote: sudo apt-get install -y python-pip
provisioner:
name: ansible_playbook
hosts: test-kitchen
playbook: test-playbook.yml
roles_path: roles
ansible_verbose: false
ansible_verbosity: 2
require_ansible_repo: false
require_ansible_omnibus: false
require_chef_for_busser: false
require_ruby_for_busser: false
ansible_connection: ssh
additional_copy_path:
- "."
init_environment: |
ln -s /usr/bin/bundle2.7 /usr/bin/bundle
verifier:
name: shell
command: >
pytest --color=yes
--hosts="paramiko://${KITCHEN_USERNAME}@${KITCHEN_HOSTNAME}:${KITCHEN_PORT}?ssh_identity_file=${KITCHEN_SSH_KEY}" "tests/integration/${KITCHEN_SUITE}/testinfra"
#verifier:
# name: inspec
# use_sudo: yes
# sudo_path: true
suites:
- name: basic
#for testinfra
verifier:
default_pattern: true
env_vars:
TARGET_HOST: 127.0.0.1
SUDO: true
# - name: basic
# #for inspec
# verifier:
# inspec_tests:
# - tests/integration/basic/inspec/hello