Skip to content

Commit 4385827

Browse files
authored
Merge pull request #2786 from austb/pe-37178-ubuntu-18-pg-fix
(PE-37178) bionic tests - install pg from archive
2 parents c6900cd + dc822b5 commit 4385827

File tree

1 file changed

+12
-1
lines changed

1 file changed

+12
-1
lines changed

acceptance/suites/pre_suite/foss/95_install_pdb.rb

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,15 @@
1010
on(master, "rm -f #{sitepp}")
1111
end
1212

13+
step 'Update Ubuntu 18 package repo' do
14+
if master.platform =~ /ubuntu-18/
15+
# bionic is EOL, so get postgresql from the archive
16+
on master, 'echo "deb https://apt-archive.postgresql.org/pub/repos/apt bionic-pgdg main" >> /etc/apt/sources.list'
17+
on master, 'curl https://www.postgresql.org/media/keys/ACCC4CF8.asc | sudo apt-key add -'
18+
on master, 'apt update'
19+
end
20+
end
21+
1322
step 'Install Puppet nightly repo' do
1423
install_puppetlabs_release_repo_on(master, 'puppet7-nightly')
1524
end
@@ -23,10 +32,12 @@
2332
end
2433

2534
step 'Configure PuppetDB via site.pp' do
35+
manage_package_repo = ! master.platform.match?(/ubuntu-18/)
2636
create_remote_file(master, sitepp, <<SITEPP)
2737
node default {
2838
class { 'puppetdb':
29-
manage_firewall => false,
39+
manage_firewall => false,
40+
manage_package_repo => #{manage_package_repo},
3041
}
3142
3243
class { 'puppetdb::master::config':

0 commit comments

Comments
 (0)