Scaleway, a french hosting company (member of Illiad’s group), has recently launched it’s new product Kosmos, based on their already sucesful Kapsule control-plane. more infos here https://blog.scaleway.com/k8s-multi-cloud/
For now Kosmos is available in the following Scaleway regions:
- Paris
- Amsterdam
- Varsovie
(for the control plane) and you can of course deploy your node pools on any Scaleway region or even another cloud provider !
A few articles has been around since Scaleway announced it but i wanted to cover it deeply with some specific usages in mind.
Do it yourself ! 🧩
This article is following the experiments made on this labs repo: https://github.com/webofmars/labs-kosmos you can check all the source code and results there.
Planning infrastructure
For this experiment i wanted to have at least 3 differents cloud-providers since more and more multi-cloud use cases start emerge recently and i have some experience on them. I also wanted to choose 3 clouders in Europe that does not include Scaleway (too easy i guess).
So i ended up creating 9 instances as follows:
- 3 x CX31 in Hetzner (helsinki DC): 2 vCPUs / 8Gb Ram
- 3 x D2-8 in OVH (GRA5 DC): 4 vCPUs / 8Gb Ram
- 3 x 2gb in DigitalOcean (AMS3 DC): 2vCPUs / 2Gb Ram*
* actualy this was an error at the creation time but i didn’t changed it later since this does not seems to affect any results
Let’s setup our multi-cloud cluster
It’s time to create our cluster. Go to your Scaleway console and kubernetes universe, and create a new cluster. Choose Kubernetes Kosmos cluster type.
Enter cluster name / description and optional tags. Check projected costs for your kosmos HA control-plane (does not include any nodes).
Once your cluster is ready you can start to add node pools to it. Click on Node Pools and new node pool. Choose Multi-Cloud type enter pool name (choose carefuly since it will be the basename for your nodes, shorter is better). Eventually add tags if you feel so (only used by scaleway console and cli ignored by k8s).
Once node pool is created in console you can go into “more infos” section of node pool to get the following screen that will show you how to integrate your nodes into Kosmos control-plane.
NOTE: The given command is not yet well documented. There is more options and you can also add `-a xxxx` argument that will be used as a single value to reflect your k8s region (topology.kubernetes.io/region). Refer to the linked github repo for easier setup.
Unleash the nodes !
I used an simple homemade script on each node to setup the instance based on content of some env vars to compute the differences between CPs: https://raw.githubusercontent.com/webofmars/labs-kosmos/main/setup/add-node.sh
Once applied on my 9 instances and by waiting a bit i finally get a fully functional multi-cloud cluster ! Easy !
We are now ready to deploy some apps to our MC cluster in part #2 of this article !