From 86deec194babc1264b472d4a5e2c74113953a71d Mon Sep 17 00:00:00 2001 From: Loran Mutafov Date: Wed, 8 Mar 2023 20:10:57 +0200 Subject: [PATCH] Fix debug logging and rename it to better reflect it is debug logging and not simply verbosity --- bastion | 18 ++++++++---------- 1 file changed, 8 insertions(+), 10 deletions(-) diff --git a/bastion b/bastion index 0c9d55e..7bfa5a8 100644 --- a/bastion +++ b/bastion @@ -77,16 +77,14 @@ else fi # Verbosity from 0 to 3 -if [ $VERBOSITY_LEVEL = "0" ]; then - CONFIG_VERBOSITY_LEVEL="-q" -elif [ $VERBOSITY_LEVEL = "1" ]; then - CONFIG_VERBOSITY_LEVEL="-v" -elif [ $VERBOSITY_LEVEL = "2" ]; then - CONFIG_VERBOSITY_LEVEL="-vv" -elif [ $VERBOSITY_LEVEL = "3" ]; then - CONFIG_VERBOSITY_LEVEL="-vvv" +if [ $DEBUG_LEVEL = "1" ]; then + CONFIG_DEBUG_LEVEL="-d" +elif [ $DEBUG_LEVEL = "2" ]; then + CONFIG_DEBUG_LEVEL="-dd" +elif [ $DEBUG_LEVEL = "3" ]; then + CONFIG_DEBUG_LEVEL="-ddd" else - CONFIG_VERBOSITY_LEVEL="" + CONFIG_DEBUG_LEVEL="" fi # Generate keys if they don't exist @@ -127,6 +125,6 @@ fi $CONFIG_CLIENT_ALIVE_COUNT_MAX \ $CONFIG_CLIENT_ALIVE_INTERVAL \ $CONFIG_TCP_KEEP_ALIVE \ - $CONFIG_VERBOSITY_LEVEL \ + $CONFIG_DEBUG_LEVEL \ $CONFIG_LISTEN_ADDRESS \ $CONFIG_LISTEN_PORT