-
Task
-
Resolution: Done
-
Major
-
2.14.0.GA
-
False
-
False
-
-
Synced from Eclipse Che issue
https://github.com/eclipse/che/issues/20644
Is your task related to a problem? Please describe
That's important because Che and CRW don't get devfile v2 support(devworkspace mode) by default, but OpenShift Console already use them for default samples and it breaks integration.
<img width="1269" alt="image" src="https://user-images.githubusercontent.com/606959/136627809-e276f80f-31a7-42be-93b2-e503581343ad.png">
Describe the solution you'd like
Che should supply devfile v2 in Che Server mode (by converting it to devfile v1).
It includes the following subtasks:
- @skabashnyuk https://github.com/eclipse/che/issues/20650
- @akurinnoy Che Dashboard should convert devfile v2 to devfile v1 with help of the library:
Code: https://github.com/eclipse-che/che-theia/blob/main/extensions/eclipse-che-theia-remote-impl-che-server/src/node/che-server-devfile-service-impl.ts#L591-L650
Tests: https://github.com/eclipse-che/che-theia/blob/main/extensions/eclipse-che-theia-remote-impl-che-server/tests/node/che-server-devfile-service-impl.spec.ts
:notebook: dashboard won't validate generated devfile v1 (from devfile v2) against devfile v1 schema, and if there is any bug in conversion logic, the user will get an unclear message that some component is not a valid or field is missing, but in a fact there is nothing user can do with that.
Release Notes Text
Che now supports creating workspaces from a Devfile that uses v2 of the spec even if the workspace engine is the che-server (the current default). Previously that was possible only if Che was configured with the DevWorkspace operator as workspace engine.