Skip to content

Commit

Permalink
Restructure the manifest files
Browse files Browse the repository at this point in the history
  • Loading branch information
andrewballantyne committed Jun 19, 2024
1 parent 48a6201 commit 2002af4
Show file tree
Hide file tree
Showing 109 changed files with 79 additions and 159 deletions.
2 changes: 1 addition & 1 deletion docs/architecture.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
[Dashboard Deployment `containers`]: ../manifests/base/deployment.yaml
[Dashboard Deployment `containers`]: ../manifests/common/base/deployment.yaml
[OpenShift OAuth Proxy repo]: https://github.com/openshift/oauth-proxy
[OpenShift SDK]: https://github.com/openshift/dynamic-plugin-sdk
[SDK tidbits]: SDK.md
Expand Down
2 changes: 1 addition & 1 deletion docs/dev-setup.md
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ This is the default context for running a local UI. Make sure you build the pro

> Note: You must be logged-in with `oc` before you can start the backend. Details for that are in the the [contribution guidelines](../CONTRIBUTING.md#give-your-dev-env-access).

> Note: The CLI logged-in user will need to be a `cluster-admin` level user on the cluster to mimic the Dashboard Service Account level of permissions. You could also bind the [cluster role](../manifests/base/cluster-role.yaml) to your user as we do with the service account [binding](../manifests/base/cluster-role-binding.yaml).
> Note: The CLI logged-in user will need to be a `cluster-admin` level user on the cluster to mimic the Dashboard Service Account level of permissions. You could also bind the [cluster role](../manifests/common/base/cluster-role.yaml) to your user as we do with the service account [binding](../manifests/common/base/cluster-role-binding.yaml).

```bash
npm run start
Expand Down
2 changes: 1 addition & 1 deletion docs/release-steps.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
[base/kustomization.yaml]: ../manifests/base/kustomization.yaml
[base/kustomization.yaml]: ../manifests/common/base/kustomization.yaml
[quay repo]: https://quay.io/repository/opendatahub/odh-dashboard?tab=tags
[drafting a new release]: https://github.com/opendatahub-io/odh-dashboard/releases/new
[semver]: https://semver.org/
Expand Down
36 changes: 15 additions & 21 deletions manifests/README.md
Original file line number Diff line number Diff line change
@@ -1,32 +1,26 @@
# Dashboard
# Manifests

The Open Data Hub Dashboard component installs a UI which
The Dashboard manifests run on Kustomize. There are 3 types of deployments for the Dashboard component.

- Shows what's installed
- Show's what's available for installation
- Links to component UIs
- Links to component documentation
- Open Data Hub (`./odh`)
- Red Hat OpenShift AI
- RHOAI Managed (`./rhoai/addon`)
- RHOAI Self Managed (`./rhoai/onprem`)

For more information, visit the project [GitHub repo](https://github.com/opendatahub-io/odh-dashboard).
## Adding new Manifests

### Folders
1. base: contains all the necessary yaml files to install the dashboard
Starting at the deployment type folders (see above) there will be a `kustomization.yaml` file -- consider this an "index file". Each reference in these "index files" reference other "index files" in other folders until they reach a folder that contains specific manifest yamls. Maintain this structure for cleanness.

The operator will start from one of the deployment type folders, so we are in control of all the references from there. Keep sane references & be sure to read the README files in each of the root folders for guidelines.

## Installation

##### Installation
Use the `kustomize` tool to process the manifest for the `oc apply` command.

```
# Parse the base manifest to deploy ODH Dashboard WITHOUT the required configs for groups
cd manifests/base
kustomize edit set namespace <DESTINATION NAMESPACE> # Set the namespace in the manifest where you want to deploy the dashboard
kustomize build . | oc apply -f -
```

```
# Deploy ODH Dashboard with authentication AND the default configs for groups and ODHDashboardConfig
cd manifests/overlays/odhdashboardconfig
kustomize edit set namespace <DESTINATION NAMESPACE> # Set the namespace in the manifest where you want to deploy the dashboard
cd manifests/common/base
# Set the namespace in the manifest where you want to deploy the dashboard
kustomize edit set namespace <DESTINATION NAMESPACE>
kustomize build . | oc apply -f -
# You will need to re-run the previous step if you receive the error below
# error: unable to recognize "STDIN": no matches for kind "OdhDashboardConfig" in version "opendatahub.io/v1alpha"
```
5 changes: 5 additions & 0 deletions manifests/common/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
# Common Manifests

These are manifests that are shared in both ODH & RHOAI deployments.

See `../odh` & `../rhoai` if there are specific deployment manifests needed.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
10 changes: 10 additions & 0 deletions manifests/common/kustomization.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization
commonLabels:
app: odh-dashboard
app.kubernetes.io/part-of: odh-dashboard
resources:
- ./apps
- ./base
- ./consolelink
- ./crd
5 changes: 5 additions & 0 deletions manifests/odh/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
# ODH Manifests

These are manifests that are only for ODH.

RHOAI manifests should not reference these. If they need to reference something in here, they should be put into common folder instead.
7 changes: 7 additions & 0 deletions manifests/odh/kustomization.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization
commonLabels:
app: odh-dashboard
app.kubernetes.io/part-of: odh-dashboard
resources:
- ../common
6 changes: 0 additions & 6 deletions manifests/overlays/dev/kustomization.yaml

This file was deleted.

3 changes: 0 additions & 3 deletions manifests/overlays/incubation/deployment.yaml

This file was deleted.

11 changes: 0 additions & 11 deletions manifests/overlays/incubation/kustomization.yaml

This file was deleted.

88 changes: 0 additions & 88 deletions manifests/overlays/odhdashboardconfig/odh-dashboard-config.yaml

This file was deleted.

This file was deleted.

3 changes: 0 additions & 3 deletions manifests/overlays/performance/deployment.yaml

This file was deleted.

11 changes: 0 additions & 11 deletions manifests/overlays/performance/kustomization.yaml

This file was deleted.

5 changes: 5 additions & 0 deletions manifests/rhoai/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
# RHOAI Manifests

These manifests are only for RHOAI. Overrides can be performed on the manifest files in common.

Use the `./shared` folder to place anything that is shared between RHOAI deployments.
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ commonLabels:
app: odh-dashboard
app.kubernetes.io/part-of: odh-dashboard
resources:
- ../base
- ./nvidia
- ./rhoam
- ./starburst
8 changes: 8 additions & 0 deletions manifests/rhoai/addon/kustomization.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization
commonLabels:
app: odh-dashboard
app.kubernetes.io/part-of: odh-dashboard
resources:
- ../shared
- ./apps
Original file line number Diff line number Diff line change
Expand Up @@ -4,5 +4,4 @@ commonLabels:
app: odh-dashboard
app.kubernetes.io/part-of: odh-dashboard
resources:
- ../base
- ./starburst-enterprise
7 changes: 7 additions & 0 deletions manifests/rhoai/onprem/kustomization.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization
commonLabels:
app: odh-dashboard
app.kubernetes.io/part-of: odh-dashboard
resources:
- ../shared
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ commonLabels:
app: odh-dashboard
app.kubernetes.io/part-of: odh-dashboard
resources:
- ../../../apps
- ./aikit
- ./anaconda-ce
- ./elastic
Expand Down
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ commonLabels:
app: rhods-dashboard
app.kubernetes.io/part-of: rhods-dashboard
resources:
- ../../base
- anaconda-ce-validator-cron.yaml
patchesJson6902:
- path: service-account.yaml
Expand Down Expand Up @@ -84,4 +83,4 @@ vars:
fieldref:
fieldpath: data.odh-dashboard-image
configurations:
- params.yaml
- params.yaml
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,10 @@ commonLabels:
app: rhods-dashboard
app.kubernetes.io/part-of: rhods-dashboard
resources:
- ../../consolelink
- ../../../common/consolelink
patchesJson6902:
- path: consolelink.yaml
target:
version: v1
kind: ConsoleLink
name: odhlink
name: odhlink
11 changes: 11 additions & 0 deletions manifests/rhoai/shared/kustomization.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
apiVersion: kustomize.config.k8s.io/v1beta1
kind: Kustomization
commonLabels:
app: odh-dashboard
app.kubernetes.io/part-of: odh-dashboard
resources:
- ../../common
- ./apps
- ./base
- ./consolelink
- ./odhdashboardconfig

0 comments on commit 2002af4

Please sign in to comment.