|
4 | 4 | unless ENV['RS_PROVISION'] == 'no' or ENV['BEAKER_provision'] == 'no' |
5 | 5 | # This will install the latest available package on el and deb based |
6 | 6 | # systems fail on windows and osx, and install via gem on other *nixes |
7 | | - foss_opts = { :default_action => 'gem_install' } |
| 7 | + foss_opts = {:default_action => 'gem_install'} |
8 | 8 |
|
9 | | - if default.is_pe?; then install_pe; else install_puppet( foss_opts ); end |
| 9 | + if default.is_pe?; then |
| 10 | + install_pe; |
| 11 | + else |
| 12 | + install_puppet(foss_opts); |
| 13 | + end |
10 | 14 |
|
11 | 15 | hosts.each do |host| |
12 | 16 | on hosts, "mkdir -p #{host['distmoduledir']}" |
|
25 | 29 | # Install module and dependencies |
26 | 30 | hosts.each do |host| |
27 | 31 | if fact_on(host, 'osfamily') == 'windows' |
28 | | - on host, 'powershell.exe -command "(New-Object System.Net.Webclient).DownloadString(\'https://forge.puppetlabs.com\')"' |
| 32 | + pp = <<EOS |
| 33 | + exec{'download-cert': |
| 34 | + path => ['C:\Windows\System32\WindowsPowershell\v1.0','C:\Windows\Sysnative\WindowsPowershell\v1.0'], |
| 35 | + command => 'powershell.exe -command "(New-Object System.Net.Webclient).DownloadString(\"https://forge.puppetlabs.com\")"', |
| 36 | + } |
| 37 | +EOS |
| 38 | + apply_manifest_on(host, pp) |
29 | 39 | end |
30 | 40 |
|
31 | 41 | on host, "mkdir -p #{host['distmoduledir']}/concat" |
|
36 | 46 | scp_to host, "#{proj_root}/#{file}", target |
37 | 47 | end |
38 | 48 | #copy_module_to(host, :source => proj_root, :module_name => 'concat') |
39 | | - on host, puppet('module','install','puppetlabs-stdlib'), { :acceptable_exit_codes => [0,1] } |
| 49 | + on host, puppet('module', 'install', 'puppetlabs-stdlib'), {:acceptable_exit_codes => [0, 1]} |
40 | 50 | end |
41 | 51 | end |
42 | 52 |
|
|
0 commit comments