Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update kind to 0.15 to support deploy k8s 1.25 environment #2551

Merged
merged 1 commit into from
Sep 22, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
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:
Copy link
Member Author

@jwcesign jwcesign Sep 20, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This feature is enabeled to be true by default after 1.19, so it's ok, ref to: https://v1-23.docs.kubernetes.io/docs/reference/command-line-tools-reference/feature-gates/

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

good!

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That means we don't need this flag, right? Since our E2E are started to v1.21.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, we don't need it, it's enabled by default

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
4 changes: 2 additions & 2 deletions hack/deploy-karmada.sh
Original file line number Diff line number Diff line change
Expand Up @@ -125,10 +125,10 @@ function installCRDs() {
kubectl --context="${context_name}" apply -k "${crd_path}"/_crds
}

# Use x.x.x.6 IP address, which is the same CIDR with the node address of the Kind cluster,
# Use x.x.x.8 IP address, which is the same CIDR with the node address of the Kind cluster,
# as the loadBalancer service address of component karmada-interpreter-webhook-example.
interpreter_webhook_example_service_external_ip_prefix=$(echo $(util::get_apiserver_ip_from_kubeconfig "${HOST_CLUSTER_NAME}") | awk -F. '{printf "%s.%s.%s",$1,$2,$3}')
interpreter_webhook_example_service_external_ip_address=${interpreter_webhook_example_service_external_ip_prefix}.6
interpreter_webhook_example_service_external_ip_address=${interpreter_webhook_example_service_external_ip_prefix}.8

# generate cert
util::cmd_must_exist "openssl"
Expand Down
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
29 changes: 15 additions & 14 deletions hack/pre-run-e2e.sh
Original file line number Diff line number Diff line change
Expand Up @@ -34,29 +34,30 @@ 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,
# Use x.x.x.8 IP address, which is the same CIDR with the node address of the Kind cluster,
# as the loadBalancer service address of component karmada-interpreter-webhook-example.
interpreter_webhook_example_service_external_ip_prefix=$(echo $(util::get_apiserver_ip_from_kubeconfig "${HOST_CLUSTER_NAME}") | awk -F. '{printf "%s.%s.%s",$1,$2,$3}')
interpreter_webhook_example_service_external_ip_address=${interpreter_webhook_example_service_external_ip_prefix}.6
interpreter_webhook_example_service_external_ip_address=${interpreter_webhook_example_service_external_ip_prefix}.8

# 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