Chapter 4. Creating project-scoped resources
Users can access global resources in all OpenShift AI projects, but can access project-scoped resources within the specified project only.
Cluster administrators can create the following types of project-scoped resources in any OpenShift AI project:
- Workbench images
- Hardware profiles
- Accelerator profiles
- Model-serving runtimes for KServe
All resource names must be unique within a project.
A project member who is not a cluster administrator can create project-scoped resources for their project, as described in Creating project-scoped resources for your project.
Prerequisites
- You can access the OpenShift console as a cluster administrator.
-
You have set the
disableProjectScoped
dashboard configuration option tofalse
, as described in Customizing the dashboard.
Procedure
- Log in to the OpenShift console as a cluster administrator.
Copy the YAML code to create the resource.
You can get the YAML code from a trusted source, such as an existing resource, a Git repository, or documentation.
For example, you can copy the YAML code from an existing resource, as follows:
-
In the Administrator perspective, click Home
Search. From the Project list, select the appropriate value.
To limit the search to global OpenShift AI resources only, select the
redhat-ods-applications
project.In the Resources list, search for the relevant resource type, as follows:
-
For workbench images, search for
ImageStream
. -
For hardware profiles, search for
HardwareProfile
. -
For accelerator profiles, search for
AcceleratorProfile
. -
For serving runtimes, search for
Template
. From the resulting list, find the templates that have theobjects.kind
specification set toServingRuntime
.
-
For workbench images, search for
- Select a resource, and click the YAML tab.
- Copy the YAML content, and click Cancel.
-
In the Administrator perspective, click Home
- From the Project list, select the target project name. Note the spelling.
- From the toolbar, click the + icon to open the Import YAML page.
- Paste the relevant YAML content into the code area.
-
Edit the
metadata.namespace
value to specify the name of the target project. -
If necessary, edit the
metadata.name
value to ensure that the resource name is unique within the specified project. Optional: Edit the resource name that is displayed in the OpenShift AI console, as follows:
-
For workbench images, edit the
metadata.annotations.opendatahub.io/notebook-image-name
value. -
For hardware profiles and accelerator profiles, edit the
spec.displayName
value. -
For serving runtimes, edit the
objects.metadata.annotations.openshift.io/display-name
value.
-
For workbench images, edit the
- Click Create.
Verification
- Log in to the OpenShift AI console as a regular user.
Verify that the project-scoped resource is shown in the specified project only:
- For workbench images, hardware profiles, and accelerator profiles, see Creating a workbench.
- For serving runtimes, see Deploying models on the single-model serving platform.