Is your task related to a problem? Please describe
When using the per-workspace storage strategy, the PVC size can actually be calculated based on the requirements of the CDE's devfile by summing the size of the devfile volumes that are defined. Currently, the rules used in calculating the PVC size are not documented, which may confuse users about this issue.
Describe the solution you'd like
We should document the per-workspace PVC size calculation rules in the Che Docs. The rules are as follows:
If all volumes in a devfile specify their size, the computed PVC size will be used.
If all volumes in a devfile either specify their size or are ephemeral, the computed PVC size will be used.
If at least one volume in a devfile specifies its size, and the computed PVC size is greater than the default per-workspace PVC size, the computed PVC size will be used.
Some notes:
In rule 1. or 2. it's possible for the PVC size to be larger or smaller than the per-workspace PVC storage size that is set in the Che Cluster CRsdevEnvironments.storage.PerWorkspaceStrategyPvcConfig.claimSize.
In rule 3, the computed PVC size will only be used if it is larger than the per-workspace PVC storage size that is set in the Che Cluster CRs devEnvironments.storage.PerWorkspaceStrategyPvcConfig.claimSize. If it's smaller than the per-workspace PVC claimSize defined in the Che Cluster CR, then the PVC size will be set to the Che Cluster's per-workspace PVC claim size.
If the devfile's volumes do not meet any of these rules requirements, then the default per-workspace PVC storage size will be used (i.e. the size defined in the Che Cluster CRs `devEnvironments.storage.PerWorkspaceStrategyPvcConfig.claimSize).
Describe alternatives you've considered
No response
Additional context
Some extra notes:
There is a known bug with this feature that occurs when a devfile does not define any volumes & mountSources is used
Is your task related to a problem? Please describe
When using the per-workspace storage strategy, the PVC size can actually be calculated based on the requirements of the CDE's devfile by summing the size of the devfile volumes that are defined. Currently, the rules used in calculating the PVC size are not documented, which may confuse users about this issue.
Describe the solution you'd like
We should document the per-workspace PVC size calculation rules in the Che Docs. The rules are as follows:
Some notes:
devEnvironments.storage.PerWorkspaceStrategyPvcConfig.claimSize
.devEnvironments.storage.PerWorkspaceStrategyPvcConfig.claimSize
. If it's smaller than the per-workspace PVC claimSize defined in the Che Cluster CR, then the PVC size will be set to the Che Cluster's per-workspace PVC claim size.Describe alternatives you've considered
No response
Additional context
Some extra notes: