Prevent users from changing controller.devfile.io/storage-type
on an existing workspace to avoid confusing & frustrating data loss
#23035
Labels
area/editor/vscode
Issues related to the Code OSS editor of Che
kind/bug
Outline of a bug - must adhere to the bug report template.
severity/P1
Has a major impact to usage or development of the system.
team/B
This team is responsible for the Web Terminal, the DevWorkspace Operator and the IDEs.
Describe the bug
When I go to start a new workspace from scratch, I often follow a workflow like this:
In general this is a great workflow for getting started working on a new project. However occasionally I would get a behavior that was frustrating/unexpected... after that first "Restart workspace from local devfile", my data would get wiped. No repo in /projects, and any other work I had done that I normally expect to persist would be gone.
Eventually I realized that what was happening was that I had inadvertently copy/pasted a devfile that had this config in it:
And if I was working in a che-cluster that defaults to "per-user", the result of the restart would be that I would get a brand new PVC on restart, and all my work was missing.
I'm not sure if the right solution here would be to prevent that change, or issue a warning, but I could see this being a huge turn-off to new users trying to get started, and I think we should do something about it
Che version
7.81
Steps to reproduce
/projects
. (e.g.touch /projects/testfile
)devfile.yaml
with the following content:ls /projects/testfile
)Expected behavior
I would like to be issued a warning of some kind that the devfile is changing the storage type that will result in data loss, or maybe just prevent the change from happening alltogether
Runtime
OpenShift
Screenshots
No response
Installation method
OperatorHub
Environment
Linux
Eclipse Che Logs
No response
Additional context
No response
The text was updated successfully, but these errors were encountered: