How do you migrate between k8s clusters?
# general
o
Recently AWS has released EKS 1.26; we're going to migrate our v1.25 cluster over to it; this 1.25 cluster is currently running our coder instance. We use the built-in terraform provisioner; it provisions a mix of ebs volumes, k8s pods, etc. Very similar to the k8s development template. In a prior upgrade we found that when coder was uninstalled (via helm) from one cluster and installed on another all of our persistent resources were destroyed. This makes sense; presumably something like
terraform destroy -f
was run for each workspace, which deleted the EBS volumes that we use for our
/home
directories. With this new migration being planned, and we now have more folks using coder, we're interested in not losing data (😅). Any pointers would be greatly appreciated.
k
Hey there! Coder won't destroy resources unless workspaces are deleted (or your template is set to delete on stop). Even if you uninstall Coder, no workspace resources will be removed. Are you certain the namespace wasn't deleted?
o
👋🏼 Hard to be certain because the “uninstall” I refer to was a big process that also involved shutting down the cluster / ie deleting the namespaces on the cluster. Are you suggesting that blue green deployment across clusters is a viable plan? It’s not clear to me how to migrate the terraform state from one cluster to another, as an example of one potential solution that would facilitate this.