PVC Creating forever...
I'm trying to deploy Coder.OSS on K8S... during the workspace provisioning, TF reports volume.claim creating until time exceeded.
On K8S, the PVC shows as pending.
Any clue?
32 Replies
Seems like your configuration doesn't have anything mounting the PVC...
I see you have a pod there. Is it using the PVC?
Could you describe the storage class that is being used by the PV?
Storage class is the K3S Local-path...
Indeed, I have two pods within the same namespace (coder), but they are coderd and coder-db... no workspace related pod though.
it seems that pvc is waiting for a pod to bind it but no pod is being started.
Same.
What templates are you running into this with?
kubernetes @f0ssel
What template specifically ?
I dont understand. Looks like already answered:
oh, sorry, I thought there was multiple kubernetes templates
Nope, just trying from scratch in k3s cluster in hetzner single master.
Postgres claim bound succesfully.
But workspace always fail.
First problem was that default workspace in tf was not connected correctly. For some reason coder-workspaces does not work, fixed it in tf template (role succefully created, extended to * resources, and binded)
After that claim was created without storage class.
Fixed like this:
But still claim stuck:
Looks like local-path-provisioner waits pod as first consumer like in this example:
https://github.com/rancher/local-path-provisioner
But logic of workspace creation is different. It waits pvc claim bound and after that creating pod.
Does it work if you disable
wait_until_bound
? https://registry.terraform.io/providers/hashicorp/kubernetes/latest/docs/resources/persistent_volume_claim#wait_until_bound@Ben creation of workspace we passed with
wait_until_boun
flag. Right now code-server unhealthy.Oh that's odd. What are the logs inside the workspace of
/tmp/coder-startup-script.log
?
I imagine the Terminal and SSH works to connect?I imagine the Terminal and SSH works to connect?Terminal works fine. Looks like /home/coder was initialized with
root:root
permission only.
After sudo chown -R 1000:1000 /home/coder
vscode server started.Ah nice. I'm surprised that happened in the first place but running that in the startup script should do the trick.
Yep, right now last small improvement with wildcard certificate and we have done. Dont have questions. Thanks a lot! @Ben
Nice! So the wildcard is working too?
I did not start implementing it! 🙂 On this week will try.
Ahh got it!