Skip to content

Commit

Permalink
PMM-13662 Fix backup from data container (#3486)
Browse files Browse the repository at this point in the history
  • Loading branch information
BupycHuk authored Jan 24, 2025
1 parent 3346e2a commit 0866d70
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion get-pmm.sh
Original file line number Diff line number Diff line change
Expand Up @@ -469,6 +469,7 @@ start_pmm() {
pmm_archive="$container_name-$(date "+%F-%H%M%S")"
msg "\tExisting PMM Server found, renaming to $pmm_archive\n"
run_docker "stop $container_name" || :
volume_name=$(run_docker "inspect -f '{{ range .Mounts }}{{ if and (eq .Type \"volume\") (eq .Destination \"/srv\" )}}{{ .Name }}{{ \"\n\" }}{{ end }}{{ end }}' $container_name")
if [[ "$backup_data" == 1 ]]; then
backup_pmm_data
fi
Expand All @@ -479,7 +480,6 @@ start_pmm() {
docker_env_flags=$(migrate_env_vars "$docker_env_flags")
migrate_pmm_data
fi
volume_name=$(run_docker "inspect -f '{{ range .Mounts }}{{ if and (eq .Type \"volume\") (eq .Destination \"/srv\" )}}{{ .Name }}{{ \"\n\" }}{{ end }}{{ end }}' $container_name")
run_docker "rename $container_name $pmm_archive\n"
fi

Expand Down

0 comments on commit 0866d70

Please sign in to comment.