From 2a9295e8e8bcf031f6044b0de95f4bb4cb49a4ff Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mika=C3=ABl=20Cluseau?= Date: Thu, 2 Feb 2023 00:32:38 +0100 Subject: [PATCH] bump initrdv2 --- cmd/dkl-local-server/bootv2.go | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/cmd/dkl-local-server/bootv2.go b/cmd/dkl-local-server/bootv2.go index b05501b..7ae4c24 100644 --- a/cmd/dkl-local-server/bootv2.go +++ b/cmd/dkl-local-server/bootv2.go @@ -3,6 +3,7 @@ package main import ( "archive/tar" "encoding/json" + "flag" "fmt" "io" "log" @@ -14,6 +15,8 @@ import ( "novit.tech/direktil/pkg/cpiocat" ) +var initrdV2 = flag.String("initrd-v2", "2.1.0", "initrd V2 version (temporary flag)") // FIXME + func renderBootstrapConfig(w http.ResponseWriter, r *http.Request, ctx *renderContext, asJson bool) (err error) { log.Printf("sending bootstrap config for %q", ctx.Host.Name) @@ -40,7 +43,7 @@ func buildInitrdV2(out io.Writer, ctx *renderContext) (err error) { cat := cpiocat.New(out) // initrd - initrdPath, err := ctx.distFetch("initrd", "2.0.0" /* FIXME */) + initrdPath, err := ctx.distFetch("initrd", *initrdV2) if err != nil { return }