From 21d1a575277bdee1c59aa92bfd2b7ba19968af58 Mon Sep 17 00:00:00 2001 From: Peter Kurfer Date: Tue, 7 Feb 2023 20:47:29 +0100 Subject: [PATCH] feat: upgrade CI image to Go 1.20 --- .agola/config.yml | 80 ----------------------------------------------- go-ci/Dockerfile | 4 +-- 2 files changed, 2 insertions(+), 82 deletions(-) delete mode 100644 .agola/config.yml diff --git a/.agola/config.yml b/.agola/config.yml deleted file mode 100644 index 6d7a106..0000000 --- a/.agola/config.yml +++ /dev/null @@ -1,80 +0,0 @@ -version: v0 -runs: - - name: Build - tasks: - - name: Checkout code - runtime: - type: pod - containers: - - image: docker.io/alpine/git - steps: - - clone: - recurse_submodules: true - - save_to_workspace: - contents: - - source_dir: . - dest_dir: . - paths: - - '**' - - name: Build Go CI image - runtime: - containers: - - image: gcr.io/kaniko-project/executor:debug - environment: - DOCKERAUTH: - from_variable: dockerauth - shell: /busybox/sh - steps: - - restore_workspace: - dest_dir: . - - run: - name: generate docker config - command: | - cat << EOF > /kaniko/.docker/config.json - { - "auths": { - "https://code.icb4dc0.de": { "auth" : "$DOCKERAUTH" } - } - } - EOF - - run: - name: Build and push image - command: | - /kaniko/executor \ - --destination code.icb4dc0.de/inetmock/ci-images/go-ci:latest \ - --context dir:///root/project/ \ - --dockerfile /root/project/go-ci/Dockerfile - depends: - - Checkout code - - - - name: Build mdbook image - runtime: - containers: - - image: gcr.io/kaniko-project/executor:debug - environment: - DOCKERAUTH: - from_variable: dockerauth - shell: /busybox/sh - steps: - - restore_workspace: - dest_dir: . - - run: - name: generate docker config - command: | - cat << EOF > /kaniko/.docker/config.json - { - "auths": { - "https://code.icb4dc0.de": { "auth" : "$DOCKERAUTH" } - } - } - EOF - - run: - name: Build and push image - command: | - /kaniko/executor \ - --destination code.icb4dc0.de/inetmock/ci-images/mdbook:latest \ - --context dir:///root/project/ \ - --dockerfile /root/project/mdbook/Dockerfile - depends: - - Checkout code \ No newline at end of file diff --git a/go-ci/Dockerfile b/go-ci/Dockerfile index b71e2d9..180b5b9 100644 --- a/go-ci/Dockerfile +++ b/go-ci/Dockerfile @@ -1,4 +1,4 @@ -FROM docker.io/golang:1.19-bullseye as tools +FROM docker.io/golang:1.20-bullseye as tools RUN go install github.com/golang/mock/mockgen@latest && \ go install github.com/Helcaraxan/gomod@latest && \ @@ -25,7 +25,7 @@ RUN apt-get update && \ ln -s /usr/bin/llc-14 /usr/bin/llc # Install Go -RUN curl -L https://go.dev/dl/go1.19.2.linux-amd64.tar.gz | tar -xvz -C /usr/local +RUN curl -L https://go.dev/dl/go1.20.linux-amd64.tar.gz | tar -xvz -C /usr/local ENV PATH=/go/bin:/usr/local/go/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin \ GOPATH=/go