smart_proxy_remote_execution_ssh 1.0.2 → 1.0.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: da4cc9f46c877bbc7fc4e92db5dc13f140cbf59de86a0709749d67eaeceeaa46
|
|
4
|
+
data.tar.gz: f8192bcda0fdd9635a0616bf2668a4eac0376d5e026f07c2652d353f7b06addf
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: eb11312a369159202095cb7a3f5c215c3d83755ebd279f6d8d1eb43e3bb5cbe9c9a8cd81075a2903a4a8cd8c1475b0e823610a6d4c5065d2b489483240f48b5a
|
|
7
|
+
data.tar.gz: 57f7e5684a6649be4d02d51f18b4988c4826fb486fe7bb31bfa8a6ffb0b9124182dd3100148fbe3d46d771d687eaf56940d7d6b0ae8ba16ef025cb9c3d3c4056
|
|
@@ -22,7 +22,8 @@ module Proxy::RemoteExecution::Ssh::Runners
|
|
|
22
22
|
end
|
|
23
23
|
|
|
24
24
|
def filter_password?(received_data)
|
|
25
|
-
!@effective_user_password.empty? && @password_sent &&
|
|
25
|
+
!@effective_user_password.empty? && @password_sent &&
|
|
26
|
+
received_data.b.match(Regexp.new(Regexp.escape(@effective_user_password).b))
|
|
26
27
|
end
|
|
27
28
|
|
|
28
29
|
def sent_all_data?
|
|
@@ -112,7 +113,7 @@ module Proxy::RemoteExecution::Ssh::Runners
|
|
|
112
113
|
|
|
113
114
|
@client_private_key_file = settings.ssh_identity_key_file
|
|
114
115
|
@local_working_dir = options.fetch(:local_working_dir, settings.local_working_dir)
|
|
115
|
-
@remote_working_dir = options.fetch(:remote_working_dir, settings.remote_working_dir.shellescape
|
|
116
|
+
@remote_working_dir = absolute_path!(options.fetch(:remote_working_dir, settings.remote_working_dir)).shellescape
|
|
116
117
|
@socket_working_dir = options.fetch(:socket_working_dir, settings.socket_working_dir)
|
|
117
118
|
@cleanup_working_dirs = options.fetch(:cleanup_working_dirs, settings.cleanup_working_dirs)
|
|
118
119
|
@first_execution = options.fetch(:first_execution, false)
|
|
@@ -274,6 +275,13 @@ module Proxy::RemoteExecution::Ssh::Runners
|
|
|
274
275
|
string.lines.map { |line| " | #{line}" }.join
|
|
275
276
|
end
|
|
276
277
|
|
|
278
|
+
def absolute_path!(path)
|
|
279
|
+
path = path.to_s.strip
|
|
280
|
+
raise "Remote working directory '#{path}' is not an absolute path" unless Pathname.new(path).absolute?
|
|
281
|
+
|
|
282
|
+
path
|
|
283
|
+
end
|
|
284
|
+
|
|
277
285
|
def should_cleanup?
|
|
278
286
|
@process_manager && @cleanup_working_dirs
|
|
279
287
|
end
|
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: smart_proxy_remote_execution_ssh
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 1.0.
|
|
4
|
+
version: 1.0.4
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Ivan Nečas
|
|
@@ -233,7 +233,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
|
233
233
|
- !ruby/object:Gem::Version
|
|
234
234
|
version: '0'
|
|
235
235
|
requirements: []
|
|
236
|
-
rubygems_version: 4.0.
|
|
236
|
+
rubygems_version: 4.0.16
|
|
237
237
|
specification_version: 4
|
|
238
238
|
summary: Ssh remote execution provider for Foreman Smart-Proxy
|
|
239
239
|
test_files: []
|