Skip to content

Commit cd4d091

Browse files
committed
bump to go v1.24
1 parent d8e8fa2 commit cd4d091

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

46 files changed

+734
-1739
lines changed

.devcontainer/Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
# See here for image contents: https://github.com/microsoft/vscode-dev-containers/tree/v0.203.0/containers/go/.devcontainer/base.Dockerfile
22

33
# [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
4-
ARG VARIANT="1.22"
4+
ARG VARIANT="dev-1.24"
55
FROM mcr.microsoft.com/vscode/devcontainers/go:${VARIANT}
66

77
# [Choice] Node.js version: none, lts/*, 16, 14, 12, 10

.devcontainer/devcontainer.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
// Update the VARIANT arg to pick a version of Go: 1, 1.16, 1.17
99
// Append -bullseye or -buster to pin to an OS version.
1010
// Use -bullseye variants on local arm64/Apple Silicon.
11-
"VARIANT": "1.22-bullseye",
11+
"VARIANT": "dev-1.24",
1212
// Options
1313
"NODE_VERSION": "none"
1414
}

.github/dependabot.yaml

Lines changed: 0 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -47,17 +47,6 @@ updates:
4747
- "azure/azure-sdn-members"
4848
commit-message:
4949
prefix: "deps"
50-
- package-ecosystem: "gomod"
51-
directory: "/build/tools"
52-
schedule:
53-
interval: "daily"
54-
assignees:
55-
- "matmerr"
56-
- "rbtr"
57-
reviewers:
58-
- "azure/azure-sdn-members"
59-
commit-message:
60-
prefix: "deps"
6150
- package-ecosystem: "gomod"
6251
directory: "/dropgz"
6352
schedule:

.github/workflows/crdgen.yaml

Lines changed: 3 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -8,20 +8,16 @@ on:
88
- synchronize
99
- ready_for_review
1010
jobs:
11-
crdgen119:
12-
strategy:
13-
matrix:
14-
go-version: ["1.23", "1.24"]
15-
os: [ubuntu-latest]
11+
crdgen:
1612
name: CRDs are Generated
17-
runs-on: ${{ matrix.os }}
13+
runs-on: ubuntu-latest
1814
steps:
1915
- uses: actions/checkout@v4
2016
with:
2117
fetch-depth: 0
2218
- uses: actions/setup-go@v5
2319
with:
24-
go-version: ${{ matrix.go-version }}
20+
go-version: stable
2521
- name: Regenerate NodeNetworkConfig CRD
2622
run: make -C crd/nodenetworkconfig
2723
- name: Regenerate MultitenantNetworkContainer CRD

.github/workflows/cyclonus-netpol-extended-nightly-test.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ jobs:
2727

2828
- uses: actions/setup-go@v5
2929
with:
30-
go-version: "^1.22"
30+
go-version: stable
3131

3232
- name: Setup Kind
3333
uses: engineerd/[email protected]

.github/workflows/cyclonus-netpol-test.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ jobs:
3434

3535
- uses: actions/setup-go@v5
3636
with:
37-
go-version: '^1.23'
37+
go-version: stable
3838

3939
- name: Setup Kind
4040
uses: helm/kind-action@v1

.github/workflows/golangci.yaml

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -15,19 +15,18 @@ jobs:
1515
strategy:
1616
fail-fast: false
1717
matrix:
18-
go-version: ['1.23.x', '1.24.x']
1918
os: [ubuntu-latest, windows-latest]
2019
name: Lint
2120
runs-on: ${{ matrix.os }}
2221
steps:
2322
- uses: actions/setup-go@v5
2423
with:
25-
go-version: ${{ matrix.go-version }}
24+
go-version: stable
2625
- uses: actions/checkout@v4
2726
with:
2827
fetch-depth: 0
2928
- name: golangci-lint
3029
uses: golangci/golangci-lint-action@v6
3130
with:
32-
version: v1.61
31+
version: latest
3332
args: --new-from-rev=origin/release/v1.4 --config=.golangci.yml --timeout=25m

.gitignore

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,6 @@ ipam-*.xml
2222
*.test
2323

2424
controller-gen
25-
build/tools/bin
2625
npm/debug/http
2726

2827
# certificates

.pipelines/pipeline.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,7 @@ stages:
6868
{ { { {
6969
sudo -E env "PATH=$PATH" make test-all;
7070
echo $? >&3;
71-
} | tee >(build/tools/bin/go-junit-report > report.xml) >&4;
71+
} | tee >(go tool go-junit-report > report.xml) >&4;
7272
} 3>&1;
7373
} | { read xs; exit $xs; }
7474
} 4>&1

Makefile

Lines changed: 5 additions & 65 deletions
Original file line numberDiff line numberDiff line change
@@ -65,8 +65,6 @@ CNI_OVERLAY_BUILD_DIR = $(BUILD_DIR)/cni-overlay
6565
CNI_BAREMETAL_BUILD_DIR = $(BUILD_DIR)/cni-baremetal
6666
CNS_BUILD_DIR = $(BUILD_DIR)/cns
6767
NPM_BUILD_DIR = $(BUILD_DIR)/npm
68-
TOOLS_DIR = $(REPO_ROOT)/build/tools
69-
TOOLS_BIN_DIR = $(TOOLS_DIR)/bin
7068
CNI_AI_ID = 5515a1eb-b2bc-406a-98eb-ba462e6f0411
7169
CNS_AI_ID = ce672799-8f08-4235-8c12-08563dc2acef
7270
NPM_AI_ID = 014c22bd-4107-459e-8475-67909e96edcb
@@ -75,15 +73,6 @@ CNI_AI_PATH=$(ACN_PACKAGE_PATH)/telemetry.aiMetadata
7573
CNS_AI_PATH=$(ACN_PACKAGE_PATH)/cns/logger.aiMetadata
7674
NPM_AI_PATH=$(ACN_PACKAGE_PATH)/npm.aiMetadata
7775

78-
# Tool paths
79-
CONTROLLER_GEN := $(TOOLS_BIN_DIR)/controller-gen
80-
GOCOV := $(TOOLS_BIN_DIR)/gocov
81-
GOCOV_XML := $(TOOLS_BIN_DIR)/gocov-xml
82-
GOFUMPT := $(TOOLS_BIN_DIR)/gofumpt
83-
GOLANGCI_LINT := $(TOOLS_BIN_DIR)/golangci-lint
84-
GO_JUNIT_REPORT := $(TOOLS_BIN_DIR)/go-junit-report
85-
MOCKGEN := $(TOOLS_BIN_DIR)/mockgen
86-
8776
# Archive file names.
8877
ACNCLI_ARCHIVE_NAME = acncli-$(GOOS)-$(GOARCH)-$(ACN_VERSION).$(ARCHIVE_EXT)
8978
CNI_ARCHIVE_NAME = azure-vnet-cni-$(GOOS)-$(GOARCH)-$(CNI_VERSION).$(ARCHIVE_EXT)
@@ -680,16 +669,17 @@ endif
680669

681670
clean: ## Clean build artifacts.
682671
$(RMDIR) $(OUTPUT_DIR)
683-
$(RMDIR) $(TOOLS_BIN_DIR)
684672
$(RMDIR) go.work*
685673

686674

687675
LINT_PKG ?= .
688676

689-
lint: $(GOLANGCI_LINT) ## Fast lint vs default branch showing only new issues.
677+
GOLANGCI_LINT = go tool golangci-lint
678+
679+
lint: ## Fast lint vs default branch showing only new issues.
690680
GOGC=20 $(GOLANGCI_LINT) run --new-from-rev release/v1.4 --timeout 10m -v $(LINT_PKG)/...
691681

692-
lint-all: $(GOLANGCI_LINT) ## Lint the current branch in entirety.
682+
lint-all: ## Lint the current branch in entirety.
693683
GOGC=20 $(GOLANGCI_LINT) run -v $(LINT_PKG)/...
694684

695685

@@ -761,57 +751,7 @@ gitconfig: ## configure the local git repository
761751
@git config core.fsmonitor true
762752
@git config core.untrackedcache true
763753

764-
setup: tools install-hooks gitconfig ## performs common required repo setup
765-
766-
767-
##@ Tools
768-
769-
$(TOOLS_DIR)/go.mod:
770-
cd $(TOOLS_DIR); go mod init && go mod tidy
771-
772-
$(CONTROLLER_GEN): $(TOOLS_DIR)/go.mod
773-
cd $(TOOLS_DIR); go mod download; go build -o bin/controller-gen sigs.k8s.io/controller-tools/cmd/controller-gen
774-
775-
controller-gen: $(CONTROLLER_GEN) ## Build controller-gen
776-
777-
protoc:
778-
source ${REPO_ROOT}/scripts/install-protoc.sh
779-
780-
$(GOCOV): $(TOOLS_DIR)/go.mod
781-
cd $(TOOLS_DIR); go mod download; go build -o bin/gocov github.com/axw/gocov/gocov
782-
783-
gocov: $(GOCOV) ## Build gocov
784-
785-
$(GOCOV_XML): $(TOOLS_DIR)/go.mod
786-
cd $(TOOLS_DIR); go mod download; go build -o bin/gocov-xml github.com/AlekSi/gocov-xml
787-
788-
gocov-xml: $(GOCOV_XML) ## Build gocov-xml
789-
790-
$(GOFUMPT): $(TOOLS_DIR)/go.mod
791-
cd $(TOOLS_DIR); go mod download; go build -o bin/gofumpt mvdan.cc/gofumpt
792-
793-
gofumpt: $(GOFUMPT) ## Build gofumpt
794-
795-
$(GOLANGCI_LINT): $(TOOLS_DIR)/go.mod
796-
cd $(TOOLS_DIR); go mod download; go build -o bin/golangci-lint github.com/golangci/golangci-lint/cmd/golangci-lint
797-
798-
golangci-lint: $(GOLANGCI_LINT) ## Build golangci-lint
799-
800-
$(GO_JUNIT_REPORT): $(TOOLS_DIR)/go.mod
801-
cd $(TOOLS_DIR); go mod download; go build -o bin/go-junit-report github.com/jstemmer/go-junit-report
802-
803-
go-junit-report: $(GO_JUNIT_REPORT) ## Build go-junit-report
804-
805-
$(MOCKGEN): $(TOOLS_DIR)/go.mod
806-
cd $(TOOLS_DIR); go mod download; go build -o bin/mockgen github.com/golang/mock/mockgen
807-
808-
mockgen: $(MOCKGEN) ## Build mockgen
809-
810-
clean-tools:
811-
rm -r build/tools/bin
812-
813-
tools: acncli gocov gocov-xml go-junit-report golangci-lint gofumpt protoc ## Build bins for build tools
814-
754+
setup: install-hooks gitconfig ## performs common required repo setup
815755

816756
##@ Help
817757

0 commit comments

Comments
 (0)