wenzel-felix / terraform-hcloud-rke2

This module deploys a resilient and highly available rke2 Kubernetes cluster on Hetzner Cloud.
https://registry.terraform.io/modules/wenzel-felix/rke2/hcloud/latest
MIT License
12 stars 6 forks source link

Allows grouping hcloud resources by clustername #40

Closed mpepping closed 10 months ago

mpepping commented 10 months ago

Allows setting a =< 20 character clustername to easily identify hcloud resources when deploying multiple clusters. By default the current rke2 prefix is used for servers and load-balancers. This allows setting a different prefix.

mpepping commented 10 months ago

Thanks for this Terraform module, @wenzel-felix! Makes it real easy to deploy RKE2 clusters on Hetzner. For now, I'll leave it at these three PR's (LB location, CNI support and cluster name) .. and we already have a couple of clusters running using your module :)

wenzel-felix commented 10 months ago

@mpepping glad to hear. I have some open tasks that I wanted to tackle, regarding node management and also the networking (which is currently not configurable at all).

On this topic of networking, what do you think about adding this prefix also to the network as this is coupled to the cluster atm. (my idea would be to also allow existing Networks in the future)

mpepping commented 10 months ago

@wenzel-felix sounds like a good idea. By default a hcloud_network object specific for the clusters sounds wise in terms of isolation. The ability to allow use of an existing hcloud_network (via a data resource or so) to place (a multitude of) cluster(s) is also viable. I'll add the prefix to the network is this PR, and check addressing.

In terms of networking, adding hcloud_firewall objects for nodes is maybe also something to consider.

wenzel-felix commented 10 months ago

Yes, I already had the FW rules, but I "deactivated" it for now. Maybe, tmr I have some time to check on these two topics.

wenzel-felix commented 10 months ago

@mpepping, out of curiosity, are you using any of the optional "preinstalled" charts?

mpepping commented 10 months ago

Nice, @wenzel-felix! In regards to the preinstalled charts; planning to use hcloud-cloud-controller-manager. Are you planning to change something around the chart installations?

wenzel-felix commented 10 months ago

Ok, I am still not sure if the module should only include core functionality - talking about removing the Cloudflare DNS config (or moving it to external DNS at least) and some of the Helm/Kubernetes deployments