Log debug on etcd if $ENABLE_DEBUG_LOG_LEVEL is on

Change-Id: I452a2e4882377d165e3c28fcec18e237e45db8a4
This commit is contained in:
Michał Dulko 2018-12-20 18:55:29 +01:00
parent 2697e431d2
commit 119ee66cde
1 changed files with 3 additions and 0 deletions

View File

@ -46,6 +46,9 @@ function start_etcd3 {
cmd+=" --listen-peer-urls http://0.0.0.0:$ETCD_PEER_PORT "
fi
cmd+=" --listen-client-urls http://$SERVICE_HOST:$ETCD_PORT"
if [ "$ENABLE_DEBUG_LOG_LEVEL" == "True" ]; then
cmd+=" --debug"
fi
local unitfile="$SYSTEMD_DIR/$ETCD_SYSTEMD_SERVICE"
write_user_unit_file $ETCD_SYSTEMD_SERVICE "$cmd" "" "root"