File tree 3 files changed +21
-4
lines changed
3 files changed +21
-4
lines changed Original file line number Diff line number Diff line change
1
+ HOSTS :
2
+ ubuntu-server-1404-x64 :
3
+ roles :
4
+ - master
5
+ platform : ubuntu-14.04-64
6
+ box : puppetlabs/ubuntu-14.04-64-nocm
7
+ hypervisor : vagrant
8
+ CONFIG :
9
+ type : foss
Original file line number Diff line number Diff line change @@ -28,15 +28,15 @@ class { 'postgresql::server': }
28
28
pp = <<-EOS . unindent
29
29
class { 'postgresql::server': }
30
30
31
- postgresql::server::config_entry { 'test_listen_addresses ':
32
- value => '0.0.0.0 ',
31
+ postgresql::server::config_entry { 'log_directory ':
32
+ value => '/tmp/testfile ',
33
33
}
34
34
EOS
35
35
36
36
apply_manifest ( pp , :catch_failures => true )
37
37
38
38
psql ( '--command="show all" postgres' ) do |r |
39
- r . stdout . should =~ /test_listen_adresses.+0 \. 0 \. 0 \. 0 /
39
+ r . stdout . should =~ /log_directory.+ \/ tmp \/ testfile /
40
40
r . stderr . should be_empty
41
41
r . exit_code . should == 0
42
42
end
Original file line number Diff line number Diff line change 1
1
require 'spec_helper_acceptance'
2
2
3
+ # Hack around the fact that so far only Ubuntu 14.04 seems to have moved this
4
+ # file. Can revisit if everyone else gets clever.
5
+ if fact ( 'operatingsystem' ) == 'Ubuntu' && fact ( 'operatingsystemrelease' ) == '14.04'
6
+ pghba_file = '/etc/postgresql/9.3/main/pg_hba.conf'
7
+ else
8
+ pghba_file = '/var/lib/pgsql/data/pg_hba.conf'
9
+ end
10
+
3
11
describe 'server:' , :unless => UNSUPPORTED_PLATFORMS . include? ( fact ( 'osfamily' ) ) do
4
12
after :all do
5
13
# Cleanup after tests have ran
@@ -19,7 +27,7 @@ class { 'postgresql::server': }
19
27
it { should be_listening }
20
28
end
21
29
22
- describe file ( '/var/lib/pgsql/data/pg_hba.conf' ) do
30
+ describe file ( pghba_file ) do
23
31
it { should be_file }
24
32
it { should be_owned_by 'postgres' }
25
33
it { should be_grouped_into 'postgres' }
You can’t perform that action at this time.
0 commit comments