From 06f8237196e9b060e959211b3d5fb6ec71f5ecf9 Mon Sep 17 00:00:00 2001 From: Jose Diaz-Gonzalez Date: Wed, 4 Jul 2018 15:31:03 -0400 Subject: [PATCH] fix: get the global scheduler if no app is specified --- plugins/ps/subcommands/restore | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/plugins/ps/subcommands/restore b/plugins/ps/subcommands/restore index b9c209fd1..7103f59d8 100755 --- a/plugins/ps/subcommands/restore +++ b/plugins/ps/subcommands/restore @@ -8,8 +8,13 @@ ps_restore_cmd() { declare desc="starts all apps with DOKKU_APP_RESTORE not set to 0 via command line" local cmd="ps:restore" local APP="$2" + local DOKKU_SCHEDULER + + DOKKU_SCHEDULER=$(config_get --global DOKKU_SCHEDULER || echo "docker-local") + if [[ -n "$APP" ]]; then + DOKKU_SCHEDULER=$(config_get "$APP" DOKKU_SCHEDULER || echo "docker-local") + fi - local DOKKU_SCHEDULER=$(config_get "$APP" DOKKU_SCHEDULER || echo "docker-local") plugn trigger pre-restore "$DOKKU_SCHEDULER" if [[ -n "$APP" ]]; then