Mercurial > public > ssdt-docker
diff scripts/backup-container.sh @ 293:95d7d70f34a5 production v2.4.0
flow: Merged <release> 'v2.4.0' to <master> ('production').
author | smith@nwoca.org |
---|---|
date | Thu, 27 Dec 2018 00:06:14 +0000 |
parents | 4cc087cde1d0 |
children | d78b45c28205 |
line wrap: on
line diff
--- a/scripts/backup-container.sh Thu Nov 15 20:10:48 2018 +0000 +++ b/scripts/backup-container.sh Thu Dec 27 00:06:14 2018 +0000 @@ -15,14 +15,16 @@ source "${SSDT_SCRIPTS:-$(dirname "${BASH_SOURCE[0]}")}/.functions.sh" +project=$(composeGetProject) + set -o pipefail mkdir -p ./backup -backupFile=./backup/${container}.$(date +%Y-%m-%d-%H-%M-%S).backup +backupFile=./backup/${project}-${container}.$(date +%Y-%m-%d-%H-%M-%S).backup echo "preparing to backup ${container} on current project at ${projectDir}:" echo " " -project=$(composeGetProject) + if [ "$project" == "" ]; then echo "no project available"