lib/beaker-pe/install/pe_utils.rb in beaker-pe-2.11.16 vs lib/beaker-pe/install/pe_utils.rb in beaker-pe-2.11.17
- old
+ new
@@ -882,10 +882,11 @@
# If we're installing a database version less than 3.0, ignore the database host
install_hosts.delete(database) if pre30database and database != master and database != dashboard
end
install_hosts.each do |host|
+ solaris_key_chain_fix
if agent_only_check_needed && hosts_agent_only.include?(host) || install_via_msi?(host)
host['type'] = 'aio'
install_params = {
:puppet_agent_version => get_puppet_agent_version(host, opts),
@@ -1330,10 +1331,64 @@
end
answers
end
+ # If installing older versions of solaris, make sure the DigiCert cert is added to the keychain
+ def solaris_key_chain_fix
+digicert = <<-EOM
+-----BEGIN CERTIFICATE-----
+MIIFkDCCA3igAwIBAgIQBZsbV56OITLiOQe9p3d1XDANBgkqhkiG9w0BAQwFADBi
+MQswCQYDVQQGEwJVUzEVMBMGA1UEChMMRGlnaUNlcnQgSW5jMRkwFwYDVQQLExB3
+d3cuZGlnaWNlcnQuY29tMSEwHwYDVQQDExhEaWdpQ2VydCBUcnVzdGVkIFJvb3Qg
+RzQwHhcNMTMwODAxMTIwMDAwWhcNMzgwMTE1MTIwMDAwWjBiMQswCQYDVQQGEwJV
+UzEVMBMGA1UEChMMRGlnaUNlcnQgSW5jMRkwFwYDVQQLExB3d3cuZGlnaWNlcnQu
+Y29tMSEwHwYDVQQDExhEaWdpQ2VydCBUcnVzdGVkIFJvb3QgRzQwggIiMA0GCSqG
+SIb3DQEBAQUAA4ICDwAwggIKAoICAQC/5pBzaN675F1KPDAiMGkz7MKnJS7JIT3y
+ithZwuEppz1Yq3aaza57G4QNxDAf8xukOBbrVsaXbR2rsnnyyhHS5F/WBTxSD1If
+xp4VpX6+n6lXFllVcq9ok3DCsrp1mWpzMpTREEQQLt+C8weE5nQ7bXHiLQwb7iDV
+ySAdYyktzuxeTsiT+CFhmzTrBcZe7FsavOvJz82sNEBfsXpm7nfISKhmV1efVFiO
+DCu3T6cw2Vbuyntd463JT17lNecxy9qTXtyOj4Dat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UaCKKsnOeMzV6ocEGLPOr0mI
+r/OSmbaz5mEP0oUA51Aa5BuVnRmhuZyxm7EAHu/QD09CbMkKvO5D+jpxpchNJqU1
+/YldvIViHTLSoCtU7ZpXwdv6EM8Zt4tKG48BtieVU+i2iW1bvGjUI+iLUaJW+fCm
+gKDWHrO8Dw9TdSmq6hN35N6MgSGtBxBHEa2HPQfRdbzP82Z+
+-----END CERTIFICATE-----
+EOM
+ hosts.each do |host|
+ if host.platform=~ /solaris-11(\.2)?-(i386|sparc)/
+ create_remote_file(host, "DigiCertTrustedRootG4.crt.pem", digicert)
+ on(host, 'chmod a+r /root/DigiCertTrustedRootG4.crt.pem')
+ on(host, 'cp -p /root/DigiCertTrustedRootG4.crt.pem /etc/certs/CA/')
+ on(host, 'rm /root/DigiCertTrustedRootG4.crt.pem')
+ on(host, '/usr/sbin/svcadm restart /system/ca-certificates')
+ timeout = 60
+ counter = 0
+ while on(host, 'svcs -x ca-certificates').output !~ /State: online/ do
+ raise 'ca-certificates services failed start up' if counter > timeout
+ sleep 5
+ counter = counter + 5
+ end
+ end
+ end
+ end
+
# Builds the agent_only and not_agent_only arrays needed for installation.
#
# @param [Array<Host>] hosts hosts to split up into the arrays
#
# @note should only be called against versions 4.0+, as this method
@@ -2014,9 +2069,10 @@
# Method to install just the agent nodes
# This method can be called only after installing PE on infrastructure nodes
# @param [Array] agent only nodes from Beaker hosts
# @param [Hash] opts The Beaker options hash
def install_agents_only_on(agent_nodes, opts)
+ solaris_key_chain_fix
unless agent_nodes.empty?
configure_type_defaults_on(agent_nodes)
step "Setup frictionless installer on the master" do
agent_nodes.each do |agent|