Hi Andrew, great tutorial, well explained and straightforward. But I've a doubt, I have already 4 Raspberry Pis running with many containers running on each of them. It is possible to "convert" this environment into a Kubernetes cluster or I have to reinstall everything from the begining and start from scratch?. Im new commer in this, and It took me a lot of time and efforts to set this up... Thanks a lot!!!
Hi Antonio, thank you for the kind words. You can combine your 4 pis into the one cluster and host all of your containers there. But you need to rewrite your Docker / Docker compose instructions into Kubernetes deployment manifests.
In your cluster you will have only 1 master and 3 worker nodes. All containers that you are running now will be run on these worker nodes. To run your containers now you are using Docker compose or just Docker commands. It's not possible to use it with Kubernetes. You need to rewrite your Docker commands / compose files to Kubernetes deployment manifests that are written in YAML.
@@anmalkov Ok, now I understand perfectly! thank you very much. So I think that I'll try Kubernetes in my next life... Thinking of start everthing from the begining really scares me.
Hello Andrew, it is a very good tutorial. I have installed the kubernetes as you recommended on running raspi-system and it is running without problems The only thing is that yaml is new for me. My question is can you publish the yaml source on your youtube-channel?
@@tsob99 You can find your own config yaml file at /etc/rancher/k3s/k3s.yaml. You can't use an another one. It's used to configure your laptop after install kubectl.
Hi Andrew Malkov Thanks for bringing such a wonderful organized tutorial. I am new comer in kubernetees world, to understand I tried multiple contents to build my cluster but this one is done in very simple way and thanks for the same. One part related to joining the connections in yml file (around 27.5) i think we need kubernetees to be installed on laptop (Where I am establishing the ssh towards my pi cluster). Reason is I do not see any .kube folder in my home directory.
hey im a noob, im going to follow this tutorial. i only have 2 rpi but does the master node only work as a master node? or does it see itself as a worker too? i ask because if i only have 2 pis for the cluster will one node be doing all the work? or should i wait until i have alot of nodes. since im not too sure i welcome any help
The master can also host the workloads. However it's not recommended. But, who cares about recommendations if it's your own home cluster ;) I would suggest to not wait and use what you have, if it won't work for you - just add another one pi
Have you happened to get the Kubernetes Dashboard working and accessible from outside the Raspberry Pi? I am having a horrible time getting it to be accessible.
check netplan , cd /etc/netplan, 50-cloud-init.yaml config.yaml creat your own config.yaml for static ip address configaration. (Netplan apply /config.yaml) :)
@@anmalkov Hello, for some odd reason when I try to set a static IP address to mi Pi's it doesn't work (while every tutorial shows its very simple). I skipped ahead and clustered them any way and both nodes show "ready", however I am still worried because I never set a static IP. Sorry for the long comment.
Useful video. Followed your instructions line by line. ubuntu@master:~$ sudo kubectl get nodes E0506 15:30:16.957925 28052 memcache.go:265] couldn't get current server API group list: the server is currently unable to handle the request E0506 15:30:16.983338 28052 memcache.go:265] couldn't get current server API group list: the server is currently unable to handle the request E0506 15:30:17.001146 28052 memcache.go:265] couldn't get current server API group list: the server is currently unable to handle the request Error from server (ServiceUnavailable): the server is currently unable to handle the request (get nodes)
I got the same thing. I discovered my /etc/hosts file was reset to a clean state. After researching this I found that the /etc/cloud/templates/hosts.debian.tmpl had to be updated with the additional worker node addresses: sudo nano /etc/cloud/templates/hosts.debian.tmpl #add everything you want to appear in /etc/hosts - save and reboot master. Then my master appeared when I ran sudo kubectl get nodes I am running Ubuntu server 22.04