From 6a9197764f7d6f5bc7f321d45caaf66fd2dd6dd2 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Isma=C3=ABl=20Bouya?= Date: Sun, 18 Feb 2018 01:56:39 +0100 Subject: [PATCH] Add rules for localhost --- modules/role/manifests/cryptoportfolio.pp | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/modules/role/manifests/cryptoportfolio.pp b/modules/role/manifests/cryptoportfolio.pp index 2755fee..4b03e16 100644 --- a/modules/role/manifests/cryptoportfolio.pp +++ b/modules/role/manifests/cryptoportfolio.pp @@ -10,5 +10,21 @@ class role::cryptoportfolio { password => postgresql_password('cryptoportfolio', generate_password(24, $password_seed, "postgres_cryptoportfolio")), } + postgresql::server::pg_hba_rule { 'allow localhost TCP access to cryptoportfolio user': + type => 'host', + database => 'cryptoportfolio', + user => 'cryptoportfolio', + address => '127.0.0.1/32', + auth_method => 'md5', + order => "b0", + } + postgresql::server::pg_hba_rule { 'allow localhost ip6 TCP access to cryptoportfolio user': + type => 'host', + database => 'cryptoportfolio', + user => 'cryptoportfolio', + address => '::1/128', + auth_method => 'md5', + order => "b0", + } ensure_packages("go") } -- 2.41.0