refs #1172 change "logger" into "echo", remove ogGetCaller from 2 scripts

ogboot-log
Natalia Serrano 2024-11-25 11:13:46 +01:00
parent 1fe999f05a
commit 00d328b9bf
3 changed files with 11 additions and 11 deletions

View File

@ -59,7 +59,7 @@ if [ -n "$LOGLEVEL" ]; then
DATETIME=$(date +"%F %T")
# Registrar mensajes en fichero de log si la depuración no está desactivada.
[ "${DEBUG,,}" != "no" ] && LOGS="$OGLOGFILE $LOGS"
logger -s -t "OpenGnsys $LOGLEVEL" "$DATETIME $*" 2>&1 | tee -a $LOGS
echo "OpenGnsys $LOGLEVEL" "$DATETIME $*" 2>&1 | tee -a $LOGS
else
echo "$*" | tee -a $LOGS
fi

View File

@ -8,11 +8,11 @@
# Error si llamada no se realliza desde OpenGnsys Client.
PROG=$(basename $0)
CALLER=$(ogGetCaller)
if ! $(ogCheckStringInGroup "$CALLER" "CrearImagen ConsolaRemota CrearImagenBasica CrearSoftIncremental"); then
ogRaiseError $OG_ERR_NOTEXEC "$CALLER -> $PROG"
exit $?
fi
#CALLER=$(ogGetCaller)
#if ! $(ogCheckStringInGroup "$CALLER" "CrearImagen ConsolaRemota CrearImagenBasica CrearSoftIncremental"); then
# ogRaiseError $OG_ERR_NOTEXEC "$CALLER -> $PROG"
# exit $?
#fi
# Salir si el repositorio está bloquedo (tiene ficheros abiertos).
REPOIP=$(ogGetRepoIp)

View File

@ -45,11 +45,11 @@ ogEcho log session "$MSG_INTERFACE_START $0 $*"
# Solo ejecutable por OpenGnsys Client.
PATH=$PATH:$(dirname $0)
PROG=$(basename $0)
CALLER=$(ogGetCaller)
if [ "$CALLER" != "ogAdmClient" ]; then
ogRaiseError $OG_ERR_NOTEXEC "$CALLER -> $PROG"
exit $?
fi
#CALLER=$(ogGetCaller)
#if [ "$CALLER" != "ogAdmClient" ]; then
# ogRaiseError $OG_ERR_NOTEXEC "$CALLER -> $PROG"
# exit $?
#fi
# Valor por defecto para el repositorio.
REPO=${4:-"REPO"}