When calculating the per-workspace PVC size, container components in a devworkspace are now treated as if they were volume components with no size specified.
This change was made to address an edge case in the per-workspace PVC size calculation where a devworkspace that has no volume components, but has a container component with mountSources enabled will request a PVC size of 0.
When mountSources is used, the devworkspace requires storage to store the project sources. However, it's ambiguous as to how much storage is required for the project sources. Thus, the best we can do is to treat container components with mountSources enabled as if they were volume components with an unspecified size.
I also documented the original 3 rules that were followed when calculating the per-workspace PVC size (mentioned in this PR) and added a 4th rule regarding the mountSources edge case.
Needs approval from an approver in each of these files:
- ~~[OWNERS](https://github.com/devfile/devworkspace-operator/blob/main/OWNERS)~~ [AObuchow]
Approvers can indicate their approval by writing `/approve` in a comment
Approvers can cancel approval by writing `/approve cancel` in a comment
What does this PR do?
When calculating the per-workspace PVC size, container components in a devworkspace are now treated as if they were volume components with no size specified.
This change was made to address an edge case in the per-workspace PVC size calculation where a devworkspace that has no volume components, but has a container component with
mountSources
enabled will request a PVC size of 0.When
mountSources
is used, the devworkspace requires storage to store the project sources. However, it's ambiguous as to how much storage is required for the project sources. Thus, the best we can do is to treat container components withmountSources
enabled as if they were volume components with an unspecified size.I also documented the original 3 rules that were followed when calculating the per-workspace PVC size (mentioned in this PR) and added a 4th rule regarding the mountSources edge case.
What issues does this PR fix or reference?
Fix https://github.com/devfile/devworkspace-operator/issues/1239
Is it tested? How?
PR Checklist
/test v8-devworkspace-operator-e2e, v8-che-happy-path
to trigger)v8-devworkspace-operator-e2e
: DevWorkspace e2e testv8-che-happy-path
: Happy path for verification integration with Che