From dfbf4fa8252d168c4b0835d059a6d497f80ac511 Mon Sep 17 00:00:00 2001 From: ramon Date: Tue, 15 Jan 2013 13:21:54 +0000 Subject: [PATCH] =?UTF-8?q?#570:=20Corregir=20problema=20en=20caminos=20y?= =?UTF-8?q?=20al=20detectar=20distribuci=C3=B3n=20del=20cliente=20generado?= =?UTF-8?q?.?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit git-svn-id: https://opengnsys.es/svn/branches/version1.0@3483 a21b9725-9963-47de-94b9-378ad31fedc9 --- boottoolsgenerator.sh | 7 ++--- .../bin/boot-tools/boottoolsFsOpengnsys.sh | 28 +++++++++---------- 2 files changed, 15 insertions(+), 20 deletions(-) diff --git a/boottoolsgenerator.sh b/boottoolsgenerator.sh index 40d5aab..358cf66 100755 --- a/boottoolsgenerator.sh +++ b/boottoolsgenerator.sh @@ -69,8 +69,8 @@ echo "FASE 4 - Configurar acceso schroot al Segundo Sistema de archivos (img)" cat /etc/schroot/schroot.conf | grep $BTROOTFSIMG || btogSetFsAccess ########################################################################### echo "FASE 5 - Incorporando ficheros OpenGnSys el sistema raiz rootfs " -cp -av ${BTSVNBOOTTOOLS}/includes/usr/bin/* /tmp/ -chmod 777 /tmp/boot-tools/*.sh +cp -a ${BTSVNBOOTTOOLS}/includes/usr/bin/* /tmp +chmod +x /tmp/boot-tools/*.sh umount $BTROOTFSMNT 2>/dev/null schroot -p -c IMGogclient -- /tmp/boot-tools/boottoolsFsOpengnsys.sh ############################################################################################ @@ -80,7 +80,6 @@ schroot -p -c IMGogclient -- /usr/bin/boot-tools/boottoolsSoftwareInstall.sh echo "Fase 6.2 compilar software." cd / schroot -p -c IMGogclient -- /usr/bin/boot-tools/boottoolsSoftwareCompile.sh -schroot -p -c IMGogclient -- /usr/bin/boot-tools/boottoolsSoftwareCompile.sh cd - echo "FASE 7 - Personalizar el sistema creado" @@ -111,7 +110,5 @@ echo "Fase 8.3 Generar la ISO" btogIsoGenerator ######################################################################3 ######################################################################## -# Mostrar sumario de la instalación e instrucciones de post-instalación. -installationSummary echoAndLog "OpenGnSys installation finished at $(date)" diff --git a/includes/usr/bin/boot-tools/boottoolsFsOpengnsys.sh b/includes/usr/bin/boot-tools/boottoolsFsOpengnsys.sh index e9a9adf..76adbcc 100755 --- a/includes/usr/bin/boot-tools/boottoolsFsOpengnsys.sh +++ b/includes/usr/bin/boot-tools/boottoolsFsOpengnsys.sh @@ -3,11 +3,11 @@ #svn checkout http://www.opengnsys.es/svn/branches/version1.0/client /tmp/opengnsys_installer/opengnsys/client/; #svn checkout http://www.opengnsys.es/svn/branches/version2/ /tmp/opengnsys_installer/opengnsys2 -find /tmp/opengnsys_installer/ -name .svn -type d -exec rm -fr {} \; 2>/dev/null; - -apt-get -y --force-yes install subversion +#find /tmp/opengnsys_installer/ -name .svn -type d -exec rm -fr {} \; 2>/dev/null; +#apt-get -y --force-yes install subversion #export SVNURL="http://opengnsys.es/svn/branches/version1.0/client/" #VERSIONSVN=$(LANG=C svn info $SVNURL | awk '/Revision:/ {print "r"$2}') + VERSIONSVN=$(cat /tmp/versionsvn.txt) VERSIONBOOTTOOLS=ogLive @@ -19,13 +19,15 @@ SVNCLIENTSTRUCTURE=/tmp/opengnsys_installer/opengnsys/client/shared SVNCLIENTENGINE=/tmp/opengnsys_installer/opengnsys/client/engine SVNOG2=/tmp/opengnsys_installer/opengnsys2 -OGCLIENTMOUNT="$BTROOTFSMNT" +OGCLIENTMOUNT="" -OSDISTRIB=$(lsb_release -is) -OSCODENAME=$(lsb_release -cs) -OSRELEASE=$(uname -a | awk '{print $3}') -uname -a | grep x86_64 > /dev/null && export OSARCH=amd64 || export OSARCH=i386 -OSHTTP="http://es.archive.ubuntu.com/ubuntu/" +OSDISTRIB=${OSDISTRIB:-$(lsb_release -is)} +OSCODENAME=${OSCODENAME:-$(lsb_release -cs)} +OSRELEASE=${OSRELEASE:-$(uname -a | awk '{print $3}')} +if [ -z "$OSARCH" ]; then + uname -a | grep x86_64 > /dev/null && export OSARCH=amd64 || export OSARCH=i386 +fi +OSHTTP=${OSHTTP:-"http://es.archive.ubuntu.com/ubuntu/"} echo "$OSDISTRIB:$OSCODENAME:$OSRELEASE:$OSARCH:$OSHTTP" @@ -94,28 +96,24 @@ fi #Compatiblidad con og2 cp -av ${SVNCLIENTSTRUCTURE}/bin/browser2 $OGCLIENTMOUNT/bin - cp -av ${SVNOG2}/ogr/ogr $OGCLIENTMOUNT/opt/opengnsys/bin/ - cp -av ${SVNOG2}/ogr/libogr.py $OGCLIENTMOUNT/usr/lib/python2.7/libogr.py cp -av ${SVNOG2}/ogr/libogr.py $OGCLIENTMOUNT/usr/lib/python2.6/libogr.py cp -av ${SVNOG2}/ogr/libogr.py $OGCLIENTMOUNT/opt/opengnsys/lib/python - echo "mkdir -p /opt/opengnsys/lib/engine/" mkdir -p /opt/opengnsys/engine/ echo "cp -prv ${SVNOG2}/engine/2.0/* $OGCLIENTMOUNT/opt/opengnsys/engine/" cp -av ${SVNOG2}/engine/2.0/* $OGCLIENTMOUNT/opt/opengnsys/engine/ - cp -av ${SVNOG2}/job_executer $OGCLIENTMOUNT/opt/opengnsys/bin/ cp -av ${SVNCLIENTSTRUCTURE}/bin/ogAdmClient $OGCLIENTMOUNT/bin -echo "${VERSIONBOOTTOOLS}-${OSCODENAME}-${OSRELEASE}-${VERSIONSVN}" > $OGCLIENTMOUNT/$NAMEISOCLIENTFILE -echo "${VERSIONBOOTTOOLS}-${OSCODENAME}-${VERSIONSVN}" > $OGCLIENTMOUNT/$NAMEHOSTCLIENTFILE +echo "${VERSIONBOOTTOOLS}-${OSCODENAME}-${OSRELEASE}-${VERSIONSVN}" > /$NAMEISOCLIENTFILE +echo "${VERSIONBOOTTOOLS}-${OSCODENAME}-${VERSIONSVN}" > $NAMEHOSTCLIENTFILE history -c