|
2 | 2 | require 'beaker-rspec/helpers/serverspec' |
3 | 3 | require 'beaker/puppet_install_helper' |
4 | 4 | require 'beaker/module_install_helper' |
| 5 | +require 'beaker/task_helper' |
5 | 6 |
|
6 | 7 | run_puppet_install_helper |
7 | | -install_ca_certs unless ENV['PUPPET_INSTALL_TYPE'] =~ /pe/i |
| 8 | +install_ca_certs unless pe_install? |
8 | 9 |
|
9 | 10 | UNSUPPORTED_PLATFORMS = ['AIX','windows','Solaris','Suse'] |
10 | 11 |
|
@@ -35,10 +36,18 @@ def module_dependencies_from_metadata |
35 | 36 | end |
36 | 37 | end |
37 | 38 |
|
| 39 | + |
| 40 | +install_bolt_on(hosts) unless pe_install? |
38 | 41 | install_module_on(hosts) |
39 | 42 | install_module_dependencies_on(hosts) |
40 | 43 | install_module_from_forge_on(hosts,'puppetlabs/apt','< 4.2.0') |
41 | 44 |
|
| 45 | +DEFAULT_PASSWORD = if default[:hypervisor] == 'vagrant' |
| 46 | + 'vagrant' |
| 47 | + elsif default[:hypervisor] == 'vcloud' |
| 48 | + 'Qu@lity!' |
| 49 | + end |
| 50 | + |
42 | 51 | class String |
43 | 52 | # Provide ability to remove indentation from strings, for the purpose of |
44 | 53 | # left justifying heredoc blocks. |
@@ -78,6 +87,7 @@ def psql(psql_cmd, user = 'postgres', exit_codes = [0,1], &block) |
78 | 87 |
|
79 | 88 | # Configure all nodes in nodeset |
80 | 89 | c.before :suite do |
| 90 | + run_puppet_access_login(user: 'admin') if pe_install? |
81 | 91 | # Set up selinux if appropriate. |
82 | 92 | if fact('osfamily') == 'RedHat' && fact('selinux') == 'true' |
83 | 93 | pp = <<-EOS |
@@ -109,7 +119,6 @@ def psql(psql_cmd, user = 'postgres', exit_codes = [0,1], &block) |
109 | 119 | end |
110 | 120 |
|
111 | 121 | hosts.each do |host| |
112 | | - on host, "/bin/touch #{host['puppetpath']}/hiera.yaml" |
113 | 122 | on host, 'chmod 755 /root' |
114 | 123 | if fact_on(host, 'osfamily') == 'Debian' |
115 | 124 | on host, "echo \"en_US ISO-8859-1\nen_NG.UTF-8 UTF-8\nen_US.UTF-8 UTF-8\n\" > /etc/locale.gen" |
|
0 commit comments