kitchen-verifier-shell 0.1.1 → 0.2.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/kitchen-verifier-shell.gemspec +1 -1
- data/lib/kitchen/verifier/shell.rb +18 -1
- 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: ce4506347f7d67c10f86d0120ba07ee1bc286520
|
4
|
+
data.tar.gz: 202f626e545f47267ee8a0ad88b3403d53b8d867
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: c16929ee3a8cd86792bb117125d33b74525a46696f0fa4265aa186451c82b2388a71feef7e9b780a83c7c69c138336accfb6def1e0b360db2ce6fe5740e348e9
|
7
|
+
data.tar.gz: 4bce1f4dcb470995bd3169ab66dc18ba94595398122fdb2e877ff04721a37fd498819536b64e5288dbb68ab3c165d7364e6f26ef961929eade1c9889d8f477c5
|
@@ -36,16 +36,33 @@ module Kitchen
|
|
36
36
|
default_config :command, "true"
|
37
37
|
default_config :shellout_opts, {}
|
38
38
|
default_config :live_stream, $stdout
|
39
|
+
default_config :remote_exec, false
|
39
40
|
|
40
41
|
# (see Base#call)
|
41
42
|
def call(state)
|
42
43
|
info("[#{name}] Verify on instance=#{instance} with state=#{state}")
|
43
44
|
sleep_if_set
|
44
45
|
merge_state_to_env(state)
|
45
|
-
|
46
|
+
if config[:remote_exec]
|
47
|
+
instance.transport.connection(state) do |conn|
|
48
|
+
conn.execute(config[:command])
|
49
|
+
end
|
50
|
+
else
|
51
|
+
shellout
|
52
|
+
end
|
46
53
|
debug("[#{name}] Verify completed.")
|
47
54
|
end
|
48
55
|
|
56
|
+
## for legacy drivers.
|
57
|
+
def run_command
|
58
|
+
if config[:remote_exec]
|
59
|
+
config[:command]
|
60
|
+
else
|
61
|
+
shellout
|
62
|
+
nil
|
63
|
+
end
|
64
|
+
end
|
65
|
+
|
49
66
|
private
|
50
67
|
|
51
68
|
# Sleep for a period of time, if a value is set in the config.
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: kitchen-verifier-shell
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.2.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- sawanoboly
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2015-07-
|
11
|
+
date: 2015-07-31 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: test-kitchen
|