rancher / elemental

Elemental is an immutable Linux distribution built to run Rancher and its corresponding Kubernetes distributions RKE2 and k3s. It is built using the Elemental-toolkit
https://elemental.docs.rancher.com/
Apache License 2.0
293 stars 39 forks source link

Seed installation - first Elemental, then Rancher #911

Open kkaempf opened 1 year ago

kkaempf commented 1 year ago

Currently Elemental can only be used to provision machines for downstream clusters. Installation depends on an existing (Rancher) management cluster where elemental-operator is running.

This issue asks for a "seed installation" concept. Where we start with a (bare metal) machine (resp. VM / cloud image), install Elemental and then Rancher on top.

Bonus points if we find a way to install elemental-operator on this Rancher instance and self-manage the machine.

kwiesmueller commented 8 months ago

Is there any way external contributors could help with this? I'm looking to update/replace my k3os setup (single CP node with occasional "edge" worker nodes). The simple yet effective setup of k3os is crucial for me, but as it links to elemental now I can't see how I would get the same.

If you could provide some pointers I'd be happy to look into this and experiment to see how I could get a single-node bootstrap with elemental working.

kkaempf commented 8 months ago

Is there any way external contributors could help with this?

Oh, absolutely ! Thanks for offering help.

If you could provide some pointers I'd be happy to look into this and experiment to see how I could get a single-node bootstrap with elemental working.

You could start with this Dockerfile and try to add k3s to it. The linked Dockerfile is (open)SUSE-specific, see here for a Fedora one (incomplete 😞 ) to get the idea.

@frelon is working on "raw image" support, which might be helpful for quick turnarounds in testing this. 🤞🏻

kwiesmueller commented 7 months ago

Will give it a try. As I'm not familiar with the repo/build process, can you give some pointers on how to then build and test the image?

frelon commented 7 months ago

@kwiesmueller Awesome! I usually iterate using one of the examples from elemental-toolkit when building a new derivative and then adapt it to OBS when it's time for packaging.

The process is pretty much docker build ..., elemental build-disk ... and then run with qemu/virt-manager.

The makefile in the toolkit has all the needed args, but don't hesitate to reach out if you run into any issues!

jswolvaardt commented 2 months ago

Just want to check what the status of this is? Came across this item while looking for instructions to do just this.

We are changing our tech stack in the company, we run about 60 Kubernetes nodes running either in RHEL vm's with RKE on our HCI stack, or the hypervisor's own flavour of Kubernetes engine, but due to issues with both approaches, we need to look at something new, on-prem. Since we are comfortable and happy with the RKE and Rancher components - the only part we are happy with - we are considering ElementalOS with the RKE stack. In preparation for this, I wanted to test Elemental out with K3s, on my home lab.

Preamble done.

I'm also willing to help, though I tried to take a look at the mentioned Dockerfile, to be met with a 404. I used to be developer, but it has been about 3 years since I touched code, DevOps and Kubernetes is just too much fun. So I'm not averse to building a few things on my side, but don't let me touch code, unless you want to summon Cthulu.

I have only 2 old server spec machines in my home lab, and a few edge devices, but I'm willing to reload the servers multiple times. My thoughts are leaning towards 2 single node K3s clusters for my test - one running Rancher the other running the app cluster.