0

Is this possible?

I want to create an image to run a kubernetes worker inside a docker container.

I tryed using dind images but it didn't work... Any ideas?

David Maze
  • 130,717
  • 29
  • 175
  • 215
Caio Borghi
  • 76
  • 4
  • 10
  • 1
    Kubernetes is a multi-host distributed cluster environment. Do you just need the `kubectl` client? Or are you looking for a single-host Kubernetes setup like [kind](https://kind.sigs.k8s.io) that happens to run inside a container? – David Maze Mar 28 '21 at 17:06
  • Actually, I'm looking for a way to create an image with kubernetes on it, to make it easier to setup my kubernetes workers – Caio Borghi Mar 29 '21 at 13:09

1 Answers1

4

There are several options, for example the official kind (kubernetes in docker) project: https://kind.sigs.k8s.io/

Depending on your use case, k3s might be a good fit as well: https://k3s.io/ here is an example with docker-compose: https://www.trion.de/news/2019/08/28/kubernetes-in-docker-mit-k3s.html

Thomas
  • 11,272
  • 2
  • 24
  • 40
  • I'd agree with the recommendation for kind, it works really well and can be configured for different types of operation. – Rory McCune Mar 29 '21 at 10:25
  • Actually, I'm looking for a way to create a docker image with kubernetes configured on it, to make it easier to setup my kubernetes workers(clients) but I'm having problems when I try to do this with ubuntu images or dind images, do you know something that can help me? – Caio Borghi Mar 29 '21 at 13:10