foreman_remote_execution_core 1.4.4 → 1.4.8
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: 465e9c409286d4bd5501a4e69ce110c449ef4ab4288ef401276231e3498feaad
|
|
4
|
+
data.tar.gz: 73bc72cbac7038f7356499f638e517f00ffb9396eb36c63c5751fb985958cd22
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: d7bd2eab26b331d80adb66481fa1e3d34b698fbdfab781000216f93e9c627b36f46ba8c614c8c6f286b92c6cd39db59448d524fb2ea159c4535e2a40fa44b786
|
|
7
|
+
data.tar.gz: 621b23721f0346fb4dcf9b70133174f7bf7c1c24d917f7f3bc8f0f8595d9814ff1a977888927e370b32c4674bf62313c91d48850b5523e18a6c5a65c98db5a94
|
|
@@ -105,6 +105,8 @@ module ForemanRemoteExecutionCore
|
|
|
105
105
|
EXPECTED_POWER_ACTION_MESSAGES = ['restart host', 'shutdown host'].freeze
|
|
106
106
|
DEFAULT_REFRESH_INTERVAL = 1
|
|
107
107
|
MAX_PROCESS_RETRIES = 4
|
|
108
|
+
VERIFY_HOST_KEY = Gem::Version.create(Net::SSH::Version::STRING) < Gem::Version.create('5.0.0') ||
|
|
109
|
+
:accept_new_or_local_tunnel
|
|
108
110
|
|
|
109
111
|
def initialize(options, user_method, suspended_action: nil)
|
|
110
112
|
super suspended_action: suspended_action
|
|
@@ -155,7 +157,7 @@ module ForemanRemoteExecutionCore
|
|
|
155
157
|
script = initialization_script
|
|
156
158
|
logger.debug("executing script:\n#{indent_multiline(script)}")
|
|
157
159
|
trigger(script)
|
|
158
|
-
rescue => e
|
|
160
|
+
rescue StandardError, NotImplementedError => e
|
|
159
161
|
logger.error("error while initalizing command #{e.class} #{e.message}:\n #{e.backtrace.join("\n")}")
|
|
160
162
|
publish_exception('Error initializing command', e)
|
|
161
163
|
end
|
|
@@ -278,7 +280,7 @@ module ForemanRemoteExecutionCore
|
|
|
278
280
|
ssh_options[:keys_only] = true
|
|
279
281
|
# if the host public key is contained in the known_hosts_file,
|
|
280
282
|
# verify it, otherwise, if missing, import it and continue
|
|
281
|
-
ssh_options[:
|
|
283
|
+
ssh_options[:verify_host_key] = VERIFY_HOST_KEY
|
|
282
284
|
ssh_options[:auth_methods] = available_authentication_methods
|
|
283
285
|
ssh_options[:user_known_hosts_file] = prepare_known_hosts if @host_public_key
|
|
284
286
|
ssh_options[:number_of_password_prompts] = 1
|
|
@@ -3,7 +3,7 @@ require 'open3'
|
|
|
3
3
|
module ForemanRemoteExecutionCore
|
|
4
4
|
module Utils
|
|
5
5
|
class << self
|
|
6
|
-
def prune_known_hosts(hostname, port, logger = Logger.new($stdout))
|
|
6
|
+
def prune_known_hosts!(hostname, port, logger = Logger.new($stdout))
|
|
7
7
|
return if Net::SSH::KnownHosts.search_for(hostname).empty?
|
|
8
8
|
|
|
9
9
|
target = if port == 22
|
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: foreman_remote_execution_core
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 1.4.
|
|
4
|
+
version: 1.4.8
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Ivan Nečas
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: bin
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2021-
|
|
11
|
+
date: 2021-08-17 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: bcrypt_pbkdf
|
|
@@ -58,14 +58,14 @@ dependencies:
|
|
|
58
58
|
requirements:
|
|
59
59
|
- - ">="
|
|
60
60
|
- !ruby/object:Gem::Version
|
|
61
|
-
version:
|
|
61
|
+
version: 4.2.0
|
|
62
62
|
type: :runtime
|
|
63
63
|
prerelease: false
|
|
64
64
|
version_requirements: !ruby/object:Gem::Requirement
|
|
65
65
|
requirements:
|
|
66
66
|
- - ">="
|
|
67
67
|
- !ruby/object:Gem::Version
|
|
68
|
-
version:
|
|
68
|
+
version: 4.2.0
|
|
69
69
|
description: " Ssh remote execution provider code sharable between Foreman and Foreman-Proxy\n"
|
|
70
70
|
email:
|
|
71
71
|
- inecas@redhat.com
|