From 8afd5db0438c7a981c3fe555e73fcc6f2d9ec600 Mon Sep 17 00:00:00 2001 From: Evan Baker Date: Tue, 15 Mar 2022 22:46:38 +0000 Subject: [PATCH] update to go1.18 Signed-off-by: Evan Baker --- .devcontainer/Dockerfile | 4 ++-- .devcontainer/devcontainer.json | 2 +- .github/workflows/crdgen.yaml | 2 +- .github/workflows/cyclonus-netpol-extended-nightly-test.yaml | 2 +- .github/workflows/cyclonus-netpol-test.yaml | 2 +- .pipelines/Dockerfile | 2 +- Dockerfile.build | 2 +- build/tools/go.mod | 2 +- cns/Dockerfile | 2 +- cns/windows.Dockerfile | 2 +- go.mod | 2 +- hack/toolbox/Dockerfile.windows | 4 ++-- npm/Dockerfile | 2 +- tools/acncli/Dockerfile | 2 +- 14 files changed, 16 insertions(+), 16 deletions(-) diff --git a/.devcontainer/Dockerfile b/.devcontainer/Dockerfile index fe2b1e49c8..c2d5714e3f 100644 --- a/.devcontainer/Dockerfile +++ b/.devcontainer/Dockerfile @@ -1,8 +1,8 @@ # See here for image contents: https://github.com/microsoft/vscode-dev-containers/tree/v0.203.0/containers/go/.devcontainer/base.Dockerfile # [Choice] Go version (use -bullseye variants on local arm64/Apple Silicon): 1, 1.16, 1.17, 1-bullseye, 1.16-bullseye, 1.17-bullseye, 1-buster, 1.16-buster, 1.17-buster -ARG VARIANT="1.17-bullseye" -FROM mcr.microsoft.com/vscode/devcontainers/go:0-${VARIANT} +ARG VARIANT="1.18" +FROM mcr.microsoft.com/vscode/devcontainers/go:${VARIANT} # [Choice] Node.js version: none, lts/*, 16, 14, 12, 10 ARG NODE_VERSION="none" diff --git a/.devcontainer/devcontainer.json b/.devcontainer/devcontainer.json index c798c5176e..e8fbaeb58e 100644 --- a/.devcontainer/devcontainer.json +++ b/.devcontainer/devcontainer.json @@ -8,7 +8,7 @@ // Update the VARIANT arg to pick a version of Go: 1, 1.16, 1.17 // Append -bullseye or -buster to pin to an OS version. // Use -bullseye variants on local arm64/Apple Silicon. - "VARIANT": "1-bullseye", + "VARIANT": "1.18-bullseye", // Options "NODE_VERSION": "none" } diff --git a/.github/workflows/crdgen.yaml b/.github/workflows/crdgen.yaml index 9d5b6a1520..1a56135657 100644 --- a/.github/workflows/crdgen.yaml +++ b/.github/workflows/crdgen.yaml @@ -6,7 +6,7 @@ jobs: crdgen: strategy: matrix: - go-version: ['1.17'] + go-version: ['1.18'] os: [ubuntu-latest] name: CRDs are Generated runs-on: ${{ matrix.os }} diff --git a/.github/workflows/cyclonus-netpol-extended-nightly-test.yaml b/.github/workflows/cyclonus-netpol-extended-nightly-test.yaml index aab619ceae..2ae4b12490 100644 --- a/.github/workflows/cyclonus-netpol-extended-nightly-test.yaml +++ b/.github/workflows/cyclonus-netpol-extended-nightly-test.yaml @@ -27,7 +27,7 @@ jobs: - uses: actions/setup-go@v2 with: - go-version: "^1.17" + go-version: "^1.18" - name: Setup Kind uses: engineerd/setup-kind@v0.5.0 diff --git a/.github/workflows/cyclonus-netpol-test.yaml b/.github/workflows/cyclonus-netpol-test.yaml index 26350cc23c..2f031e3ad0 100644 --- a/.github/workflows/cyclonus-netpol-test.yaml +++ b/.github/workflows/cyclonus-netpol-test.yaml @@ -27,7 +27,7 @@ jobs: - uses: actions/setup-go@v2 with: - go-version: '^1.17' + go-version: '^1.18' - name: Setup Kind uses: engineerd/setup-kind@v0.5.0 diff --git a/.pipelines/Dockerfile b/.pipelines/Dockerfile index 0cc7ed14ce..3814f8a5e0 100644 --- a/.pipelines/Dockerfile +++ b/.pipelines/Dockerfile @@ -11,7 +11,7 @@ RUN echo "deb http://archive.ubuntu.com/ubuntu/ bionic multiverse" | sudo tee -a RUN echo "deb http://archive.ubuntu.com/ubuntu/ bionic universe" | sudo tee -a /etc/apt/sources.list RUN echo "deb http://archive.ubuntu.com/ubuntu/ bionic main" | sudo tee -a /etc/apt/sources.list RUN apt-get update && apt-get install -y iptables ipset iproute2 ebtables -RUN wget -qO- https://golang.org/dl/go1.17.linux-amd64.tar.gz | tar zxf - -C /usr/lib/ +RUN wget -qO- https://golang.org/dl/go1.18.linux-amd64.tar.gz | tar zxf - -C /usr/lib/ ENV PATH="/usr/lib/go/bin/:${PATH}" ENV GOROOT="/usr/lib/go" ENV GOPATH="/root/go" diff --git a/Dockerfile.build b/Dockerfile.build index f087f951e5..7f3af09a7b 100644 --- a/Dockerfile.build +++ b/Dockerfile.build @@ -1,4 +1,4 @@ -FROM docker.io/golang:1.17 +FROM docker.io/golang:1.18 RUN apt-get update \ && apt-get install -y zip \ diff --git a/build/tools/go.mod b/build/tools/go.mod index d562654fc2..f92186cb59 100644 --- a/build/tools/go.mod +++ b/build/tools/go.mod @@ -1,6 +1,6 @@ module github.com/Azure/azure-container-networking/build/tools -go 1.17 +go 1.18 require ( github.com/AlekSi/gocov-xml v1.0.0 diff --git a/cns/Dockerfile b/cns/Dockerfile index ade6dae7a9..89cb369d82 100644 --- a/cns/Dockerfile +++ b/cns/Dockerfile @@ -1,7 +1,7 @@ FROM docker.io/alpine:latest as certs RUN apk --update add ca-certificates -FROM docker.io/golang:1.17 AS builder +FROM docker.io/golang:1.18 AS builder ARG VERSION ARG CNS_AI_PATH ARG CNS_AI_ID diff --git a/cns/windows.Dockerfile b/cns/windows.Dockerfile index c1791c149e..7dcbc1d224 100644 --- a/cns/windows.Dockerfile +++ b/cns/windows.Dockerfile @@ -1,5 +1,5 @@ # Build cns -FROM docker.io/golang:1.17 AS builder +FROM docker.io/golang:1.18 AS builder # Build args ARG VERSION ARG CNS_AI_PATH diff --git a/go.mod b/go.mod index 117cef3fc6..78807e124c 100644 --- a/go.mod +++ b/go.mod @@ -1,6 +1,6 @@ module github.com/Azure/azure-container-networking -go 1.17 +go 1.18 require ( code.cloudfoundry.org/clock v1.0.0 // indirect diff --git a/hack/toolbox/Dockerfile.windows b/hack/toolbox/Dockerfile.windows index 4690bb5914..afdc87f2de 100644 --- a/hack/toolbox/Dockerfile.windows +++ b/hack/toolbox/Dockerfile.windows @@ -1,5 +1,5 @@ # Build cns -FROM docker.io/golang:1.17 AS builder +FROM docker.io/golang:1.18 AS builder # Build args ARG VERSION ARG CNS_AI_PATH @@ -14,7 +14,7 @@ RUN $Env:CGO_ENABLED=0; go build -v -o /usr/local/bin/toolbox.exe -gcflags="-dwa FROM mcr.microsoft.com/windows/servercore:ltsc2022 COPY --from=builder /usr/local/bin/toolbox.exe \ /usr/local/bin/toolbox.exe - + RUN powershell.exe Set-ExecutionPolicy Bypass -Scope Process -Force; [System.Net.ServicePointManager]::SecurityProtocol = [System.Net.ServicePointManager]::SecurityProtocol -bor 3072; iex ((New-Object System.Net.WebClient).DownloadString('https://community.chocolatey.org/install.ps1')) RUN choco install -y vim wget diff --git a/npm/Dockerfile b/npm/Dockerfile index da391bd2b3..1df3c12e22 100644 --- a/npm/Dockerfile +++ b/npm/Dockerfile @@ -1,5 +1,5 @@ # Build npm -FROM docker.io/golang:1.17 AS builder +FROM docker.io/golang:1.18 AS builder # Build args ARG VERSION ARG NPM_AI_PATH diff --git a/tools/acncli/Dockerfile b/tools/acncli/Dockerfile index 7ff5a219ae..9b2f30f3fe 100644 --- a/tools/acncli/Dockerfile +++ b/tools/acncli/Dockerfile @@ -1,4 +1,4 @@ -FROM docker.io/golang:1.17 as build +FROM docker.io/golang:1.18 as build WORKDIR /go/src/github.com/Azure/azure-container-networking/ ARG VERSION ARG PLATFORM