From 24836144a0c00c176c6b1e98108a4943a6038bc8 Mon Sep 17 00:00:00 2001 From: Itxaka Date: Tue, 13 Jun 2023 11:39:31 +0200 Subject: [PATCH] Build fips packages with go 1.19.10 (#280) --- packages/system/immucore/build.yaml | 8 ++- packages/system/kairos-agent/build.yaml | 16 +++-- packages/system/kcrypt-challenger/build.yaml | 13 +++- packages/system/kcrypt/build.yaml | 13 +++- packages/toolchain-go/collection.yaml | 72 +++++++++++++------- 5 files changed, 86 insertions(+), 36 deletions(-) diff --git a/packages/system/immucore/build.yaml b/packages/system/immucore/build.yaml index 3e97182..a1fced7 100644 --- a/packages/system/immucore/build.yaml +++ b/packages/system/immucore/build.yaml @@ -1,8 +1,14 @@ +{{if eq .Values.category "fips" }} +requires: + - name: "toolchain-go-ubuntu" + category: "fips" + version: ">=0" +{{else}} requires: - name: "toolchain-go-ubuntu" category: "development" version: ">=0" - +{{end}} prelude: {{if eq .Values.category "fips" }} - apt-get update && apt-get install gcc diff --git a/packages/system/kairos-agent/build.yaml b/packages/system/kairos-agent/build.yaml index 3f1c746..244e5a2 100644 --- a/packages/system/kairos-agent/build.yaml +++ b/packages/system/kairos-agent/build.yaml @@ -1,8 +1,18 @@ +{{if eq .Values.category "fips" }} +requires: + - name: "toolchain-go-ubuntu" + category: "fips" + version: ">=0" +{{else}} requires: - name: "toolchain-go-ubuntu" category: "development" version: ">=0" - +{{end}} +prelude: + - apt-get update && apt-get install -y npm gcc + - mkdir /go/src/github.com/${GITHUB_ORG}/ -p + - cd /go/src/github.com/${GITHUB_ORG}/ && git clone --branch v${PACKAGE_VERSION} https://github.com/${GITHUB_ORG}/{{ .Values.name }}.git env: - GITHUB_ORG={{ ( index .Values.labels "github.owner" ) }} - HUGO_VERSION=0.110.0 @@ -22,10 +32,6 @@ copy: version: ">=0" source: "/usr/share/doc/kairos" destination: "/kairos-docs/" -prelude: - - apt-get update && apt-get install -y npm gcc - - mkdir /go/src/github.com/${GITHUB_ORG}/ -p - - cd /go/src/github.com/${GITHUB_ORG}/ && git clone --branch v${PACKAGE_VERSION} https://github.com/${GITHUB_ORG}/{{ .Values.name }}.git steps: # Docs for webui, copy them from the package - mkdir -p /go/src/github.com/${GITHUB_ORG}/{{ .Values.name }}/internal/webui/public/local diff --git a/packages/system/kcrypt-challenger/build.yaml b/packages/system/kcrypt-challenger/build.yaml index f990003..6141d90 100644 --- a/packages/system/kcrypt-challenger/build.yaml +++ b/packages/system/kcrypt-challenger/build.yaml @@ -1,7 +1,14 @@ +{{if eq .Values.category "fips" }} requires: -- name: "toolchain-go-ubuntu" - category: "development" - version: ">=0" + - name: "toolchain-go-ubuntu" + category: "fips" + version: ">=0" +{{else}} +requires: + - name: "toolchain-go-ubuntu" + category: "development" + version: ">=0" +{{end}} prelude: {{if eq .Values.category "fips" }} - apt-get update && apt-get install -y gcc diff --git a/packages/system/kcrypt/build.yaml b/packages/system/kcrypt/build.yaml index 7ab3139..2e691f5 100644 --- a/packages/system/kcrypt/build.yaml +++ b/packages/system/kcrypt/build.yaml @@ -1,7 +1,14 @@ +{{if eq .Values.category "fips" }} requires: -- name: "toolchain-go-ubuntu" - category: "development" - version: ">=0" + - name: "toolchain-go-ubuntu" + category: "fips" + version: ">=0" +{{else}} +requires: + - name: "toolchain-go-ubuntu" + category: "development" + version: ">=0" +{{end}} prelude: {{if eq .Values.category "fips" }} - apt-get update && apt-get install -y gcc diff --git a/packages/toolchain-go/collection.yaml b/packages/toolchain-go/collection.yaml index fd36cd1..daa1376 100644 --- a/packages/toolchain-go/collection.yaml +++ b/packages/toolchain-go/collection.yaml @@ -1,25 +1,49 @@ packages: -- name: toolchain-go - category: development - variant: "alpine" - version: "1.20.2" - tag: "1.20.2" - hidden: true -- name: toolchain-go-ubuntu - variant: "" - category: development - version: "1.20.2" - tag: "1.20.2" - hidden: true -- name: toolchain-go - category: development - variant: "alpine" - version: "1.20.2" - tag: "1.20.2" - hidden: true -- name: toolchain-go-ubuntu - variant: "" - category: development - version: "1.20.2" - tag: "1.20.2" - hidden: true \ No newline at end of file + - name: toolchain-go + category: development + variant: "alpine" + version: "1.20.2" + tag: "1.20.2" + hidden: true + - name: toolchain-go-ubuntu + variant: "" + category: development + version: "1.20.2" + tag: "1.20.2" + hidden: true + - name: toolchain-go + category: development + variant: "alpine" + version: "1.20.2" + tag: "1.20.2" + hidden: true + - name: toolchain-go-ubuntu + variant: "" + category: development + version: "1.20.2" + tag: "1.20.2" + hidden: true + - name: toolchain-go + category: fips + variant: "alpine" + version: "1.19.10" + tag: "1.19.10" + hidden: true + - name: toolchain-go-ubuntu + variant: "" + category: fips + version: "1.19.10" + tag: "1.19.10" + hidden: true + - name: toolchain-go + category: fips + variant: "alpine" + version: "1.19.10" + tag: "1.19.10" + hidden: true + - name: toolchain-go-ubuntu + variant: "" + category: fips + version: "1.19.10" + tag: "1.19.10" + hidden: true \ No newline at end of file