You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If a devworkspace uses the ephemeral storage strategy, and the DWOC's field workspace.persistUserHome: true is set, then the devworkspace's deployment spec will be invalid because it will contain a volume named persistentHome, which is an invalid volume name in kubernetes (see #1200). Even if the persistent home volume name was valid, the persistent home volume should not be injected into the devworkspace: an ephemeral storage workspace cannot have it's home directory persisted.
Check the workspace status (i.e. kubectl get dw -n $NAMESPACE) and see that the workspace has failed:
NAME DEVWORKSPACE ID PHASE INFO
plain-devworkspace-ephemeral workspace79f813e0f75a42f4 Failed Error creating DevWorkspace deployment: Deployment.apps "workspace79f813e0f75a42f4" is invalid: [spec.template.spec.volumes[0].name: Invalid value: "persistentHome": a lowercase RFC 1123 label must consist of lower case alphanumeric characters or '-', and must start and end
with an alphanumeric character (e.g. 'my-name', or '123-abc', regex used for validation is '[a-z0-9]([-a-z0-9]*[a-z0-9])?'), spec.template.spec.containers[0].volumeMounts[0].name: Not found: "persistentHome"]
Expected behavior
The workspace deployment succeeds and no persistent home volume is added to the workspace deployment's volumes or volumeMounts.
Description
If a devworkspace uses the ephemeral storage strategy, and the DWOC's field
workspace.persistUserHome: true
is set, then the devworkspace's deployment spec will be invalid because it will contain a volume namedpersistentHome
, which is an invalid volume name in kubernetes (see #1200). Even if the persistent home volume name was valid, the persistent home volume should not be injected into the devworkspace: an ephemeral storage workspace cannot have it's home directory persisted.When we check if home persistence is enabled, we should also ensure persist storage is being used as well.
How To Reproduce
workspace.persistUserHome: true
in the DWOCkubectl get dw -n $NAMESPACE
) and see that the workspace has failed:Expected behavior
The workspace deployment succeeds and no persistent home volume is added to the workspace deployment's volumes or volumeMounts.
Additional context
Related upstream issue
The text was updated successfully, but these errors were encountered: