norad_spec_runner 0.3.1 → 0.3.2
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 +4 -4
- data/lib/norad_spec_runner/cli.rb +1 -0
- data/lib/norad_spec_runner/remote_task.rb +3 -1
- data/lib/norad_spec_runner/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: 59ba4e5d2d5469e6262dd96132ef61dac1b93b86
|
4
|
+
data.tar.gz: b90b2f3acb7759badafb7aa7c6ec863c91b6d508
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: bc171bd51a7232c3001872fde7cd0960b7e53c4a697616facd014e2041e63140db15de6462df135c7ebb4a29f2dbf8f887735805f65d964b6c5d2b073f10c761
|
7
|
+
data.tar.gz: 0bee9549392b184b2c6e2c0e95546f73c744932cbca47a0c717b6fd0fbf4f5a47b60a8250b7110161fc68e167a96ec885885e84ae6a409741156d8c318b54ff3
|
@@ -19,6 +19,7 @@ module NoradSpecRunner
|
|
19
19
|
method_option :sub_tests, :aliases => '-s', :desc => 'Specific test from given RSpec file', :default => '\'\''
|
20
20
|
method_option :results_file, :aliases => '-r', :desc => 'File to store the results'
|
21
21
|
method_option :port, :aliases => '-p', :desc => 'Port to connect on', :default => 22
|
22
|
+
method_option :cisco_enable_pw, :desc => 'Password to enter Enable mode in Cisco IOS', :default => ''
|
22
23
|
method_option :detect_os, :desc => 'Whether or not to perform OS detection', :type => :boolean, :default => false
|
23
24
|
|
24
25
|
def remote(encoded_key)
|
@@ -8,11 +8,12 @@ module NoradSpecRunner
|
|
8
8
|
class RemoteTask < Task
|
9
9
|
SSH_TIMEOUT = 10
|
10
10
|
|
11
|
-
attr_reader :host, :username, :sshkey, :ssh_port, :obj, :platform, :results_file
|
11
|
+
attr_reader :host, :username, :sshkey, :ssh_port, :obj, :platform, :results_file, :cisco_enable_pw
|
12
12
|
|
13
13
|
def initialize(encoded_key, options)
|
14
14
|
@host = options.fetch(:host)
|
15
15
|
@sshkey = options.fetch(:sshkey)
|
16
|
+
@cisco_enable_pw = options.fetch(:cisco_enable_pw, '')
|
16
17
|
# Decode the key and store
|
17
18
|
File.open(@sshkey, "w") do |f|
|
18
19
|
f.write Base64.decode64(encoded_key)
|
@@ -41,6 +42,7 @@ module NoradSpecRunner
|
|
41
42
|
ENV['AUDIT_USERNAME'] = username
|
42
43
|
ENV['AUDIT_SSHKEY'] = sshkey
|
43
44
|
ENV['AUDIT_SSH_PORT'] = ssh_port
|
45
|
+
ENV['AUDIT_CISCO_ENABLE_PASSWORD'] = cisco_enable_pw
|
44
46
|
|
45
47
|
# Capture STDERR for SSH related errors
|
46
48
|
STDERR.reopen(ftmp)
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: norad_spec_runner
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.3.
|
4
|
+
version: 0.3.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Brian Manifold
|
@@ -10,7 +10,7 @@ authors:
|
|
10
10
|
autorequire:
|
11
11
|
bindir: bin
|
12
12
|
cert_chain: []
|
13
|
-
date: 2017-03-
|
13
|
+
date: 2017-03-17 00:00:00.000000000 Z
|
14
14
|
dependencies:
|
15
15
|
- !ruby/object:Gem::Dependency
|
16
16
|
name: serverspec
|