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

As an Admin I want to easily update 'Getting Started' / 'Select a Sample' view and point it to repositories we use inside our organization #22429

Closed
ibuziuk opened this issue Aug 9, 2023 · 11 comments
Assignees
Labels
area/dashboard kind/task Internal things, technical debt, and to-do tasks to be performed. severity/P2 Has a minor but important impact to the usage or development of the system.
Milestone

Comments

@ibuziuk
Copy link
Member

ibuziuk commented Aug 9, 2023

Is your task related to a problem? Please describe

Motivation

Currently, it is very hard to add custom samples and update devfile registry - https://github.com/ibuziuk/che-devfile-registry
There is a plan to switch to devfile.io and a dedicated devfile registry operator to decouple samples from Dev Spaces as part of - #20251
Whereas this is an ultimate goal and would allow removing devfile-registry operand from the operator, there could be challenges for customers to use this approach

  • devfile registry operator is community supported
  • setup and configuration of yet another operator could be challenging

Describe the solution you'd like

As an Admin I want to update 'Getting Started' / 'Select a Sample' view and point it to repositories we use inside our organization. Basically, this could boil down to creating the cm with the list of repositories that would be read by the dashboard and displayed accordingly

apiVersion: v1
kind: ConfigMap
metadata:
  name: getting-started
labels:
    app.kubernetes.io/part-of: che.eclipse.org
data:
  getting-started-samples: |-
    [
      {
        "name": "Java Quarkus",
        "description": "Quarkus example with a default REST endpoint application sample",
        "tag": "Community",
        "url": "https://github.com/che-incubator/quarkus-api-example/",
        "icon": {
          "base64data": <base64-encoded-data>,
          "mediatype": "image/png"
        }
      },
      {
        "name": "Eclipse Che Dashboard",
        "description": "Specifies development environment needed to develop the Eclipse Che Dashboard.",
        "tag": "Eclipse Che",
        "url": "https://github.com/che-incubator/quarkus-api-example/",
        "icon": {
          "base64data": <base64-encoded-data>,
          "mediatype": "image/png"
        }
      }
    ]

The pros of this approach:

  • simple and straight-forward configuration via single k8s resource
  • airgap / private repo support OOTB assuming that OAuth / PAT is configured

Describe alternatives you've considered

No response

Additional context

  • description is optional
  • tag is optional
  • icon is optional, if not set on UD we display the default image:

image

@ibuziuk ibuziuk added the kind/task Internal things, technical debt, and to-do tasks to be performed. label Aug 9, 2023
@che-bot che-bot added the status/need-triage An issue that needs to be prioritized by the curator responsible for the triage. See https://github. label Aug 9, 2023
@ibuziuk ibuziuk added status/analyzing An issue has been proposed and it is currently being analyzed for effort and implementation approach area/dashboard labels Aug 9, 2023
@ibuziuk ibuziuk changed the title As an Admin I want to update 'Getting Started' / 'Select a Sample' view and point it to repositories we use inside our organizatoin As an Admin I want to easily update 'Getting Started' / 'Select a Sample' view and point it to repositories we use inside our organizatoin Aug 9, 2023
@ibuziuk ibuziuk changed the title As an Admin I want to easily update 'Getting Started' / 'Select a Sample' view and point it to repositories we use inside our organizatoin As an Admin I want to easily update 'Getting Started' / 'Select a Sample' view and point it to repositories we use inside our organization Aug 10, 2023
@Kasturi1820 Kasturi1820 added severity/P2 Has a minor but important impact to the usage or development of the system. and removed status/analyzing An issue has been proposed and it is currently being analyzed for effort and implementation approach status/need-triage An issue that needs to be prioritized by the curator responsible for the triage. See https://github. labels Aug 11, 2023
@ibuziuk ibuziuk added the status/analyzing An issue has been proposed and it is currently being analyzed for effort and implementation approach label Aug 23, 2023
@tolusha tolusha self-assigned this Aug 30, 2023
@tolusha tolusha moved this to Unplanned Tasks in Eclipse Che Team A Backlog Aug 30, 2023
@tolusha tolusha removed the status/analyzing An issue has been proposed and it is currently being analyzed for effort and implementation approach label Aug 30, 2023
@tolusha
Copy link
Contributor

tolusha commented Aug 30, 2023

Should be the same structure like this?
https://registry.devfile.io/index

@ibuziuk
Copy link
Member Author

ibuziuk commented Aug 30, 2023

we can use a different or similar structure to devfile.io - whatever would be easier to support/maintain. Also, maybe this cm should be managed by the operator

@tolusha
Copy link
Contributor

tolusha commented Aug 31, 2023

Also, maybe this cm should be managed by the operator

What does it mean?

My suggestion:

      {
        "displayName": "Eclipse Che Dashboard",
        "description": "Specifies development environment needed to develop the Eclipse Che Dashboard.",
        "tags": ["Eclipse Che", "Dashboard"],
        "url": "https://github.com/che-incubator/quarkus-api-example/",
        "icon": {
          "base64data": <base64-encoded-data>,
          "mediatype": "image/png"
        }
      }

@ibuziuk
Copy link
Member Author

ibuziuk commented Aug 31, 2023

format lgtm, I do not know if it makes sense to have the cm be managed by the operator e.g. app.kubernetes.io/managed-by: che-operator

@tolusha
Copy link
Contributor

tolusha commented Aug 31, 2023

The ConfigMap must have some distinguish labels.
I suggest:

apiVersion: v1
kind: ConfigMap
metadata:
  name: getting-started
  labels:
    app.kubernetes.io/part-of: che.eclipse.org
    app.kubernetes.io/component: devfile-metadata
data:
  getting-started-samples: |-
    [
      {
        "displayName": "Eclipse Che Dashboard",
        "description": "Specifies development environment needed to develop the Eclipse Che Dashboard.",
        "tags": ["Eclipse Che", "Dashboard"],
        "url": "https://github.com/che-incubator/quarkus-api-example/",
        "icon": {
          "base64data": <base64-encoded-data>,
          "mediatype": "image/png"
        }
      }
    ]

@ibuziuk
Copy link
Member Author

ibuziuk commented Aug 31, 2023

LGTM, the only thing is app.kubernetes.io/component: devfile-metadata, I would rather use app.kubernetes.io/component: getting-started-samples
@l0rd wdyt? could you please review the proposal?

@tolusha
Copy link
Contributor

tolusha commented Sep 1, 2023

Sounds better for me

@l0rd
Copy link
Contributor

l0rd commented Sep 1, 2023

Proposal looks good to me 👍

@ibuziuk
Copy link
Member Author

ibuziuk commented Sep 13, 2023

@tolusha just want to double-check if any backports are needed for 7.74.x ? We really want to have this feature in 3.9 ;-)

@tolusha
Copy link
Contributor

tolusha commented Sep 13, 2023

We have to backport the doc PR eclipse-che/che-docs#2646

@tolusha
Copy link
Contributor

tolusha commented Sep 13, 2023

Here is https://github.com/eclipse-che/che-docs/commits/7.74.x

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/dashboard kind/task Internal things, technical debt, and to-do tasks to be performed. severity/P2 Has a minor but important impact to the usage or development of the system.
Projects
None yet
Development

No branches or pull requests

5 participants