918-git-images-111dconfigfileconfigure-oglivegit-imageslgromero-new-oglivemainmaint-cronmount-efivarfsmultivmmultivm-ogboot-installerogClonningEngineogboot-installer-jenkinsoglive-ipv6test-python-scriptsticket-301ticket-50ticket-50-oldticket-577ticket-585ticket-611ticket-612ticket-693ticket-700ubu24tplunification2use-local-agent-oglivevarios-instalacionwebconsole3
Last change
on this file since c916af9 was
5acde60,
checked in by ramon <ramongomez@…>, 11 years ago
|
#541 #645: Modificar función ogGetOsVersion para detectar Grub como última opción mostrando bien el sistema operativo instalado junto al cargador; evitar mensajes de error en el arranque si no está definida la variable ogactiveadmin .
git-svn-id: https://opengnsys.es/svn/branches/version1.0@4369 a21b9725-9963-47de-94b9-378ad31fedc9
|
-
Property mode set to
100755
|
File size:
915 bytes
|
Line | |
---|
1 | #!/bin/bash |
---|
2 | #/** |
---|
3 | #@file mountrepo.sh |
---|
4 | #@brief Script para montar el repositorio de datos remoto. |
---|
5 | #@warning License: GNU GPLv3+ |
---|
6 | #@version 1.0 |
---|
7 | #@author Ramon Gomez, ETSII Universidad de Sevilla |
---|
8 | #@date 2011-03-17 |
---|
9 | #*/ |
---|
10 | |
---|
11 | OGIMG=${OGIMG:-/opt/opengnsys/images} |
---|
12 | ROOTREPO=${ROOTREPO:-"$ROOTSERVER"} |
---|
13 | |
---|
14 | # TODO Revisar proceso de arranque para no montar 2 veces el repositorio. |
---|
15 | if [ "$ogactiveadmin" == "true" ]; then |
---|
16 | export boot=admin # ATENCIÓN: siempre en modo "admin". |
---|
17 | umount $OGIMG 2>/dev/null |
---|
18 | |
---|
19 | protocol=${ogprotocol:-"smb"} |
---|
20 | printf "$MSG_MOUNTREPO\n" "$protocol" "$boot" |
---|
21 | case "$ogprotocol" in |
---|
22 | nfs) mount.nfs ${ROOTREPO}:$OGIMG $OGIMG -o rw,nolock ;; |
---|
23 | smb) PASS=$(grep "^[ ]*\(export \)\?OPTIONS=" /scripts/ogfunctions 2>&1 | \ |
---|
24 | sed 's/\(.*\)pass=\(\w*\)\(.*\)/\2/') |
---|
25 | PASS=${PASS:-"og"} |
---|
26 | mount.cifs //${ROOTREPO}/ogimages $OGIMG -o rw,serverino,acl,username=opengnsys,password=$PASS |
---|
27 | ;; |
---|
28 | esac |
---|
29 | fi |
---|
30 | |
---|
Note: See
TracBrowser
for help on using the repository browser.