Adding optional colorized log output for trove
Change-Id: Ibdaed9c2d1527b4c38551efbc147597e2a668b1a
This commit is contained in:
parent
94bfa18bd1
commit
674ee84ec6
16
lib/trove
16
lib/trove
@ -33,6 +33,17 @@ TROVE_AUTH_ENDPOINT=$KEYSTONE_AUTH_PROTOCOL://$KEYSTONE_AUTH_HOST:$KEYSTONE_AUTH
|
||||
TROVE_AUTH_CACHE_DIR=${TROVE_AUTH_CACHE_DIR:-/var/cache/trove}
|
||||
TROVE_BIN_DIR=/usr/local/bin
|
||||
|
||||
# setup_trove_logging() - Adds logging configuration to conf files
|
||||
function setup_trove_logging() {
|
||||
local CONF=$1
|
||||
iniset $CONF DEFAULT debug $ENABLE_DEBUG_LOG_LEVEL
|
||||
iniset $CONF DEFAULT use_syslog $SYSLOG
|
||||
if [ "$LOG_COLOR" == "True" ] && [ "$SYSLOG" == "False" ]; then
|
||||
# Add color to logging output
|
||||
setup_colorized_logging $CONF DEFAULT tenant user
|
||||
fi
|
||||
}
|
||||
|
||||
# create_trove_accounts() - Set up common required trove accounts
|
||||
|
||||
# Tenant User Roles
|
||||
@ -121,6 +132,9 @@ function configure_trove() {
|
||||
iniset $TROVE_LOCAL_CONF_DIR/trove-guestagent.conf.sample DEFAULT control_exchange trove
|
||||
sed -i "s/localhost/$NETWORK_GATEWAY/g" $TROVE_LOCAL_CONF_DIR/trove-guestagent.conf.sample
|
||||
|
||||
setup_trove_logging $TROVE_CONF_DIR/trove.conf
|
||||
setup_trove_logging $TROVE_LOCAL_CONF_DIR/trove-guestagent.conf.sample
|
||||
|
||||
# (Re)create trove taskmanager conf file if needed
|
||||
if is_service_enabled tr-tmgr; then
|
||||
iniset $TROVE_CONF_DIR/trove-taskmanager.conf DEFAULT rabbit_password $RABBIT_PASSWORD
|
||||
@ -130,6 +144,7 @@ function configure_trove() {
|
||||
iniset $TROVE_CONF_DIR/trove-taskmanager.conf DEFAULT nova_proxy_admin_tenant_name trove
|
||||
iniset $TROVE_CONF_DIR/trove-taskmanager.conf DEFAULT nova_proxy_admin_pass $RADMIN_USER_PASS
|
||||
iniset $TROVE_CONF_DIR/trove-taskmanager.conf DEFAULT trove_auth_url $TROVE_AUTH_ENDPOINT
|
||||
setup_trove_logging $TROVE_CONF_DIR/trove-taskmanager.conf
|
||||
fi
|
||||
|
||||
# (Re)create trove conductor conf file if needed
|
||||
@ -141,6 +156,7 @@ function configure_trove() {
|
||||
iniset $TROVE_CONF_DIR/trove-conductor.conf DEFAULT nova_proxy_admin_pass $RADMIN_USER_PASS
|
||||
iniset $TROVE_CONF_DIR/trove-conductor.conf DEFAULT trove_auth_url $TROVE_AUTH_ENDPOINT
|
||||
iniset $TROVE_CONF_DIR/trove-conductor.conf DEFAULT control_exchange trove
|
||||
setup_trove_logging $TROVE_CONF_DIR/trove-conductor.conf
|
||||
fi
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user