Init ONE: download latest ISO point release
* postservice/99-init-hapy-master: use “eole-iso” to retrieve informations. Ref: #25055
This commit is contained in:
parent
6f190b5dcd
commit
233afaaf94
|
@ -33,18 +33,26 @@ function runOneCmd()
|
||||||
return ${?}
|
return ${?}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if [ $(CreoleGet activer_proxy_client 'non') = 'oui' ]
|
||||||
|
then
|
||||||
|
PROXY_SERVER=$(CreoleGet proxy_client_adresse)
|
||||||
|
PROXY_PORT=$(CreoleGet proxy_client_port)
|
||||||
|
PROXY_OPT="--proxy http://${PROXY_SERVER}:${PROXY_PORT}"
|
||||||
|
fi
|
||||||
|
|
||||||
DISKSIZE=$(CreoleGet hapy_init_master_disk_size)
|
DISKSIZE=$(CreoleGet hapy_init_master_disk_size)
|
||||||
DISKNAME="DSK-${DISKSIZE}-Go"
|
DISKNAME="DSK-${DISKSIZE}-Go"
|
||||||
DISKDESC="Disque vide de ${DISKSIZE} Go"
|
DISKDESC="Disque vide de ${DISKSIZE} Go"
|
||||||
|
|
||||||
VERSIONISO=$(CreoleGet hapy_init_master_iso_version)
|
VERSIONISO=$(CreoleGet hapy_init_master_iso_version)
|
||||||
MAJORVERSION=${VERSIONISO:0:3}
|
MAJORVERSION=${VERSIONISO:0:3}
|
||||||
ISONAME="ISO-Eole-${VERSIONISO}-amd64"
|
POINT_RELEASE=$(eole-iso ${PROXY_OPT} --release ${VERSIONISO} get-last-point-release)
|
||||||
ISODESC="Image ISO EOLE Stable ${VERSIONISO} 64 bits"
|
ISONAME=$(eole-iso ${PROXY_OPT} --release ${VERSIONISO} get-iso-name)
|
||||||
ISOURL="http://eole.ac-dijon.fr/pub/iso/EOLE-${MAJORVERSION}/${VERSIONISO}/eole-${VERSIONISO}-alternate-amd64.iso"
|
ISODESC="Image ISO EOLE ${POINT_RELEASE} 64 bits"
|
||||||
|
ISOURL=$(eole-iso ${PROXY_OPT} --release ${VERSIONISO} get-iso-url)
|
||||||
|
|
||||||
TMPLNAME="InstallEole-${VERSIONISO}-amd64"
|
TMPLNAME="install-eole-${POINT_RELEASE}-amd64"
|
||||||
TMPLDESC="Modèle de VM permettant d'installer un module EOLE ${VERSIONISO} 64 bits (non persistente)"
|
TMPLDESC="Modèle de VM permettant d'installer un module EOLE ${POINT_RELEASE} 64 bits (non persistente)"
|
||||||
|
|
||||||
#echo "########### suppr ${DISKNAME} ###############"
|
#echo "########### suppr ${DISKNAME} ###############"
|
||||||
#oneimage delete ${DISKNAME}
|
#oneimage delete ${DISKNAME}
|
||||||
|
@ -109,7 +117,7 @@ EOF
|
||||||
break
|
break
|
||||||
fi
|
fi
|
||||||
done
|
done
|
||||||
rm -f "/tmp/eole-${VERSIONISO}-alternate-amd64.iso"
|
rm -f "/tmp/${ISONAME}"
|
||||||
else
|
else
|
||||||
echo "***** ${ISONAME} existe déjà *****"
|
echo "***** ${ISONAME} existe déjà *****"
|
||||||
fi
|
fi
|
||||||
|
|
Loading…
Reference in New Issue