This repository has been archived by the owner on Oct 6, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #46 from everpeace/upgrade-v1.24.3
Upgrade Kubernetes v1.24.3 (go 1.18)
- Loading branch information
Showing
18 changed files
with
347 additions
and
293 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
FROM golang:1.17 as builder | ||
FROM golang:1.18 as builder | ||
ARG RELEASE | ||
ARG VERSION | ||
WORKDIR /workspace | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -35,7 +35,7 @@ generate: codegen crd | |
|
||
.PHONY: codegen | ||
codegen: | ||
./hack/update-codegen.sh | ||
CODEGEN_PKG=$(CODEGEN_PKG) ./hack/update-codegen.sh | ||
$(GO_LICENSER) --licensor "Shingo Omura" | ||
|
||
.PHONY: crd | ||
|
@@ -97,29 +97,24 @@ GOLANGCI_LINT = $(DEV_TOOL_PREFIX)/bin/golangci-lint | |
GO_LICENSER = $(DEV_TOOL_PREFIX)/bin/go-licenser | ||
GO_IMPORTS = $(DEV_TOOL_PREFIX)/bin/goimports | ||
CONTROLLER_GEN = $(DEV_TOOL_PREFIX)/bin/controller-gen | ||
CODEGEN_PKG=$(CODEGEN_PKG_NAME)@$(CODEGEN_PKG_VERSION) | ||
CODEGEN_PKG_NAME=k8s.io/code-generator | ||
CODEGEN_PKG_VERSION=v0.24.3 | ||
KIND = $(DEV_TOOL_PREFIX)/bin/kind | ||
KIND_KUBECNOFIG = $(DEV_TOOL_PREFIX)/.kubeconfig | ||
setup: | ||
$(call go-get-tool,$(GO_IMPORTS),golang.org/x/tools/cmd/goimports) | ||
$(call go-get-tool,$(GO_LICENSER),github.com/elastic/go-licenser) | ||
$(call go-get-tool,$(GIT_SEMV),github.com/linyows/git-semv/cmd/git-semv) | ||
$(call go-get-tool,$(CONTROLLER_GEN),sigs.k8s.io/controller-tools/cmd/[email protected]) | ||
$(call go-get-tool,$(KIND),sigs.k8s.io/kind) | ||
cd $(shell go env GOPATH) && \ | ||
curl -sSfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh | sh -s -- -b $(DEV_TOOL_PREFIX)/bin v1.43.0 | ||
|
||
# go-get-tool will 'go get' any package $2 and install it to $1. | ||
define go-get-tool | ||
@[ -f $(1) ] || { \ | ||
set -e ;\ | ||
TMP_DIR=$$(mktemp -d) ;\ | ||
cd $$TMP_DIR ;\ | ||
go mod init tmp ;\ | ||
echo "Downloading $(2)" ;\ | ||
GOBIN=$(DEV_TOOL_PREFIX)/bin go get $(2) ;\ | ||
rm -rf $$TMP_DIR ;\ | ||
} | ||
endef | ||
GOBIN=$(DEV_TOOL_PREFIX)/bin go install golang.org/x/tools/cmd/goimports@latest | ||
GOBIN=$(DEV_TOOL_PREFIX)/bin go install github.com/elastic/go-licenser@latest | ||
GOBIN=$(DEV_TOOL_PREFIX)/bin go install github.com/linyows/git-semv/cmd/git-semv@latest | ||
GOBIN=$(DEV_TOOL_PREFIX)/bin go install sigs.k8s.io/controller-tools/cmd/[email protected] | ||
go mod download $(CODEGEN_PKG) | ||
GOBIN=$(DEV_TOOL_PREFIX)/bin go install $(CODEGEN_PKG_NAME)/cmd/defaulter-gen@$(CODEGEN_PKG_VERSION) | ||
GOBIN=$(DEV_TOOL_PREFIX)/bin go install $(CODEGEN_PKG_NAME)/cmd/client-gen@$(CODEGEN_PKG_VERSION) | ||
GOBIN=$(DEV_TOOL_PREFIX)/bin go install $(CODEGEN_PKG_NAME)/cmd/lister-gen@$(CODEGEN_PKG_VERSION) | ||
GOBIN=$(DEV_TOOL_PREFIX)/bin go install $(CODEGEN_PKG_NAME)/cmd/informer-gen@$(CODEGEN_PKG_VERSION) | ||
GOBIN=$(DEV_TOOL_PREFIX)/bin go install $(CODEGEN_PKG_NAME)/cmd/deepcopy-gen@$(CODEGEN_PKG_VERSION) | ||
GOBIN=$(DEV_TOOL_PREFIX)/bin go install sigs.k8s.io/kind@latest | ||
GOBIN=$(DEV_TOOL_PREFIX)/bin go install github.com/golangci/golangci-lint/cmd/[email protected] | ||
|
||
# | ||
# local development | ||
|
@@ -158,7 +153,7 @@ export E2E_GOMEGA_DEFAULT_CONSISTENTLY_DURATION=2s | |
E2E_PAUSE_IMAGE=k8s.gcr.io/pause:3.2 | ||
E2E_KIND_KUBECNOFIG = $(DEV_TOOL_PREFIX)/.kubeconfig | ||
E2E_KIND_CONF=./hack/e2e/kind.conf | ||
E2E_NODE_IMAGE ?= kindest/node:v1.23.4 | ||
E2E_NODE_IMAGE ?= kindest/node:v1.24.3 | ||
e2e-setup: | ||
$(KIND) get clusters | grep kube-throttler-e2e 2>&1 >/dev/null \ | ||
|| $(KIND) create cluster --name=kube-throttler-e2e \ | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.