[type/__postgres_role] Include postgres_user explorer from __postgres_conf

This commit is contained in:
Dennis Camera 2021-04-15 16:48:51 +02:00
parent 58b279a8d0
commit beb8da6d5f
3 changed files with 3 additions and 27 deletions

View file

@ -0,0 +1 @@
../../__postgres_conf/explorer/postgres_user

View file

@ -19,19 +19,7 @@
# along with cdist. If not, see <http://www.gnu.org/licenses/>. # along with cdist. If not, see <http://www.gnu.org/licenses/>.
# #
case $("${__explorer:?}/os") postgres_user=$("${__type_explorer:?}/postgres_user")
in
(netbsd)
postgres_user='pgsql'
;;
(openbsd)
postgres_user='_postgresql'
;;
(*)
postgres_user='postgres'
;;
esac
rolename=${__object_id:?} rolename=${__object_id:?}

View file

@ -28,20 +28,7 @@ quote() {
fi | sed "s/'/'\\\\''/g;1s/^/'/;\$s/\$/'/" fi | sed "s/'/'\\\\''/g;1s/^/'/;\$s/\$/'/"
} }
case $(cat "${__global:?}/explorer/os") postgres_user=$(cat "${__object:?}/explorer/postgres_user")
in
(netbsd)
postgres_user='pgsql'
;;
(openbsd)
postgres_user='_postgresql'
;;
(*)
postgres_user='postgres'
;;
esac
rolename=${__object_id:?} rolename=${__object_id:?}
state_is=$(cat "${__object:?}/explorer/state") state_is=$(cat "${__object:?}/explorer/state")
state_should=$(cat "${__object:?}/parameter/state") state_should=$(cat "${__object:?}/parameter/state")