From 4816ea56b0dbdf230c0db685bb6924da157b2c56 Mon Sep 17 00:00:00 2001 From: Javier Sánchez Parra Date: Tue, 21 Apr 2020 13:42:21 +0200 Subject: #971 Remove ogAdmAgent initialization All the functionalities of the ogAdmAgent are now in the ogAdmServer. So, the it is not needed anymore. This commit remove the installation and update of the ogAdmAgent, adds a check to remove it if exists and removes it from the OpenGnsys init script. A future patch will remove all the code related to the ogAdmAgent. --- server/bin/checkperms | 2 -- server/bin/setserveraddr | 4 ++-- 2 files changed, 2 insertions(+), 4 deletions(-) (limited to 'server') diff --git a/server/bin/checkperms b/server/bin/checkperms index b7559e84..c03f88bf 100755 --- a/server/bin/checkperms +++ b/server/bin/checkperms @@ -48,8 +48,6 @@ chown -R $OPENGNSYS_USER:$OPENGNSYS_USER $OPENGNSYS_DIR/client/etc/ssl/private chmod -R go-rwx $OPENGNSYS_DIR/client/etc/ssl/private chown $OPENGNSYS_USER:$OPENGNSYS_USER $OPENGNSYS_DIR/client/interfaceAdm/CambiarAcceso chmod 700 $OPENGNSYS_DIR/client/interfaceAdm/CambiarAcceso -chown root:root $OPENGNSYS_DIR/etc/ogAdmAgent*.cfg -chmod 600 $OPENGNSYS_DIR/etc/ogAdmAgent*.cfg chown root:$APACHE_GROUP $OPENGNSYS_DIR/{www/controlacceso*.php,etc/ogAdmRepo*.cfg,etc/ogAdmServer*.cfg} chmod 640 $OPENGNSYS_DIR/{www/controlacceso*.php,etc/ogAdmRepo*.cfg,etc/ogAdmServer*.cfg} chown -R $APACHE_USER:$APACHE_GROUP $OPENGNSYS_DIR/www/images/{fotos,iconos} diff --git a/server/bin/setserveraddr b/server/bin/setserveraddr index c3898724..c7920e6a 100755 --- a/server/bin/setserveraddr +++ b/server/bin/setserveraddr @@ -33,7 +33,7 @@ source $OPENGNSYS/lib/ogfunctions.sh || exit 1 [ "$USER" != "root" ] && raiseError access "Need to be root" [ $# -ne 1 ] && raiseError usage [ -r $DEFAULTFILE ] || raiseError access "Cannot read default configuration file" -for f in $OPENGNSYS/{etc/{ogAdmServer,ogAdmRepo,ogAdmAgent}.cfg,www/controlacceso.php,client/ogClient/cfg/ogclient.cfg}; do +for f in $OPENGNSYS/{etc/{ogAdmServer,ogAdmRepo}.cfg,www/controlacceso.php,client/ogClient/cfg/ogclient.cfg}; do [ -w $f ] || raiseError access "Cannot write to file: $f" done @@ -88,7 +88,7 @@ if [ -n "$SERVERIP" ]; then OLDSERVERIP=$ServidorAdm # Checking if configuration files need to be modified. CHANGE=0 - for f in $OPENGNSYS/{etc/{ogAdmServer,ogAdmRepo,ogAdmAgent}.cfg,www/controlacceso.php}; do + for f in $OPENGNSYS/{etc/{ogAdmServer,ogAdmRepo}.cfg,www/controlacceso.php}; do # Updating configuration variables (if URL does not contain "localhost"). sed -e "s,\(ServidorAdm\|IPlocal\)=.*,\1=$SERVERIP," \ -e "s,^INTERFACE=.*,INTERFACE=$SERVERDEV," \ -- cgit v1.2.3-18-g5258