beaker-task_helper 1.7.0 → 1.7.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/beaker-task_helper.rb +18 -7
- data/lib/beaker-task_helper/version.rb +1 -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: f6d8f14889f34d8454b6b7c3edacb8ccd5fef898
|
4
|
+
data.tar.gz: c5cb9326641991c2ba2c7802aa9d8e8275f0de37
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 6e5001028885a733480e6b98b2afcccc5bea4dfec1aedd8415bc71642583f16f2ea5c0286cd1617e6486e9d619a780658f03d390da73149cee389aaed2681a56
|
7
|
+
data.tar.gz: 58af4abbbf3eab20be6c31e43b96cefec8da0d67c14876490c689f1fee7705aebdb52253cfdd46df1c936ec5dd4f232f0a4acc67df740195af13bcac151f72de
|
data/lib/beaker-task_helper.rb
CHANGED
@@ -74,13 +74,24 @@ INSTALL_BOLT_PP
|
|
74
74
|
#
|
75
75
|
#TODO: Implement on windows
|
76
76
|
def setup_ssh_access(task_runner, nodes)
|
77
|
-
|
78
|
-
|
79
|
-
|
80
|
-
on
|
81
|
-
|
82
|
-
|
83
|
-
|
77
|
+
task_runner_ssh_dir = '/root/.ssh'
|
78
|
+
task_runner_rsa_pub = "#{task_runner_ssh_dir}/id_rsa.pub"
|
79
|
+
on task_runner, "ssh-keygen -f #{task_runner_ssh_dir}/id_rsa -t rsa -N ''"
|
80
|
+
public_key = on(task_runner, "cat #{task_runner_rsa_pub}").stdout
|
81
|
+
|
82
|
+
nodes.each do |node|
|
83
|
+
case node.platform
|
84
|
+
when /solaris-10/
|
85
|
+
ssh_dir_path = '/.ssh/'
|
86
|
+
when /osx-1012/
|
87
|
+
ssh_dir_path = '/var/root/.ssh/'
|
88
|
+
else
|
89
|
+
ssh_dir_path = '/root/.ssh'
|
90
|
+
end
|
91
|
+
rsa_pub_path = "#{ssh_dir_path}/id_rsa.pub"
|
92
|
+
create_remote_file(node, "#{rsa_pub_path}", public_key)
|
93
|
+
on(node, "cat #{rsa_pub_path} >> #{ssh_dir_path}/authorized_keys")
|
94
|
+
end
|
84
95
|
end
|
85
96
|
|
86
97
|
def run_task(task_name:, params: nil, password: DEFAULT_PASSWORD, host: nil, format: 'human')
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: beaker-task_helper
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.7.
|
4
|
+
version: 1.7.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- puppet
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2018-09-
|
11
|
+
date: 2018-09-24 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rubocop
|