hetzner-cli 0.0.3 → 0.0.4
Sign up to get free protection for your applications and to get access to all the features.
- data/lib/hetzner-cli/command/kickstart.rb +11 -7
- data/lib/hetzner-cli/version.rb +1 -1
- metadata +29 -29
@@ -83,13 +83,17 @@ module HetznerCli
|
|
83
83
|
begin
|
84
84
|
# Ignoring new key
|
85
85
|
Net::SSH.start(ip,'root',:password => new_password , :paranoid => false, :timeout => 5 ) do |ssh|
|
86
|
-
|
87
|
-
if
|
88
|
-
|
89
|
-
|
90
|
-
|
91
|
-
|
92
|
-
|
86
|
+
motd = ssh.exec!("cat /etc/motd")
|
87
|
+
motd = "" if motd.nil?
|
88
|
+
unless motd.include?('rescue')
|
89
|
+
output = ssh.exec!("cat /root/.ssh/authorized_keys2")
|
90
|
+
if output.include?("No such file")
|
91
|
+
puts
|
92
|
+
puts "[#{ip}] Install is finished and system is available"
|
93
|
+
puts "[#{ip}] Installing root ssh key"
|
94
|
+
output = ssh.exec!("echo '#{key}' > /root/.ssh/authorized_keys")
|
95
|
+
fully_booted = true
|
96
|
+
end
|
93
97
|
end
|
94
98
|
end
|
95
99
|
rescue Net::SSH::Disconnect,Errno::ECONNREFUSED, Errno::EHOSTUNREACH, Errno::ECONNABORTED, Errno::ECONNRESET, Errno::ENETUNREACH,Errno::ETIMEDOUT,IOError,Timeout::Error,Net::SSH::AuthenticationFailed
|
data/lib/hetzner-cli/version.rb
CHANGED
metadata
CHANGED
@@ -1,13 +1,13 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: hetzner-cli
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
hash:
|
4
|
+
hash: 23
|
5
5
|
prerelease:
|
6
6
|
segments:
|
7
7
|
- 0
|
8
8
|
- 0
|
9
|
-
-
|
10
|
-
version: 0.0.
|
9
|
+
- 4
|
10
|
+
version: 0.0.4
|
11
11
|
platform: ruby
|
12
12
|
authors:
|
13
13
|
- Patrick Debois
|
@@ -15,10 +15,10 @@ autorequire:
|
|
15
15
|
bindir: bin
|
16
16
|
cert_chain: []
|
17
17
|
|
18
|
-
date:
|
18
|
+
date: 2013-02-25 00:00:00 Z
|
19
19
|
dependencies:
|
20
20
|
- !ruby/object:Gem::Dependency
|
21
|
-
|
21
|
+
version_requirements: &id001 !ruby/object:Gem::Requirement
|
22
22
|
none: false
|
23
23
|
requirements:
|
24
24
|
- - ">="
|
@@ -27,12 +27,12 @@ dependencies:
|
|
27
27
|
segments:
|
28
28
|
- 0
|
29
29
|
version: "0"
|
30
|
+
prerelease: false
|
30
31
|
type: :runtime
|
31
32
|
name: thor
|
32
|
-
|
33
|
-
prerelease: false
|
33
|
+
requirement: *id001
|
34
34
|
- !ruby/object:Gem::Dependency
|
35
|
-
|
35
|
+
version_requirements: &id002 !ruby/object:Gem::Requirement
|
36
36
|
none: false
|
37
37
|
requirements:
|
38
38
|
- - ">="
|
@@ -41,12 +41,12 @@ dependencies:
|
|
41
41
|
segments:
|
42
42
|
- 0
|
43
43
|
version: "0"
|
44
|
+
prerelease: false
|
44
45
|
type: :runtime
|
45
46
|
name: yajl-ruby
|
46
|
-
|
47
|
-
prerelease: false
|
47
|
+
requirement: *id002
|
48
48
|
- !ruby/object:Gem::Dependency
|
49
|
-
|
49
|
+
version_requirements: &id003 !ruby/object:Gem::Requirement
|
50
50
|
none: false
|
51
51
|
requirements:
|
52
52
|
- - ">="
|
@@ -55,12 +55,12 @@ dependencies:
|
|
55
55
|
segments:
|
56
56
|
- 0
|
57
57
|
version: "0"
|
58
|
+
prerelease: false
|
58
59
|
type: :runtime
|
59
60
|
name: json
|
60
|
-
|
61
|
-
prerelease: false
|
61
|
+
requirement: *id003
|
62
62
|
- !ruby/object:Gem::Dependency
|
63
|
-
|
63
|
+
version_requirements: &id004 !ruby/object:Gem::Requirement
|
64
64
|
none: false
|
65
65
|
requirements:
|
66
66
|
- - ">="
|
@@ -69,12 +69,12 @@ dependencies:
|
|
69
69
|
segments:
|
70
70
|
- 0
|
71
71
|
version: "0"
|
72
|
+
prerelease: false
|
72
73
|
type: :runtime
|
73
74
|
name: excon
|
74
|
-
|
75
|
-
prerelease: false
|
75
|
+
requirement: *id004
|
76
76
|
- !ruby/object:Gem::Dependency
|
77
|
-
|
77
|
+
version_requirements: &id005 !ruby/object:Gem::Requirement
|
78
78
|
none: false
|
79
79
|
requirements:
|
80
80
|
- - ">="
|
@@ -83,12 +83,12 @@ dependencies:
|
|
83
83
|
segments:
|
84
84
|
- 0
|
85
85
|
version: "0"
|
86
|
+
prerelease: false
|
86
87
|
type: :runtime
|
87
88
|
name: net-ssh
|
88
|
-
|
89
|
-
prerelease: false
|
89
|
+
requirement: *id005
|
90
90
|
- !ruby/object:Gem::Dependency
|
91
|
-
|
91
|
+
version_requirements: &id006 !ruby/object:Gem::Requirement
|
92
92
|
none: false
|
93
93
|
requirements:
|
94
94
|
- - ">="
|
@@ -97,12 +97,12 @@ dependencies:
|
|
97
97
|
segments:
|
98
98
|
- 0
|
99
99
|
version: "0"
|
100
|
+
prerelease: false
|
100
101
|
type: :runtime
|
101
102
|
name: system_timer
|
102
|
-
|
103
|
-
prerelease: false
|
103
|
+
requirement: *id006
|
104
104
|
- !ruby/object:Gem::Dependency
|
105
|
-
|
105
|
+
version_requirements: &id007 !ruby/object:Gem::Requirement
|
106
106
|
none: false
|
107
107
|
requirements:
|
108
108
|
- - ">="
|
@@ -111,12 +111,12 @@ dependencies:
|
|
111
111
|
segments:
|
112
112
|
- 0
|
113
113
|
version: "0"
|
114
|
+
prerelease: false
|
114
115
|
type: :runtime
|
115
116
|
name: faraday
|
116
|
-
|
117
|
-
prerelease: false
|
117
|
+
requirement: *id007
|
118
118
|
- !ruby/object:Gem::Dependency
|
119
|
-
|
119
|
+
version_requirements: &id008 !ruby/object:Gem::Requirement
|
120
120
|
none: false
|
121
121
|
requirements:
|
122
122
|
- - ">="
|
@@ -127,10 +127,10 @@ dependencies:
|
|
127
127
|
- 0
|
128
128
|
- 0
|
129
129
|
version: 1.0.0
|
130
|
+
prerelease: false
|
130
131
|
type: :development
|
131
132
|
name: bundler
|
132
|
-
|
133
|
-
prerelease: false
|
133
|
+
requirement: *id008
|
134
134
|
description: Manage a Hetzner machine
|
135
135
|
email:
|
136
136
|
- patrick.debois@jedi.be
|
@@ -185,7 +185,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
185
185
|
requirements: []
|
186
186
|
|
187
187
|
rubyforge_project: hetzner-cli
|
188
|
-
rubygems_version: 1.8.
|
188
|
+
rubygems_version: 1.8.24
|
189
189
|
signing_key:
|
190
190
|
specification_version: 3
|
191
191
|
summary: Manage a Hetzner machine
|