aell 0.2.1 → 0.3.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Gemfile.lock +5 -5
- data/exe/aell +15 -2
- data/lib/aell/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 6a366cd9a2b0a141f24e8270b81aa32e3ae1f6fe0c0a30c1c09b10bbd3056796
|
4
|
+
data.tar.gz: d890e5c9b5148cfb13653eef9fde2dcf993e0d0ea80eab4e4c54653240c886f3
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 2858561b28f5779e03b3858803cef5e658796e88207ed5cd2074cafee0ab111ebfc9f79fc41e9b421f3ed2581d5cd5dc6e1faaa3762f7c516083fdd34a1300fd
|
7
|
+
data.tar.gz: 579d2b0931b72141f57d7e94a3ebe86c1784b9c4ea803764db3a7ffab8ae96cf00739fd4631045d1eab66276aca9e09050f3e2e5bf841ed06c635f4f3c1d6c10
|
data/Gemfile.lock
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
PATH
|
2
2
|
remote: .
|
3
3
|
specs:
|
4
|
-
aell (0.
|
4
|
+
aell (0.3.0)
|
5
5
|
aws-sdk-ec2 (~> 1.137)
|
6
6
|
net-ssh-multi (~> 1.2.1)
|
7
7
|
|
@@ -9,16 +9,16 @@ GEM
|
|
9
9
|
remote: https://rubygems.org/
|
10
10
|
specs:
|
11
11
|
aws-eventstream (1.1.0)
|
12
|
-
aws-partitions (1.
|
13
|
-
aws-sdk-core (3.
|
12
|
+
aws-partitions (1.354.0)
|
13
|
+
aws-sdk-core (3.104.3)
|
14
14
|
aws-eventstream (~> 1, >= 1.0.2)
|
15
15
|
aws-partitions (~> 1, >= 1.239.0)
|
16
16
|
aws-sigv4 (~> 1.1)
|
17
17
|
jmespath (~> 1.0)
|
18
|
-
aws-sdk-ec2 (1.
|
18
|
+
aws-sdk-ec2 (1.186.0)
|
19
19
|
aws-sdk-core (~> 3, >= 3.99.0)
|
20
20
|
aws-sigv4 (~> 1.1)
|
21
|
-
aws-sigv4 (1.2.
|
21
|
+
aws-sigv4 (1.2.1)
|
22
22
|
aws-eventstream (~> 1, >= 1.0.2)
|
23
23
|
coderay (1.1.2)
|
24
24
|
diff-lcs (1.3)
|
data/exe/aell
CHANGED
@@ -52,6 +52,7 @@ options = {
|
|
52
52
|
secret_access_key: AWS_SECRET_ACCESS_KEY,
|
53
53
|
session_token: AWS_SESSION_TOKEN,
|
54
54
|
region: AWS_REGION,
|
55
|
+
verify_host_key: :never,
|
55
56
|
}
|
56
57
|
|
57
58
|
class Hash
|
@@ -86,6 +87,14 @@ BANNER
|
|
86
87
|
options[:user] = user
|
87
88
|
end
|
88
89
|
|
90
|
+
opts.on("--single", "Only runs in one host") do
|
91
|
+
options[:single] = true
|
92
|
+
end
|
93
|
+
|
94
|
+
opts.on("--verify-host-key HOST_VERIFICATION", "Check host key when connecting (never, accept_new_or_local_tunnel, accept_new or always), default: never") do |host_verification|
|
95
|
+
options[:verify_host_key] = host_verification.to_sym
|
96
|
+
end
|
97
|
+
|
89
98
|
opts.on("-v", "--version", "Shows aell version") do
|
90
99
|
puts Aell::VERSION
|
91
100
|
exit
|
@@ -120,13 +129,17 @@ end.parse!
|
|
120
129
|
|
121
130
|
verify_options!(options)
|
122
131
|
|
123
|
-
servers = options[:hosts] || get_servers_ips(**options.except(:user, :hosts, :command))
|
132
|
+
servers = options[:hosts] || get_servers_ips(**options.except(:user, :hosts, :command, :single, :verify_host_key))
|
133
|
+
|
134
|
+
servers = [servers.first] if options[:single]
|
124
135
|
|
125
136
|
begin
|
126
137
|
Thread.report_on_exception = false
|
127
138
|
Net::SSH::Multi.start do |session|
|
128
139
|
servers.each do |server|
|
129
|
-
|
140
|
+
connection = options[:user] ? "#{options[:user]}@#{server}" : server
|
141
|
+
|
142
|
+
session.use(connection, verify_host_key: options[:verify_host_key])
|
130
143
|
end
|
131
144
|
|
132
145
|
session.exec options[:command]
|
data/lib/aell/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: aell
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.3.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Carlos Atkinson
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2021-01-26 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: aws-sdk-ec2
|