Open yidongw opened 2 years ago
I have the same issue with v0.14.0 although I include the kubeadmConfigPatchesJSON6902 thing
apiVersion: kind.x-k8s.io/v1alpha4
kind: Cluster
networking:
apiServerAddress: "0.0.0.0"
# add to the apiServer certSANs the name of the docker (dind) service in order to be able to reach the cluster through it
kubeadmConfigPatchesJSON6902:
- group: kubeadm.k8s.io
version: v1beta2
kind: ClusterConfiguration
patch: |
- op: add
path: /apiServer/certSANs/-
value: docker
nodes:
- role: control-plane
- role: worker
- role: worker
you're hitting that with v0.14.0 because v1beta2 is no longer the current config version for kubeadm for that kubernetes version in the default image in v0.14.0 of kind, you can just drop the version
field in this case since the field you're patching is stable across versions.
v0.11.1 has been a while, I don't recall what we changed to v0.12.0, but docker
is not an expected hostname for the Kubernetes API cert under normal kind usage.
I don't have / use gitlab myself, but we accept PRs from users to update these.
you're hitting that with v0.14.0 because v1beta2 is no longer the current config version for kubeadm for that kubernetes version in the default image in v0.14.0 of kind, you can just drop the
version
field in this case since the field you're patching is stable across versions.v0.11.1 has been a while, I don't recall what we changed to v0.12.0, but
docker
is not an expected hostname for the Kubernetes API cert under normal kind usage.I don't have / use gitlab myself, but we accept PRs from users to update these.
if docker
is not an expected hostname, what is?
What is the config that I can try in my gitlab?
My solution is:
kubectl config set-cluster kind --insecure-skip-tls-verify=true
if docker is not an expected hostname, what is?
localhost, or the node name.
I was using the https://github.com/kind-ci/examples/blob/master/.gitlab-ci.yml, but with different versions.
still works fine.
Starting from
KIND: v0.12.0
, Gitlab CI will give me the following errorHow can I fix it?