mirror of
https://github.com/flynx/proxmox-utils.git
synced 2025-10-29 11:10:09 +00:00
cleanup...
Signed-off-by: Alex A. Naanou <alex.nanou@gmail.com>
This commit is contained in:
parent
c18e82a199
commit
2df81dcf01
35
Makefile
35
Makefile
@ -60,7 +60,6 @@ check: check-message $(foreach dep,$(DEPENDENCIES),require($(dep)))
|
|||||||
FORCE:
|
FORCE:
|
||||||
|
|
||||||
|
|
||||||
# XXX should thisbe an env var or an arg to make.sh???
|
|
||||||
%-bootstrap: export BOOTSTRAP=1
|
%-bootstrap: export BOOTSTRAP=1
|
||||||
%-bootstrap: %
|
%-bootstrap: %
|
||||||
@true
|
@true
|
||||||
@ -100,24 +99,24 @@ gate: gate-traefik
|
|||||||
|
|
||||||
#----------------------------------------------------------------------
|
#----------------------------------------------------------------------
|
||||||
|
|
||||||
# XXX goal:
|
# Bootstrap stage 1: build basic infrastructure...
|
||||||
# - build minimal system
|
|
||||||
# - bootstrap bridge
|
|
||||||
# - gate
|
|
||||||
# - ns
|
|
||||||
# ...not yet sure of the best way to do this...
|
|
||||||
#
|
|
||||||
.PHONY: bootstrap
|
.PHONY: bootstrap
|
||||||
bootstrap: host-bootstrap gate-bootstrap \
|
bootstrap: \
|
||||||
ns \
|
host-bootstrap \
|
||||||
ssh \
|
gate-bootstrap \
|
||||||
wireguard \
|
ns ssh wireguard \
|
||||||
bootstrap-clean
|
bootstrap-clean
|
||||||
|
|
||||||
|
|
||||||
# NOTE: host-bootstrap-clean will drop all connections to the server...
|
# Bootstrap stage 2: reconnect host through the base infrastructure...
|
||||||
.PHONY: bootstrap-clean
|
.PHONY: bootstrap-clean host-bootstrap-clean
|
||||||
bootstrap-clean: gate-bootstrap-clean #host-bootstrap-clean
|
bootstrap-clean: host-bootstrap-clean
|
||||||
|
|
||||||
|
|
||||||
|
# Finalize: reconect admin port/bridge correctly...
|
||||||
|
.PHONY: finalize
|
||||||
|
finalize: bootstrap-clean gate-bootstrap-clean
|
||||||
|
@ make host-bootstrap-clean
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@ -139,6 +138,12 @@ dev: minimal $(DEV_CTs)
|
|||||||
all: minimal $(APP_CTs)
|
all: minimal $(APP_CTs)
|
||||||
|
|
||||||
|
|
||||||
|
.PHONY: test
|
||||||
|
test:
|
||||||
|
@echo "TEST!"
|
||||||
|
|
||||||
|
test2: test test
|
||||||
|
|
||||||
|
|
||||||
#----------------------------------------------------------------------
|
#----------------------------------------------------------------------
|
||||||
|
|
||||||
|
|||||||
16
host/make.sh
16
host/make.sh
@ -47,10 +47,20 @@ BRIDGES_TPL=bridges.tpl
|
|||||||
# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
|
# - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
|
||||||
# Bootstrap...
|
# Bootstrap...
|
||||||
|
|
||||||
if ! [ -z $BOOTSTRAP_CLEAN ] \
|
if ! [ -z $BOOTSTRAP_CLEAN ] ; then
|
||||||
&& [ -e "$INTERFACES".clean ] ; then
|
|
||||||
@ cp "$INTERFACES"{,.bak}
|
@ cp "$INTERFACES"{,.bak}
|
||||||
@ cp "$INTERFACES"{.clean,.new}
|
|
||||||
|
# stage 1: bootstrap -> clean
|
||||||
|
if [ -e "$INTERFACES".clean ] ; then
|
||||||
|
@ mv "$INTERFACES"{.clean,.new}
|
||||||
|
# stage 2: clean -> final
|
||||||
|
elif [ -e "$INTERFACES".final ] ; then
|
||||||
|
@ mv "$INTERFACES"{.final,.new}
|
||||||
|
# donw
|
||||||
|
else
|
||||||
|
exit
|
||||||
|
fi
|
||||||
|
|
||||||
if reviewApplyChanges "$INTERFACES" ; then
|
if reviewApplyChanges "$INTERFACES" ; then
|
||||||
# XXX this must be done in nohup to avoid breaking on connection lost...
|
# XXX this must be done in nohup to avoid breaking on connection lost...
|
||||||
if ! @ ifreload -a ; then
|
if ! @ ifreload -a ; then
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user