From: František Dvořák Date: Mon, 18 Jan 2010 14:22:04 +0000 (+0000) Subject: Overwrite LB-super-users file by $GLITE_LB_SUPER_USERS (deleting old super-users... X-Git-Tag: glite-lb-harvester_R_1_0_3_1~20 X-Git-Url: http://scientific.zcu.cz/git/?a=commitdiff_plain;h=46d94cd659946f586e1871e46cb73a516257b724;p=jra1mw.git Overwrite LB-super-users file by $GLITE_LB_SUPER_USERS (deleting old super-users file content). --- diff --git a/org.glite.yaim.lb/config/functions/config_glite_lb b/org.glite.yaim.lb/config/functions/config_glite_lb index 637a487..01127c8 100644 --- a/org.glite.yaim.lb/config/functions/config_glite_lb +++ b/org.glite.yaim.lb/config/functions/config_glite_lb @@ -16,8 +16,8 @@ function config_glite_lb_setenv(){ yaimgridenv_set GLITE_LB_EXPORT_PURGE_ARGS "${GLITE_LB_EXPORT_PURGE_ARGS:---cleared 2d --aborted 15d --cancelled 15d --other 60d}" yaimgridenv_set GLITE_LB_EXPORT_JPPS ${GLITE_LB_EXPORT_JPPS:-} yaimgridenv_set GLITE_LB_RTM_ENABLED ${GLITE_LB_RTM_ENABLED:-false} - yaimgridenv_set GLITE_LB_RTM_DN ${GLITE_LB_RTM_DN:-/C=UK/O=eScience/OU=Imperial/L=Physics/CN=heppc24.hep.ph.ic.ac.uk/Email=janusz.martyniak@imperial.ac.uk} - yaimgridenv_set GLITE_LB_SUPER_USERS ${GLITE_LB_SUPER_USERS:-} + yaimgridenv_set GLITE_LB_RTM_DN "${GLITE_LB_RTM_DN:-/C=UK/O=eScience/OU=Imperial/L=Physics/CN=heppc24.hep.ph.ic.ac.uk/Email=janusz.martyniak@imperial.ac.uk}" + yaimgridenv_set GLITE_LB_SUPER_USERS "${GLITE_LB_SUPER_USERS:-}" yaimgridenv_set GLITE_LB_HARVESTER_ENABLED ${GLITE_LB_HARVESTER_ENABLED:-false} yaimgridenv_set GLITE_LB_HARVESTER_MSG_OPTIONS "${GLITE_LB_HARVESTER_MSG_OPTIONS:---wlcg}" @@ -173,14 +173,14 @@ EOF echo "${GLITE_LOCATION}/etc/init.d/glite-lb-bkserverd" >> ${GLITE_LOCATION}/etc/gLiteservices fi - touch ${GLITE_LOCATION}/etc/LB-super-users - echo "$GLITE_LB_SUPER_USERS" > ${GLITE_LOCATION}/etc/LB-super-users.add + if [ -z "$GLITE_LB_SUPER_USERS" ]; then + touch ${GLITE_LOCATION}/etc/LB-super-users + else + echo "$GLITE_LB_SUPER_USERS" > ${GLITE_LOCATION}/etc/LB-super-users + fi if [ x"$GLITE_LB_RTM_ENABLED" = x"true" ]; then - echo "$GLITE_LB_RTM_DN" >> ${GLITE_LOCATION}/etc/LB-super-users.add + echo "$GLITE_LB_RTM_DN" >> ${GLITE_LOCATION}/etc/LB-super-users fi - mv ${GLITE_LOCATION}/etc/LB-super-users ${GLITE_LOCATION}/etc/LB-super-users.prev - cat ${GLITE_LOCATION}/etc/LB-super-users.prev ${GLITE_LOCATION}/etc/LB-super-users.add | sort | uniq > ${GLITE_LOCATION}/etc/LB-super-users - rm ${GLITE_LOCATION}/etc/LB-super-users.prev ${GLITE_LOCATION}/etc/LB-super-users.add if [ ! -f ${GLITE_LOCATION}/etc/glite-lb-harvester.conf ]; then echo $HOSTNAME > ${GLITE_LOCATION}/etc/glite-lb-harvester.conf