File tree Expand file tree Collapse file tree 4 files changed +8
-24
lines changed Expand file tree Collapse file tree 4 files changed +8
-24
lines changed Original file line number Diff line number Diff line change 5252
5353 context 'with server cert' do
5454 before ( :context ) do
55- [ 'crt' , 'key' ] . each do |ext |
56- source_path = "fixtures/example.partial.solutions.#{ ext } "
57- dest_path = "/server.#{ ext } "
58- scp_to ( hosts , source_path , dest_path )
59- end
60-
6155 # Force regen
6256 on hosts , "if [ -e /root/ssl-build/#{ fact ( 'fqdn' ) } ] ; then touch /root/ssl-build/#{ fact ( 'fqdn' ) } /#{ fact ( 'fqdn' ) } -apache.update ; fi"
6357 end
@@ -134,12 +128,6 @@ class { 'certs::apache':
134128
135129 context 'with custom certificates fresh' do
136130 before ( :context ) do
137- [ 'crt' , 'key' ] . each do |ext |
138- source_path = "fixtures/example.partial.solutions.#{ ext } "
139- dest_path = "/server.#{ ext } "
140- scp_to ( hosts , source_path , dest_path )
141- end
142-
143131 on hosts , 'rm -rf /root/ssl-build'
144132 end
145133
Original file line number Diff line number Diff line change @@ -126,12 +126,6 @@ class { 'certs':
126126 end
127127
128128 context 'with server CA cert' do
129- before ( :context ) do
130- source_path = "fixtures/example.partial.solutions-chain.pem"
131- dest_path = "/server-ca.crt"
132- scp_to ( hosts , source_path , dest_path )
133- end
134-
135129 it_behaves_like 'an idempotent resource' do
136130 let ( :manifest ) do
137131 <<-PUPPET
Original file line number Diff line number Diff line change 164164
165165 context 'with custom certificates fresh' do
166166 before ( :context ) do
167- [ 'crt' , 'key' ] . each do |ext |
168- source_path = "fixtures/example.partial.solutions.#{ ext } "
169- dest_path = "/server.#{ ext } "
170- scp_to ( hosts , source_path , dest_path )
171- end
172-
173167 on hosts , 'rm -rf /root/ssl-build'
174168 end
175169
Original file line number Diff line number Diff line change 1+ certs = {
2+ 'fixtures/example.partial.solutions.crt' => '/server.crt' ,
3+ 'fixtures/example.partial.solutions.key' => '/server.key' ,
4+ 'fixtures/example.partial.solutions-chain.pem' => '/server-ca.crt' ,
5+ }
6+ certs . each do |source_path , dest_path |
7+ scp_to ( hosts , source_path , dest_path )
8+ end
You can’t perform that action at this time.
0 commit comments