Browse Source

fixed per shellcheck's preference for `-n` instead of `! -z`

pull/4139/head
William Sellitti 2 years ago
parent
commit
6652138d3e
  1. 12
      deploy/proxmoxve.sh

12
deploy/proxmoxve.sh

@ -32,16 +32,16 @@ proxmoxve_deploy(){
# "Sane" defaults. # "Sane" defaults.
_target_hostname="$_cdomain" _target_hostname="$_cdomain"
if [ ! -z "$DEPLOY_PROXMOXVE_SERVER" ];then
if [ -n "$DEPLOY_PROXMOXVE_SERVER" ];then
_target_hostname="$DEPLOY_PROXMOXVE_SERVER" _target_hostname="$DEPLOY_PROXMOXVE_SERVER"
fi fi
_target_port="8006" _target_port="8006"
if [ ! -z "$DEPLOY_PROXMOXVE_SERVER_PORT" ];then
if [ -n "$DEPLOY_PROXMOXVE_SERVER_PORT" ];then
_target_port="$DEPLOY_PROXMOXVE_SERVER_PORT" _target_port="$DEPLOY_PROXMOXVE_SERVER_PORT"
fi fi
if [ ! -z "$DEPLOY_PROXMOXVE_NODE_NAME" ];then
if [ -n "$DEPLOY_PROXMOXVE_NODE_NAME" ];then
_node_name="$DEPLOY_PROXMOXVE_NODE_NAME" _node_name="$DEPLOY_PROXMOXVE_NODE_NAME"
else else
_node_name=$(echo "$_target_hostname"|cut -d. -f1) _node_name=$(echo "$_target_hostname"|cut -d. -f1)
@ -52,17 +52,17 @@ proxmoxve_deploy(){
# More "sane" defaults. # More "sane" defaults.
_proxmoxve_user="root" _proxmoxve_user="root"
if [ ! -z "$_proxmoxve_user" ];then
if [ -n "$_proxmoxve_user" ];then
_proxmoxve_user="$DEPLOY_PROXMOXVE_USER" _proxmoxve_user="$DEPLOY_PROXMOXVE_USER"
fi fi
_proxmoxve_user_realm="pam" _proxmoxve_user_realm="pam"
if [ ! -z "$DEPLOY_PROXMOXVE_USER_REALM" ];then
if [ -n "$DEPLOY_PROXMOXVE_USER_REALM" ];then
_proxmoxve_user_realm="$DEPLOY_PROXMOXVE_USER_REALM" _proxmoxve_user_realm="$DEPLOY_PROXMOXVE_USER_REALM"
fi fi
_proxmoxve_api_token_name="acme" _proxmoxve_api_token_name="acme"
if [ ! -z "$DEPLOY_PROXMOXVE_API_TOKEN_NAME" ];then
if [ -n "$DEPLOY_PROXMOXVE_API_TOKEN_NAME" ];then
_proxmoxve_api_token_name="$DEPLOY_PROXMOXVE_API_TOKEN_NAME" _proxmoxve_api_token_name="$DEPLOY_PROXMOXVE_API_TOKEN_NAME"
fi fi

Loading…
Cancel
Save