Skip to content

Commit

Permalink
fix chart install/upgrade e2e (#2426)
Browse files Browse the repository at this point in the history
  • Loading branch information
zhangzujian committed Mar 6, 2023
1 parent f2c55a5 commit 4cec68c
Show file tree
Hide file tree
Showing 4 changed files with 17 additions and 17 deletions.
6 changes: 1 addition & 5 deletions .github/workflows/build-x86-image.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -643,11 +643,7 @@ jobs:
sudo chown -R $(id -un). ~/.kube/
- name: Install Kube-OVN
run: |
make kind-install-chart
kubectl rollout status deployment/ovn-central -n kube-system --timeout 300s
kubectl rollout status deployment/kube-ovn-controller -n kube-system --timeout 300s
kubectl rollout status daemonset/kube-ovn-cni -n kube-system --timeout 300s
run: make kind-install-chart

- name: Cleanup
run: sh dist/images/cleanup.sh
Expand Down
25 changes: 14 additions & 11 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -251,17 +251,20 @@ kind-untaint-control-plane:
done

.PHONY: kind-install-chart
kind-install-chart: kind-untaint-control-plane
kubectl label no -lbeta.kubernetes.io/os=linux kubernetes.io/os=linux --overwrite
kubectl label no -lnode-role.kubernetes.io/control-plane kube-ovn/role=master --overwrite
kubectl label no -lovn.kubernetes.io/ovs_dp_type!=userspace ovn.kubernetes.io/ovs_dp_type=kernel --overwrite
$(eval MASTERNODES = $(shell docker exec -i kube-ovn-control-plane kubectl get nodes -l node-role.kubernetes.io/control-plane="" -o jsonpath='{.items[*].status.addresses[].address}'))
$(eval EMPTY := )
$(eval SPACE := $(EMPTY))
$(eval MASTERS = $(subst SPACE,,,$(strip $$(MASTERNODES))))
kind load docker-image --name kube-ovn $(REGISTRY)/kube-ovn:$(RELEASE_TAG)
helm install kubeovn ./kubeovn-helm --set cni_conf.MASTER_NODES=$(MASTERNODES)
kubectl -n kube-system get pods -o wide
kind-install-chart: kind-load-image kind-untaint-control-plane
kubectl label node -lbeta.kubernetes.io/os=linux kubernetes.io/os=linux --overwrite
kubectl label node -lnode-role.kubernetes.io/control-plane kube-ovn/role=master --overwrite
kubectl label node -lovn.kubernetes.io/ovs_dp_type!=userspace ovn.kubernetes.io/ovs_dp_type=kernel --overwrite
ips=$$(kubectl get node -lkube-ovn/role=master --no-headers -o wide | awk '{print $$6}') && \
helm install kubeovn ./kubeovn-helm \
--set global.images.kubeovn.tag=$(VERSION) \
--set replicaCount=$$(echo $$ips | awk '{print NF}') \
--set cni_conf.MASTER_NODES="$$(echo $$ips | tr \\n ',' | sed -e 's/,$$//' -e 's/,/\\,/g')"
kubectl rollout status deployment/ovn-central -n kube-system --timeout 300s
kubectl rollout status deployment/kube-ovn-controller -n kube-system --timeout 120s
kubectl rollout status daemonset/kube-ovn-cni -n kube-system --timeout 120s
kubectl rollout status daemonset/kube-ovn-pinger -n kube-system --timeout 120s
kubectl rollout status deployment/coredns -n kube-system --timeout 60s

.PHONY: kind-install
kind-install: kind-load-image
Expand Down
1 change: 1 addition & 0 deletions kubeovn-helm/templates/ovn-CR.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@ rules:
- watch
- patch
- update
- delete
- apiGroups:
- ""
- networking.k8s.io
Expand Down
2 changes: 1 addition & 1 deletion kubeovn-helm/values.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ global:
images:
kubeovn:
repository: kube-ovn
tag: v1.9.18
tag: v1.9.19
support_arm: true
thirdparty: true

Expand Down

0 comments on commit 4cec68c

Please sign in to comment.