Commit fd2b80c4 authored by Andres Maldonado's avatar Andres Maldonado
Browse files

[DBBackup] Remove unnecessary flag

-c
--clean

    Output commands to clean (drop) database objects prior to outputting 
the commands for creating them. (Unless --if-exists is also specified, 
restore might generate some harmless error messages, if any objects were 
not present in the destination database.)

    This option is only meaningful for the plain-text format. For the 
archive formats, you can specify the option when you call pg_restore.

https://www.postgresql.org/docs/current/app-pgdump.html
parent 10c0b05f
......@@ -10,7 +10,7 @@ BACKUP_FOLDER=${BACKUP_FOLDER:-"/backup/"}
ping -c 1 -W 1 "${POSTGRES_HOST}" || { echo -e "\n=========== ${POSTGRES_HOST} not available, skipping backup... ===========\n"; exit 1; }
BACKUP_CMD="pg_dump -w -c --format=c > $BACKUP_FOLDER"'${BACKUP_NAME}'
BACKUP_CMD="pg_dump -w --format=c > $BACKUP_FOLDER"'${BACKUP_NAME}'
RESTORE_CMD="pg_restore -c \$1"
# Make sure backup folder exists
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment