diff options
author | Daniel J Walsh <dwalsh@fedoraproject.org> | 2005-01-11 20:20:45 +0000 |
---|---|---|
committer | Daniel J Walsh <dwalsh@fedoraproject.org> | 2005-01-11 20:20:45 +0000 |
commit | a884bda9879e83d55764818ca172b5d8486f3849 (patch) | |
tree | e08f91c4946b20c9103af6f33b8cbe1534cb295c /postgresql.init | |
parent | ec364abd8ac0e5afdc6dc6c9fa3e56e79c1585f7 (diff) | |
download | postgresql-setup-a884bda9879e83d55764818ca172b5d8486f3849.tar.gz postgresql-setup-a884bda9879e83d55764818ca172b5d8486f3849.tar.xz postgresql-setup-a884bda9879e83d55764818ca172b5d8486f3849.zip |
- Add restorecon to postgresql.init in order to restore database to correctpostgresql-7_4_6-4
- SELinux context.
Diffstat (limited to 'postgresql.init')
-rw-r--r-- | postgresql.init | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/postgresql.init b/postgresql.init index 9f41e9e..fc98742 100644 --- a/postgresql.init +++ b/postgresql.init @@ -94,6 +94,7 @@ fi # Set defaults for configuration variables PGENGINE=/usr/bin PGPORT=5432 +export PGDATADIR=/var/lib/pgsql export PGDATA=/var/lib/pgsql if [ -f $PGDATA/PG_VERSION ] && [ -d $PGDATA/base/template1 ] then @@ -165,6 +166,7 @@ start(){ mkdir -p $PGDATA || exit 1 chown postgres:postgres $PGDATA chmod go-rwx $PGDATA + [ -x /sbin/restorecon ] && restorecon $PGDATADIR fi # Make sure the locale from the initdb is preserved for later startups... [ -f /etc/sysconfig/i18n ] && cp /etc/sysconfig/i18n $PGDATA/../initdb.i18n |