Accepting request 1001272 from home:dirkmueller:Factory

- avoid bashisms in /bin/sh based startup script

OBS-URL: https://build.opensuse.org/request/show/1001272
OBS-URL: https://build.opensuse.org/package/show/server:database:postgresql/postgresql?expand=0&rev=142
This commit is contained in:
2022-09-05 13:46:15 +00:00
committed by Git OBS Bridge
parent dd6702b849
commit eba7b2a0c4
2 changed files with 7 additions and 2 deletions

View File

@@ -10,7 +10,7 @@ PIDFILE=$DATADIR/postmaster.pid
#
if test -r $DATADIR/PG_VERSION ; then
DATA_VERSION=$(cat $DATADIR/PG_VERSION)
POSTGRES=/usr/lib/postgresql${DATA_VERSION/./}/bin/postgres
POSTGRES=/usr/lib/postgresql$(echo -n $DATA_VERSION | tr -d .)/bin/postgres
fi
if test -x /usr/bin/postgres; then
ACTIVE=$(readlink -q -f /usr/bin/postgres)
@@ -49,7 +49,7 @@ case "$1" in
test -n "$POSTGRES_LANG" && export LC_ALL="$POSTGRES_LANG"
install -d -m 700 ${DATADIR} &&
echo "Initializing PostgreSQL $VERSION at location ${DATADIR}"
/usr/bin/initdb --auth=ident $DATADIR &> initlog || {
/usr/bin/initdb --auth=ident $DATADIR > initlog 2>&1 || {
echo "Initialisation failed. See $PWD/initlog ."
exit 1
}

View File

@@ -1,3 +1,8 @@
-------------------------------------------------------------------
Mon Sep 5 13:12:41 UTC 2022 - Dirk Müller <dmueller@suse.com>
- avoid bashisms in /bin/sh based startup script
-------------------------------------------------------------------
Sat May 21 15:11:15 UTC 2022 - Marcus Rueckert <mrueckert@suse.de>