-
Notifications
You must be signed in to change notification settings - Fork 76
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
Support ipv6 in e2e test #621
Changes from 2 commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -28,9 +28,14 @@ function setup_kind_cluster() { | |
fi | ||
|
||
# Create KinD cluster. | ||
cat <<EOF | kind create cluster --name="${NAME}" -v4 --retain --image "${IMAGE}" --config=- | ||
|
||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. You should also add a line here for ipv6 e2e call: https://github.com/kmesh-net/kmesh/blob/main/Makefile#L149 |
||
if [[ -n "${IPV6:-}" ]]; then | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This |
||
# Create IPv6 KinD cluster | ||
cat <<EOF | kind create cluster --name="${NAME}" -v4 --retain --image "${IMAGE}" --config=- | ||
kind: Cluster | ||
apiVersion: kind.x-k8s.io/v1alpha4 | ||
networking: | ||
ipFamily: ipv6 | ||
nodes: | ||
- role: control-plane | ||
- role: worker | ||
|
@@ -39,6 +44,20 @@ containerdConfigPatches: | |
[plugins."io.containerd.grpc.v1.cri".registry] | ||
config_path = "/etc/containerd/certs.d" | ||
EOF | ||
else | ||
# Create default IPv4 KinD cluster | ||
cat <<EOF | kind create cluster --name="${NAME}" -v4 --retain --image "${IMAGE}" --config=- | ||
kind: Cluster | ||
apiVersion: kind.x-k8s.io/v1alpha4 | ||
nodes: | ||
- role: control-plane | ||
- role: worker | ||
containerdConfigPatches: | ||
- |- | ||
[plugins."io.containerd.grpc.v1.cri".registry] | ||
config_path = "/etc/containerd/certs.d" | ||
EOF | ||
fi | ||
|
||
status=$? | ||
if [ $status -ne 0 ]; then | ||
|
@@ -185,6 +204,10 @@ while (( "$#" )); do | |
SKIP_BUILD=true | ||
shift | ||
;; | ||
--ipv6) | ||
IPV6=true | ||
shift | ||
;; | ||
esac | ||
done | ||
|
||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Make ipv6 an env, if we want to run e2e test for ipv6 run: