X-Git-Url: https://git.adam-barratt.org.uk/?a=blobdiff_plain;ds=sidebyside;f=modules%2Froles%2Fmanifests%2Fudd%2Fdb_guest_access.pp;h=4dc8f02e298b3594ad4c5b68cce2f81e4c9670c9;hb=faf0b00a7b3ef90757b7fcf9dec93c9987383f8a;hp=d848722ccd828c9fe4c22fca761a296f748683af;hpb=0ea057452a4fb807add958781fc70cd54189f98d;p=mirror%2Fdsa-puppet.git diff --git a/modules/roles/manifests/udd/db_guest_access.pp b/modules/roles/manifests/udd/db_guest_access.pp index d848722cc..4dc8f02e2 100644 --- a/modules/roles/manifests/udd/db_guest_access.pp +++ b/modules/roles/manifests/udd/db_guest_access.pp @@ -1,20 +1,25 @@ # udd guest access to DB # -# @param db_address hostname of the postgres server for this service -# @param db_port port of the postgres server for this service -# @param database list of databases to give access to +# @param db_address hostname of the postgres server for this service +# @param db_port port of the postgres server for this service +# @param database list of databases to give access to +# @param address hosts to give access +# @param connection_type connection type class roles::udd::db_guest_access ( String $db_address = $roles::udd::params::db_address, Integer $db_port = $roles::udd::params::db_port, - Array[String] $database = ['udd'] + Array[String] $database = ['udd'], + Enum['local', 'host', 'hostssl'] $connection_type = 'hostssl', + Optional[Variant[Stdlib::IP::Address, Array[Stdlib::IP::Address]]] $address = $base::public_addresses, ) inherits roles::udd::params { @@postgres::cluster::hba_entry { "udd-guest-${::fqdn}": - tag => "postgres::cluster::${db_port}::hba::${db_address}", - pg_port => $db_port, - database => $database, - user => 'guest', - address => $base::public_addresses, - method => 'trust', - order => '40', + tag => "postgres::cluster::${db_port}::hba::${db_address}", + pg_port => $db_port, + database => $database, + user => 'guest', + address => $address, + connection_type => $connection_type, + method => 'trust', + order => '25', } }