From 1928687c08676f134b37d035e486bd2848926cf9 Mon Sep 17 00:00:00 2001 From: irina Date: Fri, 23 Feb 2018 12:07:51 +0000 Subject: #678 Con directorios de OU separados se resuelve errata de r5447 por la que al crear imagen en modo usuario no permite montar el repo en modo escritura. git-svn-id: https://opengnsys.es/svn/branches/version1.1@5610 a21b9725-9963-47de-94b9-378ad31fedc9 --- client/engine/Net.lib | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/client/engine/Net.lib b/client/engine/Net.lib index 17c932d2..4b3faad9 100755 --- a/client/engine/Net.lib +++ b/client/engine/Net.lib @@ -38,7 +38,7 @@ fi # Si REPO tomamos el repositorio y la unidad organizativa actual REPO=$(ogGetRepoIp) -OGUNIT="$(df | awk -F " " '/oglog/ {sub("//.*/oglog","",$1); sub("/","",$1); print $1}')" +OGUNIT="$(df | awk -F " " '/ogimages/ {sub("//.*/ogimages","",$1); sub("/","",$1); print $1}')" # Parametros de entrada. Si $1 = "REPO" dejo el repositorio actual [ "${1^^}" == "REPO" ] && NEWREPO="$REPO" || NEWREPO="${1}" @@ -51,7 +51,9 @@ source /scripts/ogfunctions umount $OGIMG [ "$2" == "" ] && SRCIMG="ogimages" || SRCIMG="ogimages/$2" eval $(grep "OPTIONS=" /scripts/ogfunctions) -[ "$ogactiveadmin" == "true" ] && RW=",rw" || RW=",ro" + +# Opciones de montaje: lectura o escritura +mount |grep "ogimages.*rw," &>/dev/null && RW=",rw" || RW=",ro" ogEcho session log "$MSG_HELP_ogChangeRepo $NEWREPO ${2%/}" ogConnect $NEWREPO $ogprotocol $SRCIMG $OGIMG $RW -- cgit v1.2.3-18-g5258