Add missing app check
This commit is contained in:
parent
4df767fee9
commit
6d1d2235c3
@ -14,9 +14,15 @@ dokku-ansible-deploy-vault-pass-cmd() {
|
|||||||
#shellcheck disable=SC2034
|
#shellcheck disable=SC2034
|
||||||
declare desc="add new app vault password for decryption of passwords"
|
declare desc="add new app vault password for decryption of passwords"
|
||||||
|
|
||||||
local app="$1"
|
|
||||||
local vault_file="$DOKKU_LIB_ROOT/data/deploy.d/$app/.vault-password.sh"
|
local vault_file="$DOKKU_LIB_ROOT/data/deploy.d/$app/.vault-password.sh"
|
||||||
|
|
||||||
|
local app="$2"
|
||||||
|
|
||||||
|
if [[ -n "$app" ]]; then
|
||||||
|
dokku_col_log_info1_quiet "missing application name, try 'dokku ansible-deploy:vault-pass myappname'"
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
if [[ -f $vault_file ]]; then
|
if [[ -f $vault_file ]]; then
|
||||||
dokku_col_log_info1_quiet "Vault password already in place"
|
dokku_col_log_info1_quiet "Vault password already in place"
|
||||||
exit 0
|
exit 0
|
||||||
|
Reference in New Issue
Block a user