From db49858f21d4cd0623e9961a12f6d9227d3594e9 Mon Sep 17 00:00:00 2001 From: Andrew Ferguson Date: Wed, 26 Jan 2022 11:14:56 -0800 Subject: [PATCH] Check/assign variables before printing debug2 --- deploy/plex.sh | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-) mode change 100644 => 100755 deploy/plex.sh diff --git a/deploy/plex.sh b/deploy/plex.sh old mode 100644 new mode 100755 index de076cc5..05f29b6e --- a/deploy/plex.sh +++ b/deploy/plex.sh @@ -35,11 +35,6 @@ plex_deploy() { _getdeployconf PLEX_PKCS12_file _getdeployconf PLEX_sudo_required - - _debug2 PLEX_PKCS12_password "$PLEX_PKCS12_password" - _debug2 PLEX_PKCS12_file "$PLEX_PKCS12_file" - _debug2 PLEX_sudo_required "$PLEX_sudo_required" - #_DEPLOY_PLEX_WIKI="https://github.com/acmesh-official/acme.sh/wiki/deploy-to-plex" @@ -49,10 +44,20 @@ plex_deploy() { #_err "See: $_DEPLOY_PLEX_WIKI" return 1 fi + _debug2 PLEX_PKCS12_password "$PLEX_PKCS12_password" if [ -z "$PLEX_PKCS12_file" ]; then PLEX_PKCS12_file="$DOMAIN_PATH/$_cdomain.pfx" + _debug2 "Setting PLEX_PKCS12_file to default" fi + _debug2 PLEX_PKCS12_file "$PLEX_PKCS12_file" + + if [ -z "$PLEX_sudo_required" ]; then + PLEX_sudo_required=0 + _debug2 "Setting PLEX_PKCS12_file to default (0/False)" + fi + + _debug2 PLEX_sudo_required "$PLEX_sudo_required" _reload_cmd=""