added cleanup stage + fixes...

Signed-off-by: Alex A. Naanou <alex.nanou@gmail.com>
This commit is contained in:
Alex A. Naanou 2024-10-18 16:49:52 +03:00
parent 3d05258695
commit 6f923c45e9
2 changed files with 23 additions and 6 deletions

View File

@ -41,9 +41,15 @@ REBOOT=${REBOOT:=1}
# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
# Bootstrap...
if ! [ -z $BOOTSTRAP ] ; then
if ! [ -z $BOOTSTRAP_CLEAN ] ; then
# XXX update wan bridge in config...
# XXX update IP ???
true
elif ! [ -z $BOOTSTRAP ] ; then
WAN_BRIDGE=$ADMIN_BRIDGE
DFL_CTHOSTNAME=${DFL_CTHOSTNAME}-bootstrap
#DFL_CTHOSTNAME=${DFL_CTHOSTNAME}-bootstrap
else
# XXX
true
@ -55,6 +61,17 @@ fi
readVars
# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
if ! [ -z $BOOTSTRAP_CLEAN ] ; then
echo "# Reverting to WAN bridge..."
@ sed -i \
-e 's/^\(net0.*vmbr\)'${ADMIN_BRIDGE}'/\1'${WAN_BRIDGE}'/' \
/etc/pve/lxc/${ID}.conf
exit
fi
#----------------------------------------------------------------------

View File

@ -1,4 +1,4 @@
search srv
nameserver 127.0.0.1
nameserver ${NS_LAN_IPn}
nameserver 8.8.8.8
search srv
nameserver 127.0.0.1
nameserver ${NS_LAN_IPn}
nameserver 8.8.8.8