Improve debugging control
Signed-off-by: Richard T Bonhomme <tincantech@protonmail.com>
This commit is contained in:
parent
15429df9fd
commit
bf3c21273e
@ -766,24 +766,24 @@ easyrsa_openssl() {
|
|||||||
fi
|
fi
|
||||||
else
|
else
|
||||||
# debug log on
|
# debug log on
|
||||||
[ "$EASYRSA_DEBUG" ] && echo "<< DEBUG-ON >>" && set -x
|
if [ "$EASYRSA_DEBUG" ]; then print "<< DEBUG-ON >>"; set -x; fi
|
||||||
|
|
||||||
# Exec SSL with -config temp-file
|
# Exec SSL with -config temp-file
|
||||||
"$EASYRSA_OPENSSL" "$openssl_command" \
|
"$EASYRSA_OPENSSL" "$openssl_command" \
|
||||||
-config "$easyrsa_openssl_conf" "$@" || return
|
-config "$easyrsa_openssl_conf" "$@" || return
|
||||||
|
|
||||||
# debug log off
|
# debug log off
|
||||||
[ "$EASYRSA_DEBUG" ] && set +x && echo ">> DEBUG-OFF <<"
|
if [ "$EASYRSA_DEBUG" ]; then set +x; print ">> DEBUG-OFF <<"; fi
|
||||||
fi
|
fi
|
||||||
else
|
else
|
||||||
# debug log on
|
# debug log on
|
||||||
[ "$EASYRSA_DEBUG" ] && echo "<< DEBUG-ON >>" && set -x
|
if [ "$EASYRSA_DEBUG" ]; then print "<< DEBUG-ON >>"; set -x; fi
|
||||||
|
|
||||||
# Exec SSL without -config temp-file
|
# Exec SSL without -config temp-file
|
||||||
"$EASYRSA_OPENSSL" "$openssl_command" "$@" || return
|
"$EASYRSA_OPENSSL" "$openssl_command" "$@" || return
|
||||||
|
|
||||||
# debug log off
|
# debug log off
|
||||||
[ "$EASYRSA_DEBUG" ] && set +x && echo ">> DEBUG-OFF <<"
|
if [ "$EASYRSA_DEBUG" ]; then set +x; print ">> DEBUG-OFF <<"; fi
|
||||||
fi
|
fi
|
||||||
} # => easyrsa_openssl()
|
} # => easyrsa_openssl()
|
||||||
|
|
||||||
@ -988,7 +988,7 @@ install_data_to_pki () {
|
|||||||
# Copying 'vars' to the PKI is complicated, code is included but DISABLED.
|
# Copying 'vars' to the PKI is complicated, code is included but DISABLED.
|
||||||
|
|
||||||
# debug log on
|
# debug log on
|
||||||
[ "$EASYRSA_DEBUG" ] && echo "<< DEBUG-ON >>" && set -x
|
if [ "$EASYRSA_DEBUG" ]; then print ">> DEBUG-ON <<"; set -x; fi
|
||||||
|
|
||||||
context="$1"
|
context="$1"
|
||||||
shift
|
shift
|
||||||
@ -1088,7 +1088,11 @@ install_data_to_pki () {
|
|||||||
|
|
||||||
# Complete or error
|
# Complete or error
|
||||||
require_safe_ssl_conf=1 # Always required
|
require_safe_ssl_conf=1 # Always required
|
||||||
[ -e "$EASYRSA_SAFE_CONF" ] || easyrsa_openssl makesafeconf
|
[ -e "$EASYRSA_SAFE_CONF" ] || easyrsa_openssl makesafeconf || return
|
||||||
|
|
||||||
|
# debug log OFF
|
||||||
|
if [ "$EASYRSA_DEBUG" ]; then set +x; print ">> DEBUG-OFF <<"; fi
|
||||||
|
|
||||||
} # => install_data_to_pki ()
|
} # => install_data_to_pki ()
|
||||||
|
|
||||||
# Disable terminal echo, if possible, otherwise warn
|
# Disable terminal echo, if possible, otherwise warn
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user