]> git.pld-linux.org Git - packages/postgresql.git/commitdiff
set TMPDIR before every su call
authorArkadiusz Miśkiewicz <arekm@maven.pl>
Tue, 5 Jun 2001 17:12:29 +0000 (17:12 +0000)
committercvs2git <feedback@pld-linux.org>
Sun, 24 Jun 2012 12:13:13 +0000 (12:13 +0000)
Changed files:
    postgresql.init -> 1.25

postgresql.init

index 2a7d804368304fe03f31172c5bddb8ecbc6fb99b..24b657eee345b3e1bab2921fae534b206cea235d 100644 (file)
@@ -56,7 +56,7 @@ case "$1" in
                        chown postgres.postgres $POSTGRES_DATA_DIR
                        chmod 700 $POSTGRES_DATA_DIR
                    fi
-                   su postgres -c "LD_LIBRARY_PATH=/usr/lib \
+                   TMPDIR=/tmp su postgres -c "LD_LIBRARY_PATH=/usr/lib \
                        initdb --pgdata=$POSTGRES_DATA_DIR \
                        -L /usr/share/postgresql"
                fi
@@ -70,7 +70,7 @@ case "$1" in
                    $([ "$POSTGRES_DISABLE_FSYNC". = yes. ] && echo '-F') \
                    $([ "$ALLOW_TCP_CONNECTIONS". = yes. ] && echo '-i')";
 
-               su postgres -c "\
+               TMPDIR=/tmp su postgres -c "\
                        $(echo "/usr/bin/pg_ctl start $PGSQL_CMDLINE -l $POSTGRES_LOG") \
                        $([ "$POSTMASTER_OPTIONS". != . ] && echo "-o '$POSTMASTER_OPTIONS'") \
                        $(echo "2>&1 >/dev/null")";
@@ -94,7 +94,7 @@ case "$1" in
        msg_stopping postgreSQL
        busy
        PGSQL_CMDLINE="$([ -n "$POSTGRES_DATA_DIR" ] && echo "-D $POSTGRES_DATA_DIR")";
-       su postgres -c "/usr/bin/pg_ctl stop $PGSQL_CMDLINE -m fast 2>&1 >/dev/null"
+       TMPDIR=/tmp su postgres -c "/usr/bin/pg_ctl stop $PGSQL_CMDLINE -m fast 2>&1 >/dev/null"
        out=`status postmaster`
        if [ $? -eq 0 ]; then
                deltext; fail
@@ -108,7 +108,7 @@ case "$1" in
        ;;
   status)
        PGSQL_CMDLINE="$([ -n "$POSTGRES_DATA_DIR" ] && echo "-D $POSTGRES_DATA_DIR")";
-       su postgres -c "/usr/bin/pg_ctl status $PGSQL_CMDLINE"
+       TMPDIR=/tmp su postgres -c "/usr/bin/pg_ctl status $PGSQL_CMDLINE"
        ;;
   restart)
        $0 stop
@@ -129,7 +129,7 @@ case "$1" in
            $([ "$POSTGRES_DISABLE_FSYNC". = yes. ] && echo '-F') \
            $([ "$ALLOW_TCP_CONNECTIONS". = yes. ] && echo '-i')";
 
-       su postgres -c "\
+       TMPDIR=/tmp su postgres -c "\
                $(echo "/usr/bin/pg_ctl restart $PGSQL_CMDLINE -l $POSTGRES_LOG") \
                $([ "$POSTMASTER_OPTIONS". != . ] && echo "-o '$POSTMASTER_OPTIONS'") \
                $(echo "2>&1 >/dev/null")";
This page took 0.396049 seconds and 4 git commands to generate.