Hacker News new | ask | show | jobs
by nunez 481 days ago
I agree with you (this is something that OpenTofu is trying to fix), but the way I do k8s provisioning in Terraform is to have one module that brings up a cluster, another to print the cluster's Kubeconfig, then, finally, another to use the Kubeconfig to provision Kubernetes resources. It's not perfect but it gets the job done most of the time.
1 comments

this is best practice. I couldnt imagine doing it any other way and would flatly refuse.

There are shortcomings in the kubernetes provider as well that make wanting to maintain that in one state file a nonstarter for me.