Skip to content

Commit

Permalink
feat(docker-monolithic): make upgrade backup optional
Browse files Browse the repository at this point in the history
  • Loading branch information
bytestream committed Jan 17, 2025
1 parent fdf3a30 commit 2561ff8
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions templates/docker-monolithic/upgrade.sh
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,14 @@ check_docker_compose() {
}

backup() {
echo
echo "It is recommend to take a backup before upgrading, this may take some time. If you've already taken a backup you can skip this step."
echo "Do you want to take a backup? [Y/n]"
read -r PROCEED
if [ "${PROCEED}" == "n" ] ; then
return
fi

time_now=$(date +"%d-%m-%Y-%H:%M:%S")
cp -n docker-compose.yml "docker-compose.backup-${time_now}.yml"

Expand Down

0 comments on commit 2561ff8

Please sign in to comment.