Skip to content

Commit

Permalink
Update kind to 0.15 to support deloy k8s 1.25 environment
Browse files Browse the repository at this point in the history
Signed-off-by: jwcesign <jiangwei115@huawei.com>
  • Loading branch information
jwcesign committed Sep 21, 2022
1 parent ab88988 commit 58e302b
Show file tree
Hide file tree
Showing 7 changed files with 16 additions and 22 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ jobs:
runs-on: ubuntu-20.04
strategy:
matrix:
k8s: [ v1.21.10, v1.22.7, v1.23.4, v1.24.2 ]
k8s: [ v1.21.10, v1.22.7, v1.23.4, v1.24.2, v1.25.0 ]
steps:
- name: checkout code
uses: actions/checkout@v2
Expand Down
2 changes: 0 additions & 2 deletions artifacts/kindClusterConfig/general-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,6 @@ networking:
disableDefaultCNI: {{disable_cni}}
podSubnet: {{pod_cidr}}
serviceSubnet: {{service_cidr}}
featureGates:
EndpointSliceProxying: true
nodes:
- role: control-plane
- role: worker
2 changes: 0 additions & 2 deletions artifacts/kindClusterConfig/member1.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,5 @@ apiVersion: "kind.x-k8s.io/v1alpha4"
networking:
podSubnet: "10.10.0.0/16"
serviceSubnet: "10.11.0.0/16"
featureGates:
EndpointSliceProxying: true
nodes:
- role: control-plane
2 changes: 0 additions & 2 deletions artifacts/kindClusterConfig/member2.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,5 @@ apiVersion: "kind.x-k8s.io/v1alpha4"
networking:
podSubnet: "10.12.0.0/16"
serviceSubnet: "10.13.0.0/16"
featureGates:
EndpointSliceProxying: true
nodes:
- role: control-plane
2 changes: 1 addition & 1 deletion hack/local-up-karmada.sh
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ util::verify_go_version
util::cmd_must_exist "docker"

# install kind and kubectl
kind_version=v0.14.0
kind_version=v0.15.0
echo -n "Preparing: 'kind' existence check - "
if util::cmd_exist kind; then
echo "passed"
Expand Down
3 changes: 1 addition & 2 deletions hack/post-run-e2e.sh
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,7 @@ kubectl --context="${HOST_CLUSTER_NAME}" delete -f "${REPO_ROOT}"/examples/custo

# uninstall metallb
kubectl --context="${HOST_CLUSTER_NAME}" delete configmap config -n metallb-system
kubectl --context="${HOST_CLUSTER_NAME}" delete -f https://raw.githubusercontent.com/metallb/metallb/v0.12.1/manifests/metallb.yaml
kubectl --context="${HOST_CLUSTER_NAME}" delete -f https://raw.githubusercontent.com/metallb/metallb/v0.12.1/manifests/namespace.yaml
kubectl --context="${HOST_CLUSTER_NAME}" delete -f https://raw.githubusercontent.com/metallb/metallb/v0.13.5/config/manifests/metallb-native.yaml

kubectl --context="${HOST_CLUSTER_NAME}" get configmap kube-proxy -n kube-system -o yaml | \
sed -e "s/strictARP: true/strictARP: false/" | \
Expand Down
25 changes: 13 additions & 12 deletions hack/pre-run-e2e.sh
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,7 @@ sed -e "s/strictARP: false/strictARP: true/" | \
kubectl --context="${HOST_CLUSTER_NAME}" apply -f - -n kube-system

# install metallb by manifest, refer to https://metallb.universe.tf/installation/#installation-by-manifest
kubectl --context="${HOST_CLUSTER_NAME}" apply -f https://raw.githubusercontent.com/metallb/metallb/v0.12.1/manifests/namespace.yaml
kubectl --context="${HOST_CLUSTER_NAME}" apply -f https://raw.githubusercontent.com/metallb/metallb/v0.12.1/manifests/metallb.yaml
kubectl --context="${HOST_CLUSTER_NAME}" apply -f https://raw.githubusercontent.com/metallb/metallb/v0.13.5/config/manifests/metallb-native.yaml
util::wait_pod_ready "${HOST_CLUSTER_NAME}" metallb metallb-system

# Use x.x.x.6 IP address, which is the same CIDR with the node address of the Kind cluster,
Expand All @@ -45,18 +44,20 @@ interpreter_webhook_example_service_external_ip_address=${interpreter_webhook_ex

# config with layer 2 configuration. refer to https://metallb.universe.tf/configuration/#layer-2-configuration
cat <<EOF | kubectl --context="${HOST_CLUSTER_NAME}" apply -f -
apiVersion: v1
kind: ConfigMap
apiVersion: metallb.io/v1beta1
kind: IPAddressPool
metadata:
name: metallb-config
namespace: metallb-system
spec:
addresses:
- ${interpreter_webhook_example_service_external_ip_address}-${interpreter_webhook_example_service_external_ip_address}
---
apiVersion: metallb.io/v1beta1
kind: L2Advertisement
metadata:
name: metallb-advertisement
namespace: metallb-system
name: config
data:
config: |
address-pools:
- name: default
protocol: layer2
addresses:
- ${interpreter_webhook_example_service_external_ip_address}-${interpreter_webhook_example_service_external_ip_address}
EOF

# deploy interpreter webhook example in karmada-host
Expand Down

0 comments on commit 58e302b

Please sign in to comment.