Merge pull request #52 from md5/chown-run-postgresql
Ensure /run/postgresql has correct ownership and permissions
This commit is contained in:
commit
628ecb4975
|
|
@ -4,6 +4,9 @@ set -e
|
||||||
if [ "$1" = 'postgres' ]; then
|
if [ "$1" = 'postgres' ]; then
|
||||||
chown -R postgres "$PGDATA"
|
chown -R postgres "$PGDATA"
|
||||||
|
|
||||||
|
chmod g+s /run/postgresql
|
||||||
|
chown -R postgres:postgres /run/postgresql
|
||||||
|
|
||||||
if [ -z "$(ls -A "$PGDATA")" ]; then
|
if [ -z "$(ls -A "$PGDATA")" ]; then
|
||||||
gosu postgres initdb
|
gosu postgres initdb
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -4,6 +4,9 @@ set -e
|
||||||
if [ "$1" = 'postgres' ]; then
|
if [ "$1" = 'postgres' ]; then
|
||||||
chown -R postgres "$PGDATA"
|
chown -R postgres "$PGDATA"
|
||||||
|
|
||||||
|
chmod g+s /run/postgresql
|
||||||
|
chown -R postgres:postgres /run/postgresql
|
||||||
|
|
||||||
if [ -z "$(ls -A "$PGDATA")" ]; then
|
if [ -z "$(ls -A "$PGDATA")" ]; then
|
||||||
gosu postgres initdb
|
gosu postgres initdb
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -4,6 +4,9 @@ set -e
|
||||||
if [ "$1" = 'postgres' ]; then
|
if [ "$1" = 'postgres' ]; then
|
||||||
chown -R postgres "$PGDATA"
|
chown -R postgres "$PGDATA"
|
||||||
|
|
||||||
|
chmod g+s /run/postgresql
|
||||||
|
chown -R postgres:postgres /run/postgresql
|
||||||
|
|
||||||
if [ -z "$(ls -A "$PGDATA")" ]; then
|
if [ -z "$(ls -A "$PGDATA")" ]; then
|
||||||
gosu postgres initdb
|
gosu postgres initdb
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -4,6 +4,9 @@ set -e
|
||||||
if [ "$1" = 'postgres' ]; then
|
if [ "$1" = 'postgres' ]; then
|
||||||
chown -R postgres "$PGDATA"
|
chown -R postgres "$PGDATA"
|
||||||
|
|
||||||
|
chmod g+s /run/postgresql
|
||||||
|
chown -R postgres:postgres /run/postgresql
|
||||||
|
|
||||||
if [ -z "$(ls -A "$PGDATA")" ]; then
|
if [ -z "$(ls -A "$PGDATA")" ]; then
|
||||||
gosu postgres initdb
|
gosu postgres initdb
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -4,6 +4,9 @@ set -e
|
||||||
if [ "$1" = 'postgres' ]; then
|
if [ "$1" = 'postgres' ]; then
|
||||||
chown -R postgres "$PGDATA"
|
chown -R postgres "$PGDATA"
|
||||||
|
|
||||||
|
chmod g+s /run/postgresql
|
||||||
|
chown -R postgres:postgres /run/postgresql
|
||||||
|
|
||||||
if [ -z "$(ls -A "$PGDATA")" ]; then
|
if [ -z "$(ls -A "$PGDATA")" ]; then
|
||||||
gosu postgres initdb
|
gosu postgres initdb
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -4,6 +4,9 @@ set -e
|
||||||
if [ "$1" = 'postgres' ]; then
|
if [ "$1" = 'postgres' ]; then
|
||||||
chown -R postgres "$PGDATA"
|
chown -R postgres "$PGDATA"
|
||||||
|
|
||||||
|
chmod g+s /run/postgresql
|
||||||
|
chown -R postgres:postgres /run/postgresql
|
||||||
|
|
||||||
if [ -z "$(ls -A "$PGDATA")" ]; then
|
if [ -z "$(ls -A "$PGDATA")" ]; then
|
||||||
gosu postgres initdb
|
gosu postgres initdb
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -4,6 +4,9 @@ set -e
|
||||||
if [ "$1" = 'postgres' ]; then
|
if [ "$1" = 'postgres' ]; then
|
||||||
chown -R postgres "$PGDATA"
|
chown -R postgres "$PGDATA"
|
||||||
|
|
||||||
|
chmod g+s /run/postgresql
|
||||||
|
chown -R postgres:postgres /run/postgresql
|
||||||
|
|
||||||
if [ -z "$(ls -A "$PGDATA")" ]; then
|
if [ -z "$(ls -A "$PGDATA")" ]; then
|
||||||
gosu postgres initdb
|
gosu postgres initdb
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue