Skip to content
This repository was archived by the owner on Nov 6, 2023. It is now read-only.

Commit 134bdfa

Browse files
authored
bump openyurt version to v0.6.1 (#22)
* bump openyurt version to v0.6.1 * makefile: download kustomize if not exists
1 parent 2f3e851 commit 134bdfa

File tree

5 files changed

+33
-17
lines changed

5 files changed

+33
-17
lines changed

Makefile

+29-13
Original file line numberDiff line numberDiff line change
@@ -45,27 +45,27 @@ run: generate fmt vet manifests
4545
go run --ldflags "${GO_LD_FLAGS}" ./cmd/manager/manager.go
4646

4747
# Install CRDs into a cluster
48-
install: manifests
49-
kustomize build config/crd | kubectl apply -f -
48+
install: manifests kustomize
49+
$(KUSTOMIZE) build config/crd | kubectl apply -f -
5050

5151
# Uninstall CRDs from a cluster
52-
uninstall: manifests
53-
kustomize build config/crd | kubectl delete -f -
52+
uninstall: manifests kustomize
53+
$(KUSTOMIZE) build config/crd | kubectl delete -f -
5454

5555
# Deploy controller in the configured Kubernetes cluster in ~/.kube/config
56-
deploy: manifests
57-
cd config/manager && kustomize edit set image yurtcluster-operator-manager=${MANAGER_IMG}
58-
cd config/agent && kustomize edit set image yurtcluster-operator-agent=${AGENT_IMG}
59-
kustomize build config/default | kubectl apply -f -
56+
deploy: manifests kustomize
57+
cd config/manager && $(KUSTOMIZE) edit set image yurtcluster-operator-manager=${MANAGER_IMG}
58+
cd config/agent && $(KUSTOMIZE) edit set image yurtcluster-operator-agent=${AGENT_IMG}
59+
$(KUSTOMIZE) build config/default | kubectl apply -f -
6060

6161
# Release manifests into docs/manifests and push docker image to dockerhub
6262
release-artifacts: docker-push release-manifests
6363

6464
# Release manifests into docs/manifests
65-
release-manifests: manifests
66-
cd config/manager && kustomize edit set image yurtcluster-operator-manager=${MANAGER_IMG}
67-
cd config/agent && kustomize edit set image yurtcluster-operator-agent=${AGENT_IMG}
68-
kustomize build config/default > docs/manifests/deploy.yaml
65+
release-manifests: manifests kustomize
66+
cd config/manager && $(KUSTOMIZE) edit set image yurtcluster-operator-manager=${MANAGER_IMG}
67+
cd config/agent && $(KUSTOMIZE) edit set image yurtcluster-operator-agent=${AGENT_IMG}
68+
$(KUSTOMIZE) build config/default > docs/manifests/deploy.yaml
6969

7070
# Generate manifests e.g. CRD, RBAC etc.
7171
manifests: controller-gen
@@ -118,7 +118,7 @@ ifeq (, $(shell which controller-gen))
118118
CONTROLLER_GEN_TMP_DIR=$$(mktemp -d) ;\
119119
cd $$CONTROLLER_GEN_TMP_DIR ;\
120120
go mod init tmp ;\
121-
go get sigs.k8s.io/controller-tools/cmd/controller-gen@v0.2.5 ;\
121+
go get sigs.k8s.io/controller-tools/cmd/controller-gen@v0.5.0 ;\
122122
rm -rf $$CONTROLLER_GEN_TMP_DIR ;\
123123
}
124124
CONTROLLER_GEN=$(GOBIN)/controller-gen
@@ -141,3 +141,19 @@ GOLANGCI_LINT=$(GOBIN)/golangci-lint
141141
else
142142
GOLANGCI_LINT=$(shell which golangci-lint)
143143
endif
144+
145+
# find or download kustomize
146+
kustomize:
147+
ifeq (, $(shell which kustomize))
148+
@{ \
149+
set -e ;\
150+
KUSTOMIZE_TMP_DIR=$$(mktemp -d) ;\
151+
cd $$KUSTOMIZE_TMP_DIR ;\
152+
go mod init tmp ;\
153+
go get sigs.k8s.io/kustomize/kustomize/[email protected] ;\
154+
rm -rf $$KUSTOMIZE_TMP_DIR ;\
155+
}
156+
KUSTOMIZE=$(GOBIN)/kustomize
157+
else
158+
KUSTOMIZE=$(shell which kustomize)
159+
endif

api/v1alpha1/defaults.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ import (
2222

2323
const (
2424
// DefaultYurtVersion defines the default yurt version (image tag)
25-
DefaultYurtVersion = "v0.6.0"
25+
DefaultYurtVersion = "v0.6.1"
2626

2727
// DefaultYurtImageRepository defines the default repository for the yurt component images
2828
DefaultYurtImageRepository = "docker.io/openyurt"

charts/charts/yurt-controller-manager/values.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44

55
manager:
66
replicas: 3
7-
image: "openyurt/yurt-controller-manager:v0.6.0"
7+
image: "openyurt/yurt-controller-manager:v0.6.1"
88
imagePullPolicy: IfNotPresent
99
nodeSelector:
1010
openyurt.io/is-edge-worker: "false"

charts/values.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ agent:
1818
yurt-controller-manager:
1919
manager:
2020
replicas: 3
21-
image: "openyurt/yurt-controller-manager:v0.6.0"
21+
image: "openyurt/yurt-controller-manager:v0.6.1"
2222
imagePullPolicy: IfNotPresent
2323
nodeSelector:
2424
openyurt.io/is-edge-worker: "false"

config/samples/operator_v1alpha1_yurtcluster.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ kind: YurtCluster
33
metadata:
44
name: cluster
55
spec:
6-
yurtVersion: "v0.6.0"
6+
yurtVersion: "v0.6.1"
77
cloudNodes:
88
selector:
99
nodeSelectorTerms:

0 commit comments

Comments
 (0)