knife-zero 0.1.1 → 0.1.2
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/CHANGELOG.md +4 -0
- data/lib/chef/knife/chef_client.rb +7 -1
- data/lib/knife-zero/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA1:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: b722a029242b27e1a09e5c34db80713dc2f3be69
|
|
4
|
+
data.tar.gz: d79010edf67913305e2b37289157eee93ef771c0
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 4bb00bbd3e59e462fc47995c0e1277826c7334051ff8da1b99627d0039f57ad559fcb82804a2aede377c958ab0bd4c1df1e77f5fdb541ac498a201c3f3f7e4dc
|
|
7
|
+
data.tar.gz: e9b5a407ab633c8008ae2919d7c82bab6a22ac55dd537100c0aa1a14745d8fc2f40aea38c64f51c92437405790e1362829564acea39574e9e5a3be10b28dfb89
|
data/CHANGELOG.md
CHANGED
|
@@ -22,6 +22,11 @@ class Chef
|
|
|
22
22
|
:description => "The attribute to use for opening the connection - default depends on the context",
|
|
23
23
|
:proc => Proc.new { |key| Chef::Config[:knife][:ssh_attribute] = key.strip }
|
|
24
24
|
|
|
25
|
+
option :use_sudo,
|
|
26
|
+
:long => "--sudo",
|
|
27
|
+
:description => "execute the chef-client via sudo",
|
|
28
|
+
:boolean => true
|
|
29
|
+
|
|
25
30
|
def run
|
|
26
31
|
configure_attribute
|
|
27
32
|
configure_user
|
|
@@ -38,7 +43,8 @@ class Chef
|
|
|
38
43
|
end
|
|
39
44
|
|
|
40
45
|
def start_chef_client
|
|
41
|
-
client_path = @config[:
|
|
46
|
+
client_path = @config[:use_sudo] ? 'sudo ' : ''
|
|
47
|
+
client_path = @config[:chef_client_path] ? "#{client_path}#{@config[:chef_client_path]}" : "#{client_path}chef-client"
|
|
42
48
|
s = "#{client_path}"
|
|
43
49
|
s << ' -l debug' if @config[:verbosity] and @config[:verbosity] >= 2
|
|
44
50
|
s << " -S http://127.0.0.1:8889"
|
data/lib/knife-zero/version.rb
CHANGED