kind: using kind with gitlab kuberenetes executor fails

I try to create a kind cluster for integration test in a gitlab-ci job. Cluster creation fails:

Creating cluster "kind" ...
 â€ĸ Ensuring node image (kindest/node:v1.13.3) đŸ–ŧ  ...
 ✓ Ensuring node image (kindest/node:v1.13.3) đŸ–ŧ
 â€ĸ Preparing nodes đŸ“Ļ  ...
 ✓ Preparing nodes đŸ“Ļ
 â€ĸ Creating kubeadm config 📜  ...
 ✓ Creating kubeadm config 📜
 â€ĸ Starting control-plane đŸ•šī¸  ...
 ✗ Starting control-plane đŸ•šī¸
Error: failed to create cluster: failed to init node with kubeadm: exit status 1
cluster creation failed

In the dumped logs there are two entries that may give a clue on the reason.

In docker.log:

Mar 13 13:44:35 kind-control-plane dockerd[74]: time="2019-03-13T13:44:35.790818335Z" level=warning msg="Could not register builder git source: failed to find git binary: exec: \"git\": executable file not found in $PATH"

In kubelet.log:

Mar 13 13:44:45 kind-control-plane kubelet[464]: F0313 13:44:45.457729     464 server.go:189] failed to load Kubelet config file /var/lib/kubelet/config.yaml, error failed to read kubelet config file "/var/lib/kubelet/config.yaml", error: open /var/lib/kubelet/config.yaml: no such file or directory

About this issue

  • Original URL
  • State: closed
  • Created 5 years ago
  • Comments: 24 (10 by maintainers)

Most upvoted comments

If you are using the Kubernetes runner then you must address docker at localhost, i.e. tcp://localhost:2375.

Additionally, I think that you do not have to set the DOCKER_DRIVER environment variable because it does not influence your docker:dind service.