From 9a2786123a598cc3dde6e96c308b73c332f1d70a Mon Sep 17 00:00:00 2001 From: Andrey Smirnov Date: Thu, 9 Dec 2021 23:20:06 +0300 Subject: [PATCH] fix: make iPXE script replace script on chain request Without `--replace`, if the iPXE script downloaded exists, control goes back to the main script which will keep retrying. This breaks cases like `ipxe-exit` which rely on iPXE exit to continue e.g. booting from disk. Signed-off-by: Andrey Smirnov --- app/sidero-controller-manager/internal/ipxe/ipxe_server.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/sidero-controller-manager/internal/ipxe/ipxe_server.go b/app/sidero-controller-manager/internal/ipxe/ipxe_server.go index 5031374e2..9d9362764 100644 --- a/app/sidero-controller-manager/internal/ipxe/ipxe_server.go +++ b/app/sidero-controller-manager/internal/ipxe/ipxe_server.go @@ -69,7 +69,7 @@ set x:int32 0 # attempt boot, if fails try next iface route - chain http://{{ .Endpoint }}:{{ .Port }}/ipxe?uuid=${uuid}&mac=${net${idx}/mac:hexhyp}&domain=${domain}&hostname=${hostname}&serial=${serial}&arch=${buildarch} || goto next_iface + chain --replace http://{{ .Endpoint }}:{{ .Port }}/ipxe?uuid=${uuid}&mac=${net${idx}/mac:hexhyp}&domain=${domain}&hostname=${hostname}&serial=${serial}&arch=${buildarch} || goto next_iface :exhausted echo