REST API to create workspaces from a devfile
See original GitHub issueDescription
Currently there is a way to create a workspace from a devfile https://github.com/eclipse/che/blob/master/wsmaster/che-core-api-devfile/src/main/java/org/eclipse/che/api/devfile/server/DevfileService.java#L98-L116
We can post a devfile content.
I would like to be able to create workspaces from content like this one: https://github.com/redhat-developer/devfile/blob/master/Devfile.yaml
Let say I’m a client like the dashboard where I could create content of such devfile, then this devfile is referencing other files by doing something like: local: petclinic.yaml
How could I submit such files through REST API ?
would it be something like MULTIPART_FORM_DATA / https://github.com/codenvy-legacy/che-core/blob/3.x/platform-api/che-core-api-factory/src/main/java/org/eclipse/che/api/factory/FactoryService.java#L166
or to submit content with a all-in-one
format
---BEGIN DEVFILE---
content
---END DEVFILE---
---BEGIN petclinic.yaml---
content
---END petclinic.yaml---
something else ?
somehow related to https://github.com/eclipse/che/issues/11549
Issue Analytics
- State:
- Created 5 years ago
- Comments:14 (10 by maintainers)
Top GitHub Comments
I’m OK with
This would be reflected in the JSON Schema of devfile. Let’s consult with authors of the JSON Schema @l0rd @mshaposhnik @sleshchenko @skabashnyuk WDYT guys about the changes suggested by Florent? If you are OK with them I’ll work on it