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

Stack vs example in a devfile repo/registry #279

Closed
elsony opened this issue Dec 14, 2020 · 1 comment
Closed

Stack vs example in a devfile repo/registry #279

elsony opened this issue Dec 14, 2020 · 1 comment
Assignees
Labels
area/registry Devfile registry for stacks and infrastructure

Comments

@elsony
Copy link
Contributor

elsony commented Dec 14, 2020

Background:
The usage of the devfile repo/registry has been focusing on the usage of a runtime stack. A runtime stack is typically a generic stack that contains a devfile to provide support on applications of the same type. It allows tools users like odo to query for the list of odo components to build and run an existing user application. However, there is another set of use case for devfile where someone just wanted to provide samples for others to use to showcase certain technologies. This usage is slightly different from the starterProjects where is meant to provide a starter of a given stack. This proposal is to provide better support for samples where tools/users can query a list of samples and just download and use them as-is.

The current design on the registry structure can be found here: https://github.com/devfile/api/blob/master/docs/proposals/registry/registry-structure.md

The stack contents including the devfiles are stored under the directory registry/stacks (see https://github.com/devfile/registry as an example).

Proposal:
To support samples as a first-class citizen and differentiate between stack vs samples:

  1. add a file called "extraDevfileEntries.yaml" at the root of the registry source directory to add samples from other repositories to the registry (see proposal Configure codeowners and PR template #2 in the design doc below for details).
  2. on index.json, add a type (possible value stack and sample) to each entry to differentiate between stack vs samples
  3. change the index generator tools to generate the type for each entry based on the parent directory (registry/stacks and the sample entries in the extraDevfileEntries.yaml).
  4. common library will provide a filtering mechanism when querying the list of devfiles so that tools can easily find the list of stacks or samples
  5. add validation to the index generator tools to flag a warning if there are devfiles under the samples directory that has starterProjects entries

Design proposal: https://docs.google.com/document/d/1tbzZK9aWtpw5AtoZmUl1Jy8x8w9N5hhjXu3c26VYiYY/edit?usp=sharing
https://docs.google.com/document/d/1tpD0Mc7agEWSUSWc_NPyBBHwdNcwmI2BQBqYRoJxFDU/edit?usp=sharing

@GeekArthur
Copy link
Contributor

All the PRs related to this issue are merged, the issue is done.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/registry Devfile registry for stacks and infrastructure
Projects
None yet
Development

No branches or pull requests

2 participants