2 stop on pld.shutdown-started
3 stop on stopping postgresql
7 env DATADIR=/var/lib/pgsql
10 exec >>/var/log/pgsql 2>&1
12 # please note: 'pg_ctl start' does not work with 'expect daemon'
13 # nor 'expect fork', so we need to start postgres directly
14 exec /sbin/setuidgid -s postgres \
15 /usr/bin/postgres -D $DATADIR
18 # TODO: wait for the server in post-start