From e92ea8488d0f912e4325d4b1da7cb716fa91487c Mon Sep 17 00:00:00 2001 From: Olivier DOSSMANN Date: Fri, 8 Dec 2017 11:43:05 +0100 Subject: [PATCH] Revert "[IMP] Use 'docker exec' to backup database" This reverts commit da74d4b4a6fe45f7ec40b801baa285436cac7f22. --- launch.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/launch.sh b/launch.sh index dcfeb05..b3baaf2 100755 --- a/launch.sh +++ b/launch.sh @@ -208,7 +208,7 @@ backup() { test_create # Then check some specific things for dump method test_backup - $docker_cmd exec -t ${POSTGRES_DOCKER_NAME} pg_dump -F c -U postgres > $PWD/gissmo-`date +"%Y.%m.%d.%H%M"`-${GISSMO_VERSION}.dump || error_and_quit "Failed to backup Gissmo database." + $docker_cmd run -it --rm --volume $PWD/:/tmp/ --link ${POSTGRES_DOCKER_NAME}:db postgres:${POSTGRES_VERSION} bash -c 'exec pg_dump -F c -h "$DB_PORT_5432_TCP_ADDR" -p "$DB_PORT_5432_TCP_PORT" -U postgres postgres > /tmp/gissmo-`date +"%Y.%m.%d.%H%M"`-'${GISSMO_VERSION}'.dump' || error_and_quit "Failed to backup Gissmo database." } init() {