opswalrus 1.0.108 → 1.0.110
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Gemfile.lock +1 -1
- data/lib/opswalrus/host.rb +2 -2
- data/lib/opswalrus/local_non_blocking_backend.rb +4 -2
- data/lib/opswalrus/local_pty_backend.rb +3 -1
- data/lib/opswalrus/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: d1547e47df7a32fcfa9d418c6002c20aa1c79947aaafceacf6447823b300703c
|
4
|
+
data.tar.gz: 0cc147d636b6fc568106295233a6a30e476257fbf49d56e5c0f7072b046e33ed
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 19dfecd617331e1d3b900a6a70100ebadd312d1a2347d23f3f53daa8b2f3b5e2f8fe1230db8855daf0de2f7a7ab61737d17aa65aaad42cfa56e19d9b9b4888ba
|
7
|
+
data.tar.gz: 76dc51991fc073a8372bdd22f976403e675d668f11d36e306ca47d11823b5dcfb8de6667ecebb55a9c0796bf8470715a977b523927fbeb0f0f1656dff3a14b9e
|
data/Gemfile.lock
CHANGED
data/lib/opswalrus/host.rb
CHANGED
@@ -160,12 +160,12 @@ module OpsWalrus
|
|
160
160
|
}
|
161
161
|
end
|
162
162
|
|
163
|
-
def autoretry(delay: 5, timeout: 300, &block)
|
163
|
+
def autoretry(delay: 5, timeout: 300, limit: 3, &block)
|
164
164
|
attempts ||= 0
|
165
165
|
attempts += 1
|
166
166
|
block.call
|
167
167
|
rescue RetriableRemoteInvocationError => e
|
168
|
-
if attempts <=
|
168
|
+
if attempts <= limit
|
169
169
|
reconnected = reconnect(delay, timeout)
|
170
170
|
retry if reconnected
|
171
171
|
end
|
@@ -34,7 +34,8 @@ module SSHKit
|
|
34
34
|
# per https://stackoverflow.com/questions/1154846/continuously-read-from-stdout-of-external-process-in-ruby
|
35
35
|
# and https://stackoverflow.com/questions/10238298/ruby-on-linux-pty-goes-away-without-eof-raises-errnoeio
|
36
36
|
# the PTY can raise an Errno::EIO because the child process unexpectedly goes away
|
37
|
-
|
37
|
+
# Errno::ENOENT seems to be kind of like EIO
|
38
|
+
rescue EOFError, Errno::EIO, Errno::ENOENT
|
38
39
|
# puts "eof!"
|
39
40
|
handle_data_for_stdout(output, cmd, buffer, stdin, true)
|
40
41
|
stdout.close
|
@@ -68,7 +69,8 @@ module SSHKit
|
|
68
69
|
# per https://stackoverflow.com/questions/1154846/continuously-read-from-stdout-of-external-process-in-ruby
|
69
70
|
# and https://stackoverflow.com/questions/10238298/ruby-on-linux-pty-goes-away-without-eof-raises-errnoeio
|
70
71
|
# the PTY can raise an Errno::EIO because the child process unexpectedly goes away
|
71
|
-
|
72
|
+
# Errno::ENOENT seems to behave like EIO
|
73
|
+
rescue EOFError, Errno::EIO, Errno::ENOENT
|
72
74
|
# puts "eof!"
|
73
75
|
handle_data_for_stderr(output, cmd, buffer, stdin, true)
|
74
76
|
stderr.close
|
@@ -40,7 +40,8 @@ module SSHKit
|
|
40
40
|
# per https://stackoverflow.com/questions/1154846/continuously-read-from-stdout-of-external-process-in-ruby
|
41
41
|
# and https://stackoverflow.com/questions/10238298/ruby-on-linux-pty-goes-away-without-eof-raises-errnoeio
|
42
42
|
# the PTY can raise an Errno::EIO because the child process unexpectedly goes away
|
43
|
-
|
43
|
+
# Errno::ENOENT seems to behave like EIO
|
44
|
+
rescue EOFError, Errno::EIO, Errno::ENOENT
|
44
45
|
# puts "eof!"
|
45
46
|
handle_data_for_stdout(output, cmd, buffer, stdin, true)
|
46
47
|
stdout.close
|
@@ -64,6 +65,7 @@ module SSHKit
|
|
64
65
|
# stderr_writer.close
|
65
66
|
# output.log_command_data(cmd, :stderr, stderr_reader.read)
|
66
67
|
cmd.exit_status = status.exitstatus
|
68
|
+
ensure
|
67
69
|
output.log_command_exit(cmd)
|
68
70
|
end
|
69
71
|
# ensure
|
data/lib/opswalrus/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: opswalrus
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.0.
|
4
|
+
version: 1.0.110
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- David Ellis
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2024-01-
|
11
|
+
date: 2024-01-27 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: activesupport
|