chef-metal 0.9 → 0.9.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +4 -0
- data/bin/metal +1 -0
- data/lib/chef_metal/transport/ssh.rb +4 -2
- data/lib/chef_metal/version.rb +1 -1
- metadata +10 -10
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: d5fdc35ab0b1d5515d7ef8c93e9818b9be68bb62
|
4
|
+
data.tar.gz: 928fc0d4d3e02ff2c4dd89d00199cb32e3482efa
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: b9461ee53fcb21a3825868b21c3d343b80b54a665652dfcce8a404c3bc8f539ea269453233faf83d24918563108d581742723ab8a7f7affb7db5a2323e19c591
|
7
|
+
data.tar.gz: 77247e2fa8c55d9faa8492d0881622da6023dc040c7c01651d94a1f7da677012b5f16931202ca167c664ac132551d1504560652e9dd73ba38c2917283803fdcb
|
data/CHANGELOG.md
CHANGED
data/bin/metal
CHANGED
@@ -75,12 +75,13 @@ module ChefMetal
|
|
75
75
|
end
|
76
76
|
|
77
77
|
def write_file(path, content)
|
78
|
+
execute("mkdir -p #{File.dirname(path)}").error!
|
78
79
|
if options[:prefix]
|
79
80
|
# Make a tempfile on the other side, upload to that, and sudo mv / chown / etc.
|
80
81
|
remote_tempfile = "/tmp/#{File.basename(path)}.#{Random.rand(2**32)}"
|
81
82
|
Chef::Log.debug("Writing #{content.length} bytes to #{remote_tempfile} on #{username}@#{host}")
|
82
83
|
Net::SCP.new(session).upload!(StringIO.new(content), remote_tempfile)
|
83
|
-
execute("mv #{remote_tempfile} #{path}")
|
84
|
+
execute("mv #{remote_tempfile} #{path}").error!
|
84
85
|
else
|
85
86
|
Chef::Log.debug("Writing #{content.length} bytes to #{path} on #{username}@#{host}")
|
86
87
|
Net::SCP.new(session).upload!(StringIO.new(content), path)
|
@@ -88,12 +89,13 @@ module ChefMetal
|
|
88
89
|
end
|
89
90
|
|
90
91
|
def upload_file(local_path, path)
|
92
|
+
execute("mkdir -p #{File.dirname(path)}").error!
|
91
93
|
if options[:prefix]
|
92
94
|
# Make a tempfile on the other side, upload to that, and sudo mv / chown / etc.
|
93
95
|
remote_tempfile = "/tmp/#{File.basename(path)}.#{Random.rand(2**32)}"
|
94
96
|
Chef::Log.debug("Uploading #{local_path} to #{remote_tempfile} on #{username}@#{host}")
|
95
97
|
Net::SCP.new(session).upload!(local_path, remote_tempfile)
|
96
|
-
execute("mv #{remote_tempfile} #{path}")
|
98
|
+
execute("mv #{remote_tempfile} #{path}").error!
|
97
99
|
else
|
98
100
|
Chef::Log.debug("Uploading #{local_path} to #{path} on #{username}@#{host}")
|
99
101
|
Net::SCP.new(session).upload!(local_path, path)
|
data/lib/chef_metal/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: chef-metal
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version:
|
4
|
+
version: 0.9.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- John Keiser
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2014-04-
|
11
|
+
date: 2014-04-12 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: chef
|
@@ -84,30 +84,30 @@ dependencies:
|
|
84
84
|
name: chef-metal-fog
|
85
85
|
requirement: !ruby/object:Gem::Requirement
|
86
86
|
requirements:
|
87
|
-
- -
|
87
|
+
- - ~>
|
88
88
|
- !ruby/object:Gem::Version
|
89
|
-
version: '0'
|
89
|
+
version: '0.2'
|
90
90
|
type: :runtime
|
91
91
|
prerelease: false
|
92
92
|
version_requirements: !ruby/object:Gem::Requirement
|
93
93
|
requirements:
|
94
|
-
- -
|
94
|
+
- - ~>
|
95
95
|
- !ruby/object:Gem::Version
|
96
|
-
version: '0'
|
96
|
+
version: '0.2'
|
97
97
|
- !ruby/object:Gem::Dependency
|
98
98
|
name: chef-metal-vagrant
|
99
99
|
requirement: !ruby/object:Gem::Requirement
|
100
100
|
requirements:
|
101
|
-
- -
|
101
|
+
- - ~>
|
102
102
|
- !ruby/object:Gem::Version
|
103
|
-
version: '0'
|
103
|
+
version: '0.2'
|
104
104
|
type: :runtime
|
105
105
|
prerelease: false
|
106
106
|
version_requirements: !ruby/object:Gem::Requirement
|
107
107
|
requirements:
|
108
|
-
- -
|
108
|
+
- - ~>
|
109
109
|
- !ruby/object:Gem::Version
|
110
|
-
version: '0'
|
110
|
+
version: '0.2'
|
111
111
|
- !ruby/object:Gem::Dependency
|
112
112
|
name: rspec
|
113
113
|
requirement: !ruby/object:Gem::Requirement
|