Skip to content

Commit

Permalink
Upgrade to go1.22.7 (#3040)
Browse files Browse the repository at this point in the history
* add comment

* upgrade to v1.22

* upgrade to v1.22

* upgrade npm to v1.22

* upgrade to 1.22.7

* upgrade to 1.22.7

* remove unnecessary comment

* drop patch version

* version change
  • Loading branch information
aggarwal0009 authored Oct 2, 2024
1 parent d57e6c5 commit 0ab889c
Show file tree
Hide file tree
Showing 28 changed files with 93 additions and 93 deletions.
2 changes: 1 addition & 1 deletion .devcontainer/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
ARG VARIANT="1.21"
ARG VARIANT="1.22"
FROM mcr.microsoft.com/vscode/devcontainers/go:${VARIANT}
RUN apt-get update && \
export DEBIAN_FRONTEND=noninteractive && \
Expand Down
2 changes: 1 addition & 1 deletion .devcontainer/devcontainer.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
"build": {
"dockerfile": "Dockerfile",
"args": {
"VARIANT": "1.21-bullseye",
"VARIANT": "1.22-bullseye",
"NODE_VERSION": "none"
}
},
Expand Down
42 changes: 21 additions & 21 deletions .github/workflows/codeql.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,12 @@ name: "CodeQL"
on:
push:
branches:
- master
- release/*
- master
- release/*
pull_request:
branches:
- master
- release/*
- master
- release/*
types:
- opened
- reopened
Expand All @@ -32,20 +32,20 @@ jobs:
contents: read
security-events: write
steps:
- name: Setup go
uses: actions/setup-go@v5
with:
go-version: '1.21'
check-latest: true
- name: Checkout repository
uses: actions/checkout@v4
- name: Initialize CodeQL
uses: github/codeql-action/init@v3
with:
languages: ${{ matrix.language }}
- name: Autobuild
uses: github/codeql-action/autobuild@v3
- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v3
with:
category: "/language:${{matrix.language}}"
- name: Setup go
uses: actions/setup-go@v5
with:
go-version: "1.22"
check-latest: true
- name: Checkout repository
uses: actions/checkout@v4
- name: Initialize CodeQL
uses: github/codeql-action/init@v3
with:
languages: ${{ matrix.language }}
- name: Autobuild
uses: github/codeql-action/autobuild@v3
- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v3
with:
category: "/language:${{matrix.language}}"
38 changes: 19 additions & 19 deletions .github/workflows/crdgen.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,33 +3,33 @@ on:
workflow_dispatch:
pull_request:
types:
- opened
- reopened
- synchronize
- ready_for_review
- opened
- reopened
- synchronize
- ready_for_review
merge_group:
types:
- checks_requested
jobs:
crdgen:
strategy:
matrix:
go-version: ['1.21']
go-version: ["1.21", "1.22"]
os: [ubuntu-latest]
name: CRDs are Generated
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- uses: actions/setup-go@v5
with:
go-version: ${{ matrix.go-version }}
- name: Regenerate NodeNetworkConfig CRD
run: make -C crd/nodenetworkconfig
- name: Regenerate MultitenantNetworkContainer CRD
run: make -C crd/multitenantnetworkcontainer
- name: Regenerate Multitenancy CRDs
run: make -C crd/multitenancy
- name: Fail if the tree is dirty
run: test -z "$(git status --porcelain)"
- uses: actions/checkout@v4
with:
fetch-depth: 0
- uses: actions/setup-go@v5
with:
go-version: ${{ matrix.go-version }}
- name: Regenerate NodeNetworkConfig CRD
run: make -C crd/nodenetworkconfig
- name: Regenerate MultitenantNetworkContainer CRD
run: make -C crd/multitenantnetworkcontainer
- name: Regenerate Multitenancy CRDs
run: make -C crd/multitenancy
- name: Fail if the tree is dirty
run: test -z "$(git status --porcelain)"
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ jobs:

- uses: actions/setup-go@v5
with:
go-version: "^1.21"
go-version: "^1.22"

- name: Setup Kind
uses: engineerd/[email protected]
Expand Down
10 changes: 5 additions & 5 deletions .github/workflows/cyclonus-netpol-test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,11 @@ on:
- release/*
pull_request:
paths:
- 'npm/**'
- '.github/**'
- "npm/**"
- ".github/**"
schedule:
# run once a day at midnight
- cron: '0 0 * * *'
- cron: "0 0 * * *"

jobs:
cyclonus-test:
Expand All @@ -33,7 +33,7 @@ jobs:

- uses: actions/setup-go@v5
with:
go-version: '^1.21'
go-version: "^1.22"

- name: Setup Kind
uses: helm/kind-action@v1
Expand Down Expand Up @@ -77,7 +77,7 @@ jobs:
kubectl logs -n kube-system -l k8s-app=azure-npm --tail -1 --prefix > npm-logs_${{ matrix.profile }}.txt
mv ./test/cyclonus/cyclonus-test.txt ./cyclonus-test_${{ matrix.profile }}.txt
- name: 'Upload Logs'
- name: "Upload Logs"
uses: actions/upload-artifact@v4
if: always()
with:
Expand Down
24 changes: 12 additions & 12 deletions .github/workflows/golangci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,19 +15,19 @@ jobs:
strategy:
fail-fast: false
matrix:
go-version: ['1.21.x']
go-version: ["1.21.x", "1.22.x"]
os: [ubuntu-latest, windows-latest]
name: Lint
runs-on: ${{ matrix.os }}
steps:
- uses: actions/setup-go@v5
with:
go-version: ${{ matrix.go-version }}
- uses: actions/checkout@v4
with:
fetch-depth: 0
- name: golangci-lint
uses: golangci/golangci-lint-action@v5
with:
version: v1.55
args: --new-from-rev=origin/release/v1.5 --config=.golangci.yml --timeout=25m
- uses: actions/setup-go@v5
with:
go-version: ${{ matrix.go-version }}
- uses: actions/checkout@v4
with:
fetch-depth: 0
- name: golangci-lint
uses: golangci/golangci-lint-action@v5
with:
version: v1.55
args: --new-from-rev=origin/release/v1.5 --config=.golangci.yml --timeout=25m
2 changes: 1 addition & 1 deletion azure-ipam/go.mod
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
module github.com/Azure/azure-container-networking/azure-ipam

go 1.21
go 1.22.7

require (
github.com/Azure/azure-container-networking v1.5.21
Expand Down
4 changes: 2 additions & 2 deletions azure-ipam/linux.Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ ARG DROPGZ_VERSION=v0.0.12
ARG OS_VERSION
ARG OS

FROM mcr.microsoft.com/oss/go/microsoft/golang:1.21 AS azure-ipam
FROM mcr.microsoft.com/oss/go/microsoft/golang:1.22 AS azure-ipam
ARG OS
ARG VERSION
WORKDIR /azure-ipam
Expand All @@ -18,7 +18,7 @@ COPY --from=azure-ipam /azure-ipam/*.conflist /payload
RUN cd /payload && sha256sum * > sum.txt
RUN gzip --verbose --best --recursive /payload && for f in /payload/*.gz; do mv -- "$f" "${f%%.gz}"; done

FROM mcr.microsoft.com/oss/go/microsoft/golang:1.21 AS dropgz
FROM mcr.microsoft.com/oss/go/microsoft/golang:1.22 AS dropgz
ARG DROPGZ_VERSION
ARG OS
ARG VERSION
Expand Down
4 changes: 2 additions & 2 deletions azure-ipam/windows.Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ ARG DROPGZ_VERSION=v0.0.12
ARG OS
ARG OS_VERSION

FROM --platform=linux/${ARCH} mcr.microsoft.com/oss/go/microsoft/golang:1.21 AS azure-ipam
FROM --platform=linux/${ARCH} mcr.microsoft.com/oss/go/microsoft/golang:1.22 AS azure-ipam
ARG OS
ARG VERSION
WORKDIR /azure-ipam
Expand All @@ -18,7 +18,7 @@ COPY --from=azure-ipam /azure-ipam/*.conflist /payload
RUN cd /payload && sha256sum * > sum.txt
RUN gzip --verbose --best --recursive /payload && for f in /payload/*.gz; do mv -- "$f" "${f%%.gz}"; done

FROM --platform=linux/${ARCH} mcr.microsoft.com/oss/go/microsoft/golang:1.21 AS dropgz
FROM --platform=linux/${ARCH} mcr.microsoft.com/oss/go/microsoft/golang:1.22 AS dropgz
ARG DROPGZ_VERSION
ARG OS
ARG VERSION
Expand Down
2 changes: 1 addition & 1 deletion bpf-prog/ipv6-hp-bpf/go.mod
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
module github.com/Azure/azure-container-networking/bpf-prog/ipv6-hp-bpf

go 1.21.6
go 1.22.7

require (
github.com/cilium/ebpf v0.15.0
Expand Down
18 changes: 9 additions & 9 deletions bpf-prog/ipv6-hp-bpf/linux.Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM mcr.microsoft.com/oss/go/microsoft/golang:1.21 AS builder
FROM mcr.microsoft.com/oss/go/microsoft/golang:1.22 AS builder
ARG VERSION
ARG DEBUG
ARG OS
Expand All @@ -10,15 +10,15 @@ COPY ./bpf-prog/ipv6-hp-bpf/include/helper.h /bpf-prog/ipv6-hp-bpf/include/helpe
RUN apt-get update && apt-get install -y llvm clang linux-libc-dev linux-headers-generic libbpf-dev libc6-dev nftables iproute2
RUN mkdir -p /tmp/lib
RUN if [ "$ARCH" = "arm64" ]; then \
apt-get install -y gcc-aarch64-linux-gnu && \
ARCH=aarch64-linux-gnu && \
cp /lib/"$ARCH"/ld-linux-aarch64.so.1 /tmp/lib/ && \
for dir in /usr/include/"$ARCH"/*; do ln -s "$dir" /usr/include/$(basename "$dir"); done; \
apt-get install -y gcc-aarch64-linux-gnu && \
ARCH=aarch64-linux-gnu && \
cp /lib/"$ARCH"/ld-linux-aarch64.so.1 /tmp/lib/ && \
for dir in /usr/include/"$ARCH"/*; do ln -s "$dir" /usr/include/$(basename "$dir"); done; \
elif [ "$ARCH" = "amd64" ]; then \
apt-get install -y gcc-multilib && \
ARCH=x86_64-linux-gnu && \
cp /lib/"$ARCH"/ld-linux-x86-64.so.2 /tmp/lib/ && \
for dir in /usr/include/"$ARCH"/*; do ln -s "$dir" /usr/include/$(basename "$dir"); done; \
apt-get install -y gcc-multilib && \
ARCH=x86_64-linux-gnu && \
cp /lib/"$ARCH"/ld-linux-x86-64.so.2 /tmp/lib/ && \
for dir in /usr/include/"$ARCH"/*; do ln -s "$dir" /usr/include/$(basename "$dir"); done; \
fi && \
ln -sfn /usr/include/"$ARCH"/asm /usr/include/asm && \
cp /lib/"$ARCH"/libnftables.so.1 /tmp/lib/ && \
Expand Down
2 changes: 1 addition & 1 deletion build/tools/go.mod
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
module github.com/Azure/azure-container-networking/build/tools

go 1.21
go 1.22.7

require (
github.com/AlekSi/gocov-xml v1.1.0
Expand Down
4 changes: 2 additions & 2 deletions cni/linux.Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ ARG DROPGZ_VERSION=v0.0.12
ARG OS_VERSION
ARG OS

FROM mcr.microsoft.com/oss/go/microsoft/golang:1.21 AS azure-vnet
FROM mcr.microsoft.com/oss/go/microsoft/golang:1.22 AS azure-vnet
ARG OS
ARG VERSION
WORKDIR /azure-container-networking
Expand All @@ -29,7 +29,7 @@ COPY --from=azure-vnet /azure-container-networking/telemetry/azure-vnet-telemetr
RUN cd /payload && sha256sum * > sum.txt
RUN gzip --verbose --best --recursive /payload && for f in /payload/*.gz; do mv -- "$f" "${f%%.gz}"; done

FROM mcr.microsoft.com/oss/go/microsoft/golang:1.21 AS dropgz
FROM mcr.microsoft.com/oss/go/microsoft/golang:1.22 AS dropgz
ARG DROPGZ_VERSION
ARG OS
ARG VERSION
Expand Down
4 changes: 2 additions & 2 deletions cni/windows.Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ ARG DROPGZ_VERSION=v0.0.12
ARG OS
ARG OS_VERSION

FROM --platform=linux/${ARCH} mcr.microsoft.com/oss/go/microsoft/golang:1.21 AS azure-vnet
FROM --platform=linux/${ARCH} mcr.microsoft.com/oss/go/microsoft/golang:1.22 AS azure-vnet
ARG OS
ARG VERSION
WORKDIR /azure-container-networking
Expand All @@ -26,7 +26,7 @@ COPY --from=azure-vnet /azure-container-networking/telemetry/azure-vnet-telemetr
RUN cd /payload && sha256sum * > sum.txt
RUN gzip --verbose --best --recursive /payload && for f in /payload/*.gz; do mv -- "$f" "${f%%.gz}"; done

FROM --platform=linux/${ARCH} mcr.microsoft.com/oss/go/microsoft/golang:1.21 AS dropgz
FROM --platform=linux/${ARCH} mcr.microsoft.com/oss/go/microsoft/golang:1.22 AS dropgz
ARG DROPGZ_VERSION
ARG OS
ARG VERSION
Expand Down
2 changes: 1 addition & 1 deletion cns/linux.Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM mcr.microsoft.com/oss/go/microsoft/golang:1.21 AS builder
FROM mcr.microsoft.com/oss/go/microsoft/golang:1.22 AS builder
ARG VERSION
ARG CNS_AI_PATH
ARG CNS_AI_ID
Expand Down
2 changes: 1 addition & 1 deletion cns/windows.Dockerfile
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
ARG OS_VERSION
FROM --platform=linux/amd64 mcr.microsoft.com/oss/go/microsoft/golang:1.21 AS builder
FROM --platform=linux/amd64 mcr.microsoft.com/oss/go/microsoft/golang:1.22 AS builder
ARG VERSION
ARG CNS_AI_PATH
ARG CNS_AI_ID
Expand Down
2 changes: 1 addition & 1 deletion dropgz/build/linux.Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ COPY --from=azure-vnet /azure-container-networking/azure-vnet-ipam pkg/embed/fs
RUN cd pkg/embed/fs/ && sha256sum * > sum.txt
RUN gzip --verbose --best --recursive pkg/embed/fs && for f in pkg/embed/fs/*.gz; do mv -- "$f" "${f%%.gz}"; done

FROM mcr.microsoft.com/oss/go/microsoft/golang:1.21 AS dropgz
FROM mcr.microsoft.com/oss/go/microsoft/golang:1.22 AS dropgz
ARG VERSION
WORKDIR /dropgz
COPY --from=compressor /dropgz .
Expand Down
2 changes: 1 addition & 1 deletion dropgz/build/windows.Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ COPY --from=azure-vnet /azure-container-networking/azure-vnet-telemetry.config p
RUN cd pkg/embed/fs/ && sha256sum * > sum.txt
RUN gzip --verbose --best --recursive pkg/embed/fs && for f in pkg/embed/fs/*.gz; do mv -- "$f" "${f%%.gz}"; done

FROM --platform=linux/${ARCH} mcr.microsoft.com/oss/go/microsoft/golang:1.21 AS dropgz
FROM --platform=linux/${ARCH} mcr.microsoft.com/oss/go/microsoft/golang:1.22 AS dropgz
ARG VERSION
WORKDIR /dropgz
COPY --from=compressor /dropgz .
Expand Down
2 changes: 1 addition & 1 deletion dropgz/go.mod
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
module github.com/Azure/azure-container-networking/dropgz

go 1.21
go 1.22.7

require (
github.com/jsternberg/zap-logfmt v1.3.0
Expand Down
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
module github.com/Azure/azure-container-networking

go 1.21
go 1.22.7

require (
github.com/Azure/azure-sdk-for-go/sdk/azcore v1.12.0
Expand Down
2 changes: 1 addition & 1 deletion hack/toolbox/Dockerfile.windows
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# Build cns
FROM mcr.microsoft.com/oss/go/microsoft/golang:1.21 AS builder
FROM mcr.microsoft.com/oss/go/microsoft/golang:1.22 AS builder
# Build args
ARG VERSION
ARG CNS_AI_PATH
Expand Down
2 changes: 1 addition & 1 deletion hack/toolbox/server/Dockerfile.heavy
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM mcr.microsoft.com/oss/go/microsoft/golang:1.21 as build
FROM mcr.microsoft.com/oss/go/microsoft/golang:1.22 as build
ADD ./ /
WORKDIR /
RUN CGO_ENABLED=0 GOOS=linux go build -o server .
Expand Down
2 changes: 1 addition & 1 deletion hack/toolbox/server/Dockerfile.lite
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM mcr.microsoft.com/oss/go/microsoft/golang:1.21 as build
FROM mcr.microsoft.com/oss/go/microsoft/golang:1.22 as build
ADD ./server/server.go /
ADD ./server/go.mod /
WORKDIR /
Expand Down
2 changes: 1 addition & 1 deletion npm/linux.Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM mcr.microsoft.com/oss/go/microsoft/golang:1.21 AS builder
FROM mcr.microsoft.com/oss/go/microsoft/golang:1.22 AS builder
ARG VERSION
ARG NPM_AI_PATH
ARG NPM_AI_ID
Expand Down
Loading

0 comments on commit 0ab889c

Please sign in to comment.