scooter 4.3.0 → 4.3.1
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
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 475a579ee226f7cc2aac1e40e35e70ab4fa4f8bf
|
4
|
+
data.tar.gz: 89fcedd1365b092db6007a29ecde1527999540f1
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 6671df80d51349d177624a2fb321b29df6b2a5d31839b349c9b402a7aad448e9a573d854f4f123d7273b833e6aa73eece55e9a174853f84fc8f50721b767e3d4
|
7
|
+
data.tar.gz: 98c0f4c448e52a201110711b2c49aed9658205d28959a49ad6059fef579398a3968ee5e773aca6f5f623c6dc1677d88990f07d07cbb1deb83b2fd84564ed1f48
|
@@ -76,14 +76,14 @@ module Scooter
|
|
76
76
|
# not a certificate dispatcher, but representing an LDAP or local user. If
|
77
77
|
# credentials are supplied during initialization, then this overrides the
|
78
78
|
# parent class and only acquires a ca_cert.
|
79
|
-
def
|
79
|
+
def configure_private_key_and_cert_with_puppet(host=self.host)
|
80
80
|
if credentials == nil
|
81
81
|
super(host)
|
82
82
|
else
|
83
83
|
if !host.is_a?(Unix::Host)
|
84
84
|
raise 'Can only acquire SSL certs if the host is a Unix::Host'
|
85
85
|
end
|
86
|
-
|
86
|
+
configure_cacert_with_puppet(host)
|
87
87
|
end
|
88
88
|
end
|
89
89
|
|
data/lib/scooter/version.rb
CHANGED
@@ -9,22 +9,20 @@ module Scooter
|
|
9
9
|
let(:username) {'Ziggy'}
|
10
10
|
let(:password) {'Stardust'}
|
11
11
|
let(:mock_page) {double('mock_page')}
|
12
|
+
let(:logger) { double('logger')}
|
12
13
|
|
13
14
|
subject { HttpDispatchers::ConsoleDispatcher.new(host, credentials) }
|
14
15
|
|
15
16
|
context 'with a beaker host passed in' do
|
16
|
-
let(:logger) { double('logger')}
|
17
17
|
unixhost = { roles: ['test_role'],
|
18
18
|
'platform' => 'debian-7-x86_64' }
|
19
19
|
let(:host) { Beaker::Host.create('test.com', unixhost, {:logger => logger}) }
|
20
20
|
before do
|
21
|
-
|
22
|
-
|
23
|
-
expect(OpenSSL::PKey).
|
24
|
-
expect(OpenSSL::X509::Certificate).
|
25
|
-
allow_any_instance_of(HttpDispatchers::
|
26
|
-
allow_any_instance_of(HttpDispatchers::HttpDispatcher).to receive(:get_host_private_key) {'key file'}
|
27
|
-
allow_any_instance_of(HttpDispatchers::HttpDispatcher).to receive(:get_host_cacert) {'cert file'}
|
21
|
+
allow(logger).to receive(:info) {true}
|
22
|
+
allow(logger).to receive(:debug) {true}
|
23
|
+
expect(OpenSSL::PKey).not_to receive(:read)
|
24
|
+
expect(OpenSSL::X509::Certificate).not_to receive(:new)
|
25
|
+
allow_any_instance_of(HttpDispatchers::ConsoleDispatcher).to receive(:configure_cacert_with_puppet).and_return('cacert')
|
28
26
|
expect(subject).to be_kind_of(HttpDispatchers::ConsoleDispatcher)
|
29
27
|
end
|
30
28
|
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: scooter
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 4.3.
|
4
|
+
version: 4.3.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Puppetlabs
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2019-01-16 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|