Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

starterProjects and projects description #42

Closed
neeraj-laad opened this issue Apr 28, 2020 · 3 comments · Fixed by #92
Closed

starterProjects and projects description #42

neeraj-laad opened this issue Apr 28, 2020 · 3 comments · Fixed by #92
Labels
area/api Enhancement or issue related to the api/devfile specification
Milestone

Comments

@neeraj-laad
Copy link

neeraj-laad commented Apr 28, 2020

In a devfile that is being used to define a stack, there could be multiple starter projects, each providing a separate starter application (simple app, app integrated with Kafka, reactive app etc.)

Today we only have a name field to distinguish between them. But for developer to make a choice between these starter applications, having more details information on the capabilities you get with each project will be necessary.

If we can add starterProjects section, devfile creators will be able to use it for starter projects (only one should be selected by the user).

starterProjects:
  - name: "kafka-project"
    description: "Use this app to get a nodejs application for working with kafka"
  - name: "simple-project"
    description: "Use this app to get a simple "hello world" nodejs application"

starterProjects would have the same syntax as projects but a slightly different behavior: instead of cloning the git repo, only the source code would be fetched, the git metadata would not.

Moreover we would like to add the description field to both project and starterProject to help developers understand the content of the project.

@l0rd
Copy link
Contributor

l0rd commented May 6, 2020

Alternative 1: using 2 devfiles that reference the same parent devfile:

projects:
  - name: "kafka-project"
    description: "Use this app to get a nodejs application for working with kafka"
parent:
  - id: nodejs-stack
projects:
  - name: "simple-project"
    description: "Use this app to get a simple "hello world" nodejs application"
parent:
  - id: nodejs-stack

Alternative 2: using starterProjectOnly field only:

projects:
  - name: "kafka-project"
    description: "Use this app to get a nodejs application for working with kafka"
    starterProjectOnly: true
  - name: "simple-project"
    description: "Use this app to get a simple "hello world" nodejs application"

Alternative 3: using starterProjects instead of projects for optional stack projects:

starterProjects:
  - name: "kafka-project"
    description: "Use this app to get a nodejs application for working with kafka"
  - name: "simple-project"
    description: "Use this app to get a simple "hello world" nodejs application"

@l0rd
Copy link
Contributor

l0rd commented May 12, 2020

Discussed and agreed on alternative 3 because it's more straightforward for stack authors: projects will all be cloned, starterProject are supposed to be used in interactive mode only (user pick one) and the git repo get not be cloned but only source code get copied (kind of what git archive --remote=<repository URL> | tar -t would do).

@l0rd l0rd changed the title Additional information about starter projects starterProjects and projects description May 12, 2020
@l0rd
Copy link
Contributor

l0rd commented May 12, 2020

@neeraj-laad I have updated the description to reflect our discussions

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/api Enhancement or issue related to the api/devfile specification
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants