Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- node 'mysql.tor1.example.com' {
- include basenode
- include mysql_backup
- include postgres_backup
- $puppetdb_db_name = hiera('puppetdb_db_name')
- $puppetdb_db_user = hiera('puppetdb_db_user')
- $puppetdb_db_passwd = hiera('puppetdb_db_passwd')
- class { 'postgresql::globals':
- encoding => 'UTF-8',
- version => '95',
- } ->
- class { 'postgresql::server':
- pg_hba_conf_defaults => false,
- listen_addresses => ['localhost', $ipaddress_vtnet1],
- }
- postgresql::server::role{$puppetdb_db_user:
- password_hash => postgresql_password($puppetdb_db_user, $puppetdb_db_passwd),
- } ->
- postgresql::server::db{$puppetdb_db_name:
- user => $puppetdb_db_user,
- password => postgresql_password($puppetdb_db_user, $puppetdb_db_passwd),
- owner => $puppetdb_db_user,
- encoding => 'UTF-8',
- }
- postgresql::server::pg_hba_rule{'allow application network access':
- description => '"local" is for Unix domain socket connections only',
- type => 'local',
- database => 'all',
- user => 'all',
- auth_method => 'trust',
- }
- postgresql::server::pg_hba_rule{'IPv4 local connections':
- description => 'IPv4 local connections',
- type => 'host',
- database => 'all',
- user => 'all',
- address => '127.0.0.1/32',
- auth_method => 'trust',
- }
- postgresql::server::pg_hba_rule{'wattersm connections':
- description => 'wattersm connections',
- type => 'host',
- database => 'all',
- user => 'wattersm',
- address => '10.137.255.115/32',
- auth_method => 'md5',
- }
- postgresql::server::pg_hba_rule{'puppetdb connections':
- description => 'puppetdb connections',
- type => 'host',
- database => $puppetdb_db_name,
- user => $puppetdb_db_user,
- address => '10.137.64.139/32',
- auth_method => 'md5',
- }
- postgresql::server::pg_hba_rule{'IPv6 local connections':
- description => 'IPv6 local connections',
- type => 'host',
- database => 'all',
- user => 'all',
- address => '::1/128',
- auth_method => 'md5',
- }
- package { 'postgresql95-contrib':
- ensure => installed,
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement