kitchen-ansible 0.0.35 → 0.0.36
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/README.md +1 -25
- data/lib/kitchen-ansible/version.rb +1 -1
- data/lib/kitchen/provisioner/ansible/config.rb +1 -0
- data/lib/kitchen/provisioner/ansible_playbook.rb +7 -0
- data/provisioner_options.md +1 -0
- metadata +2 -2
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA1:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 9617210fbf8c1839bc92c847c36f63295ae81ff3
|
|
4
|
+
data.tar.gz: 8f0a2209b0f4714aa17ee71f739175ab121e93f2
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 7de0292f5216051db44474734ed4fbc6160bda4a6551c2174fa2b2f5459cf96b2d3cbbc2dad8f041f8531deb8516ec9946c9da6ef385c44497995ed8fc824e65
|
|
7
|
+
data.tar.gz: 6176571072fd4694e83ef4469097b0357cd43a4073da6dde2d73c30ae4b14af44d3b1b9356445eb0fb1b899e84a4e1a2b1f4050aa521158700541de41d651b6e
|
data/README.md
CHANGED
|
@@ -98,31 +98,7 @@ Serverspec uses ssh to communicate with the server to be tested and reads the an
|
|
|
98
98
|
|
|
99
99
|
### Example usage to create tomcat servers:
|
|
100
100
|
|
|
101
|
-
|
|
102
|
-
TEST KITCHEN ANSIBLE AND SERVERSPEC TOMCAT SERVER
|
|
103
|
-
WORKSTATION SERVER (built and destroyed (created separately
|
|
104
|
-
(or Jenkins CI) automatically) could be docker container)
|
|
105
|
-
+----------------------------+
|
|
106
|
-
+-------------------+ | | +-----------------------+
|
|
107
|
-
| test kitchen | | | | |
|
|
108
|
-
| kitchen-ansible | create | | | |
|
|
109
|
-
| | ser^er | | | +-----------+ |
|
|
110
|
-
| CREATE +------------> +----------+ | | | tomcat | |
|
|
111
|
-
| | | | | | install | | |
|
|
112
|
-
| | install and run | ansible +---------------> | |
|
|
113
|
-
| CONVERGE +------------+---------------> | | tomcat +-----------+ |
|
|
114
|
-
| | | +----------+ | | |
|
|
115
|
-
| | install| +----------+ +---------+ | test |
|
|
116
|
-
| VERIFY +--------------->busser- |-->serverspec--------+----> |
|
|
117
|
-
| |and run | |ansiblespec | | | | |
|
|
118
|
-
| | | +----------+ +---------+ | +-----------------------+
|
|
119
|
-
| DESTROY +------------> |
|
|
120
|
-
+-------------------+ delete +----------------------------+
|
|
121
|
-
server
|
|
122
|
-
|
|
123
|
-
* All connections over SSH
|
|
124
|
-
|
|
125
|
-
```
|
|
101
|
+

|
|
126
102
|
|
|
127
103
|
See [ansible-sample-tdd](https://github.com/volanja/ansible-sample-tdd)
|
|
128
104
|
|
|
@@ -51,6 +51,7 @@ module Kitchen
|
|
|
51
51
|
default_config :require_chef_for_busser, true
|
|
52
52
|
default_config :require_ruby_for_busser, false
|
|
53
53
|
default_config :requirements_path, false
|
|
54
|
+
default_config :ssh_known_hosts, nil
|
|
54
55
|
default_config :ansible_verbose, false
|
|
55
56
|
default_config :ansible_verbosity, 1
|
|
56
57
|
default_config :ansible_check, false
|
|
@@ -250,6 +250,13 @@ module Kitchen
|
|
|
250
250
|
sudo_env('cp -r'), File.join(config[:root_path], 'host_vars'), '/etc/ansible/.'
|
|
251
251
|
].join(' ')
|
|
252
252
|
|
|
253
|
+
if config[:ssh_known_hosts]
|
|
254
|
+
config[:ssh_known_hosts].each do |host|
|
|
255
|
+
info("Add #{host} to ~/.ssh/known_hosts")
|
|
256
|
+
commands << "ssh-keyscan #{host} > ~/.ssh/known_hosts 2> /dev/null"
|
|
257
|
+
end
|
|
258
|
+
end
|
|
259
|
+
|
|
253
260
|
if galaxy_requirements
|
|
254
261
|
if config[:require_ansible_source]
|
|
255
262
|
commands << setup_ansible_env_from_source
|
data/provisioner_options.md
CHANGED
|
@@ -50,6 +50,7 @@ ansible_source_rev | | Branch or Tag to install ansible source
|
|
|
50
50
|
ansible_host_key_checking | true | strict host key checking in ssh
|
|
51
51
|
private_key | | ssh private key file for ssh connection
|
|
52
52
|
idempotency_test | false | Enable to test ansible playbook idempotency
|
|
53
|
+
ssh_known_hosts | | List of hosts that should be added to `~/.ssh/known_hosts`
|
|
53
54
|
|
|
54
55
|
## Configuring Provisioner Options
|
|
55
56
|
|
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: kitchen-ansible
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.0.
|
|
4
|
+
version: 0.0.36
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Neill Turner
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: bin
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2015-12-
|
|
11
|
+
date: 2015-12-29 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: test-kitchen
|