dataset/seed/applicationservice/2022.03.08/postgresql-server/templates/postgresql_init

15 lines
340 B
Text
Raw Normal View History

2022-03-08 19:42:28 +01:00
#!/bin/bash -e
[ -d "/srv/postgresql" ] && exit 0 || true
/bin/mkdir /srv/postgresql
/bin/chown postgres: /srv/postgresql
mkdir /var/lib/pgsql
/bin/chown postgres: /var/lib/pgsql
/usr/bin/postgresql-setup --initdb
/bin/rm /srv/postgresql/postgresql.conf
/bin/rm /srv/postgresql/pg_hba.conf
/bin/rm /srv/postgresql/pg_ident.conf
exit 0