From 706d9dffe8cc9c3897c368115b3c6e72ba4d47fd Mon Sep 17 00:00:00 2001 From: Jirka Tesar Date: Wed, 18 Oct 2023 15:40:44 +0200 Subject: [PATCH 01/26] Initial commit --- modules/chapter1/pages/section2.adoc | 312 ++++++++++++++++++++++++++- 1 file changed, 310 insertions(+), 2 deletions(-) diff --git a/modules/chapter1/pages/section2.adoc b/modules/chapter1/pages/section2.adoc index 83a976c..d8ea80f 100644 --- a/modules/chapter1/pages/section2.adoc +++ b/modules/chapter1/pages/section2.adoc @@ -1,3 +1,311 @@ -= Section 2 += installation Using the CLI -This is _Section 2_ of _Chapter 1_ in the *hello* quick course.... \ No newline at end of file +Similarly to the Web console installation, both Red{nbsp}Hat Openshift Pipelines operator and Red{nbsp}Hat Openshift Data Science operator have to be installed. + +== Installation of an operator using CLI +Operator Lifecycle Manager (OLM) uses following resources: + +Catalog Resource:: + Each catalog source resource references an operator repository. Periodically, the OLM + examines the catalog sources in the cluster and retrieves information about the operators in + each source. + +Package manifest:: + The OLM creates a package manifest for each available operator. The package manifest + contains the required information to install an operator, such as the available channels. + +Operator group:: + Operator groups define how the OLM presents operators across namespaces. +Subscription:: + Cluster administrators create subscriptions to install operators. +Operator:: + The OLM creates operator resources to store information about installed operators. +Install plan:: + The OLM creates install plan resources as part of the installation and update process. When + requiring approvals, administrators must approve install plans. +Cluster service version (CSV):: + Each version of an operator has a corresponding CSV. The CSV contains the information that + the OLM requires to install the operator. + +When installing an operator, an administrator must create only the operator group (unsless the target namespace is openshift operators where the group already exists) and the subscription. + +Following are examples of the resources must to create. + +Namespace:: +[subs=+quotes] +---- +apiVersion: v1 +kind: Namespace +metadata: + name: _operator_namespace_ +spec: {} +---- + +Operator group:: +[subs=+quotes] +---- +apiVersion: operators.coreos.com/v1 +kind: OperatorGroup +metadata: + name: _Operator_group_name_ + namespace: _operator_namespace_ +spec: {} +---- + +Subscription:: +[subs=+quotes] +---- +apiVersion: operators.coreos.com/v1alpha1 +kind: Subscription +metadata: + name: _Subscription_name_ <1> + namespace: _operator_namespace_ +spec: + channel: _channel_ + installPlanApproval: _Manual/Automatic_ + name: _Operator_name_ + source: _Catalog_source_ + sourceNamespace: openshift-marketplace + startingCSV: _Operator_CSV_ +---- + +<1> Hello World + +[#manual_approval] +[NOTE] +When *installPlanApproval* is set to *Manual* the installation has to be manually approved in order to start. +[subs=+quotes] +---- +$ oc get installplan -n _operator_namespace_ +NAME CSV APPROVAL APPROVED +install-vpgls _operator_csv_ Manual #false# + +$ oc patch installplan install-vpgls --type merge -p '{"spec":{"approved":true}}' -n _operator_name_ +installplan.operators.coreos.com/install-vpgls patched + +oc get installplan -n redhat-ods-operator +NAME CSV APPROVAL APPROVED +install-vpgls _operator_name_ Manual #true# +---- + + +== Installation of the Red{nbsp}Hat Openshift Pipelines Operator + +Following command lists available catalog sources. +Pipelines operator is available from Red{nbsp}Hat operators catalogue. + +[subs=+quotes] +---- +$ oc get catalogsource -n openshift-marketplace +NAME DISPLAY TYPE PUBLISHER AGE +certified-operators Certified Operators grpc Red Hat 24h +community-operators Community Operators grpc Red Hat 24h +redhat-marketplace Red Hat Marketplace grpc Red Hat 24h +#redhat-operators Red Hat Operators grpc Red Hat 24h# +---- + + +To install the Pipelines operator the package manifest must be located. + +[subs=+quotes] +---- +$ oc get packagemanifest +..._output omitted_... +flux Red Hat Marketplace 24h +ack-emrcontainers-controller Community Operators 24h +fujitsu-enterprise-operator Certified Operators 24h +#openshift-pipelines-operator-rh Red Hat Operators 24h# +rhoas-operator Community Operators 24h +silicom-sts-operator Community Operators 24h +openshiftartifactoryha-operator Certified Operators 24h +..._output omitted_ ... +---- + +To get more information about the operator use *oc describe* +[subs=+quotes] +---- +oc describe packagemanifest openshift-pipelines-operator-rh -n openshift-marketplace +Name: openshift-pipelines-operator-rh +Namespace: openshift-marketplace +Labels: catalog=redhat-operators +..._output omitted_... +Spec: +Status: + Catalog Source: redhat-operators + Catalog Source Display Name: Red Hat Operators + Catalog Source Namespace: openshift-marketplace + Catalog Source Publisher: Red Hat + Channels: + Current CSV: openshift-pipelines-operator-rh.v1.12.0 + Current CSV Desc: + Annotations: + Alm - Examples: [ +..._output omitted_... + Capabilities: Full Lifecycle + Categories: Developer Tools, Integration & Delivery + Certified: false + Description: Red Hat OpenShift Pipelines is a cloud-native CI/CD solution for building pipelines using Tekton concepts which run natively on OpenShift and Kubernetes. +..._output omitted_... + + Display Name: Red Hat OpenShift Pipelines + Install Modes: + Supported: false + Type: OwnNamespace + Supported: false + Type: SingleNamespace + Supported: false + Type: MultiNamespace + Supported: true + Type: AllNamespaces + Keywords: + tektoncd + openshift + build + pipeline + Links: + Name: Tekton Pipeline GitHub Repository + URL: https://github.com/tektoncd/pipeline + Name: Tekton Operator GitHub Repository + URL: https://github.com/tektoncd/operator + Maintainers: + Email: pipelines-extcomm@redhat.com + Name: Red Hat + Maturity: alpha + Provider: + Name: Red Hat + Related Images: +..._output omitted_... +---- + +The Pipelines operator's default namespace is openshift-operators, hence neither the namespace nor operator group resources must be created. An administrator must create only the subscription to start the installation. Following is an example of the Pipelines operator subscription. + +[subs=+quotes] +---- +$ cat < pipelines-subs.yaml +apiVersion: operators.coreos.com/v1alpha1 +kind: Subscription +metadata: + name: openshift-pipelines-operator-rh + namespace: openshift-operators +spec: + channel: latest + installPlanApproval: Automatic + name: openshift-pipelines-operator-rh + source: redhat-operators + sourceNamespace: openshift-marketplace + startingCSV: openshift-pipelines-operator-rh.v1.12.0 +EOF + +$ oc create -f pipelines-subs.yaml +---- + +[NOTE] +In case *installPlanApproval* is set to *Manual*, installation has to be approved first in order to start. + + +== Installation of the Red{nbsp}Hat Openshift Data Science operator + +Red{nbsp}Hat Openshift Data Science operator is available through Red Hat Operators catalogue. + +[subs=+quotes] +---- +$ oc get packagemanifest +_...output ommited..._ +cloudbees-ci-rhmp Red Hat Marketplace 3h34m +timemachine-operator Certified Operators 3h34m +apicast-community-operator Community Operators 3h34m +#rhods-operator Red Hat Operators 3h34m# +shipwright-operator Community Operators 3h34m +pachyderm-operator-rhmp Red Hat Marketplace 3h34m +nxiq-operator-certified Certified Operators 3h34m +_...output ommited..._ +---- + +The operator has a suggested namespace *redhat-ods-operator* to be installed into. However it can be installed into any namespace an administrator chooses. + +[subs=+quotes] +---- +$ oc describe packagemanifest rhods-operator +_...output ommited..._ +operatorframework.io/suggested-namespace: redhat-ods-operator +_...output ommited..._ +---- + +Unless an administrator chooses to install it into the default openshift-operators namespace, the namespace has to be created first. + +---- +$ cat < rhods-ns.yaml +apiVersion: v1 +kind: Namespace +metadata: + name: redhat-ods-operator +spec: {} +EOF + +$ oc create -f rhods-ns.yaml +namespace/redhat-ods-operator created +---- + +Within the new namespace an *Operator Group* resource has to be created +---- +$ cat < rhods-og.yaml +apiVersion: operators.coreos.com/v1 +kind: OperatorGroup +metadata: + name: redhat-ods-operator + namespace: redhat-ods-operator +spec: {} +EOF + +$ oc create -f rhods-og.yaml +operatorgroup.operators.coreos.com/redhat-ods-operator created +---- + +Finally the operator's subscription can be created to start the installation +---- +$ cat < rhods-subs.yaml +apiVersion: operators.coreos.com/v1alpha1 +kind: Subscription +metadata: + name: rhods-operator + namespace: redhat-ods-operator +spec: + channel: stable + installPlanApproval: Automatic + name: rhods-operator + source: redhat-operators + sourceNamespace: openshift-marketplace + startingCSV: rhods-operator.1.33.0 +EOF + +$ oc create -f rhods-subs.yaml +subscription.operators.coreos.com/rhods-operator created +---- + + +[NOTE] +In case the *installPlanApproval* is set to *Manual*, installation has to be approved first in order to start. For more information xref:section2.adoc#manual_approval[see the note] + + + +[NOTE] +It may take some time for all the operator's pods to start so Red{nbsp}Hat Openshift Data Science dashboard may not be available immediately. You can check their status in the *redhat-ods-applications* namespace. Once all pods are running and ready, you can open the dashboard in the Openshift web console. + +---- +$ oc get pods -n redhat-ods-applications +NAME READY STATUS RESTARTS AGE +etcd-cc4d875c-8trld 0/1 PodInitializing 0 7s +modelmesh-controller-5749b94578-2j8nv 0/1 Running 0 7s +modelmesh-controller-5749b94578-jcxc7 0/1 ContainerCreating 0 7s +modelmesh-controller-5749b94578-rww94 0/1 ContainerCreating 0 7s +notebook-controller-deployment-685bb8f9d6-6dtbh 0/1 Running 0 29s +odh-model-controller-7d495b56cb-8pnn9 0/1 Running 0 7s +odh-model-controller-7d495b56cb-8xh5h 0/1 Running 0 7s +odh-model-controller-7d495b56cb-kcmqr 0/1 Running 0 7s +odh-notebook-controller-manager-866b7cf859-2wf2j 1/1 Running 0 29s +rhods-dashboard-7bd94f464f-7lvn8 1/2 Running 0 47s +rhods-dashboard-7bd94f464f-hksf6 1/2 Running 0 47s +rhods-dashboard-7bd94f464f-n5rbz 1/2 Running 0 47s +rhods-dashboard-7bd94f464f-pg984 1/2 Running 0 47s +rhods-dashboard-7bd94f464f-xd255 1/2 Running 0 47s +---- From 87723e1844e3d2f293ac14907f58c6a9ff066fd1 Mon Sep 17 00:00:00 2001 From: Jirka Tesar Date: Wed, 18 Oct 2023 16:47:41 +0200 Subject: [PATCH 02/26] callout modified --- modules/chapter1/pages/section2.adoc | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/modules/chapter1/pages/section2.adoc b/modules/chapter1/pages/section2.adoc index d8ea80f..719e61b 100644 --- a/modules/chapter1/pages/section2.adoc +++ b/modules/chapter1/pages/section2.adoc @@ -69,8 +69,7 @@ spec: startingCSV: _Operator_CSV_ ---- -<1> Hello World - +<1> Name of the subscription resource [#manual_approval] [NOTE] When *installPlanApproval* is set to *Manual* the installation has to be manually approved in order to start. From 79f708d08e8966d0ae05efb258ab7c025959c21b Mon Sep 17 00:00:00 2001 From: Jirka Tesar Date: Wed, 18 Oct 2023 17:34:43 +0200 Subject: [PATCH 03/26] callouts fix --- modules/chapter1/pages/section2.adoc | 47 +++++++++++++++++++--------- 1 file changed, 32 insertions(+), 15 deletions(-) diff --git a/modules/chapter1/pages/section2.adoc b/modules/chapter1/pages/section2.adoc index 719e61b..253f8a6 100644 --- a/modules/chapter1/pages/section2.adoc +++ b/modules/chapter1/pages/section2.adoc @@ -27,66 +27,83 @@ Cluster service version (CSV):: Each version of an operator has a corresponding CSV. The CSV contains the information that the OLM requires to install the operator. -When installing an operator, an administrator must create only the operator group (unsless the target namespace is openshift operators where the group already exists) and the subscription. +When installing an operator, an administrator must create only the operator group (unsless the target namespace is openshift operators where the group already exists) and the subscription. Optionally also a namespace can be created if it does not exists. -Following are examples of the resources must to create. +Following are examples of the resources an adminstrator must to create. Namespace:: +-- [subs=+quotes] ---- apiVersion: v1 kind: Namespace metadata: - name: _operator_namespace_ + name: _operator_namespace_ <1> spec: {} ---- +<1> Name of the namespace to install the operator into. +-- +NOTE: Namespace has to be only created if it does not already exist. An operator can be installed into an existing namespace. Operator group:: +-- [subs=+quotes] ---- apiVersion: operators.coreos.com/v1 kind: OperatorGroup metadata: - name: _Operator_group_name_ - namespace: _operator_namespace_ + name: _Operator_group_name_ <1> + namespace: _operator_namespace_ <2> spec: {} ---- +<1> Name of the operator group resource. +<2> Name of the namespace to create the operator group resource in. +-- Subscription:: +-- [subs=+quotes] ---- apiVersion: operators.coreos.com/v1alpha1 kind: Subscription metadata: name: _Subscription_name_ <1> - namespace: _operator_namespace_ + namespace: _operator_namespace_ <2> spec: channel: _channel_ - installPlanApproval: _Manual/Automatic_ + installPlanApproval: _Manual/Automatic_ <3> name: _Operator_name_ source: _Catalog_source_ sourceNamespace: openshift-marketplace startingCSV: _Operator_CSV_ ---- +<1> Name of the subscription resource. +<2> Name of the namespace to create the subscription resource in. +<3> installPlanApproval can be either *Automatic* or *Manual*. +-- -<1> Name of the subscription resource [#manual_approval] -[NOTE] -When *installPlanApproval* is set to *Manual* the installation has to be manually approved in order to start. + +IMPORTANT: When *installPlanApproval* is set to *Manual* the installation has to be manually approved in order to start. + +-- [subs=+quotes] ---- $ oc get installplan -n _operator_namespace_ NAME CSV APPROVAL APPROVED -install-vpgls _operator_csv_ Manual #false# +install-vpgls _operator_csv_ Manual #false# <1> -$ oc patch installplan install-vpgls --type merge -p '{"spec":{"approved":true}}' -n _operator_name_ -installplan.operators.coreos.com/install-vpgls patched +$ oc patch installplan install-vpgls --type merge -p '{"spec":{"approved":true}}' -n _operator_name_ +installplan.operators.coreos.com/install-vpgls patched <2> oc get installplan -n redhat-ods-operator NAME CSV APPROVAL APPROVED -install-vpgls _operator_name_ Manual #true# +install-vpgls _operator_name_ Manual #true# <3> ---- - +<1> Approval has not been set. +<2> The patch command approves the installation. +<3> Approval has been set. +-- == Installation of the Red{nbsp}Hat Openshift Pipelines Operator From 88da9f8d413e2fa1620226d74c1e6d50f63f82da Mon Sep 17 00:00:00 2001 From: Jirka Tesar Date: Thu, 19 Oct 2023 15:44:24 +0200 Subject: [PATCH 04/26] Minor text fixes --- modules/chapter1/pages/section2.adoc | 33 ++++++++++++++-------------- 1 file changed, 16 insertions(+), 17 deletions(-) diff --git a/modules/chapter1/pages/section2.adoc b/modules/chapter1/pages/section2.adoc index 253f8a6..fd04508 100644 --- a/modules/chapter1/pages/section2.adoc +++ b/modules/chapter1/pages/section2.adoc @@ -1,6 +1,6 @@ -= installation Using the CLI += Installation Using the Command Line Interface -Similarly to the Web console installation, both Red{nbsp}Hat Openshift Pipelines operator and Red{nbsp}Hat Openshift Data Science operator have to be installed. +Similarly to the Web Console installation, both *Red{nbsp}Hat Openshift Pipelines* operator and *Red{nbsp}Hat Openshift Data Science* operators have to be installed. == Installation of an operator using CLI Operator Lifecycle Manager (OLM) uses following resources: @@ -27,9 +27,9 @@ Cluster service version (CSV):: Each version of an operator has a corresponding CSV. The CSV contains the information that the OLM requires to install the operator. -When installing an operator, an administrator must create only the operator group (unsless the target namespace is openshift operators where the group already exists) and the subscription. Optionally also a namespace can be created if it does not exists. +When installing an operator, an administrator must create only the operator group (unless the target namespace is *openshift-operators* where the operator group resource already exists) and the subscription. Optionally a namespace can be created if it does not exists. -Following are examples of the resources an adminstrator must to create. +Following are examples of the resources an adminstrator must create. Namespace:: -- @@ -84,7 +84,7 @@ spec: [#manual_approval] -IMPORTANT: When *installPlanApproval* is set to *Manual* the installation has to be manually approved in order to start. +IMPORTANT: When *installPlanApproval* is set to *Manual*, the installation has to be manually approved in order to start. -- [subs=+quotes] @@ -93,7 +93,7 @@ $ oc get installplan -n _operator_namespace_ NAME CSV APPROVAL APPROVED install-vpgls _operator_csv_ Manual #false# <1> -$ oc patch installplan install-vpgls --type merge -p '{"spec":{"approved":true}}' -n _operator_name_ +$ oc patch installplan install-vpgls --type merge -p '{"spec":{"approved":true}}' -n _operator_namespace_ installplan.operators.coreos.com/install-vpgls patched <2> oc get installplan -n redhat-ods-operator @@ -102,13 +102,13 @@ install-vpgls _operator_name_ Manual #true# <3> ---- <1> Approval has not been set. <2> The patch command approves the installation. -<3> Approval has been set. +<3> Approval has been set and installation starts. -- == Installation of the Red{nbsp}Hat Openshift Pipelines Operator -Following command lists available catalog sources. -Pipelines operator is available from Red{nbsp}Hat operators catalogue. +The following command lists available catalog sources. +Pipelines operator is available from Red{nbsp}Hat operators catalogue. [subs=+quotes] ---- @@ -121,7 +121,7 @@ redhat-marketplace Red Hat Marketplace grpc Red Hat 24h ---- -To install the Pipelines operator the package manifest must be located. +To install the *Red{nbsp}Hat Openshift Pipelines* operator the package manifest must be located. [subs=+quotes] ---- @@ -193,7 +193,7 @@ Status: ..._output omitted_... ---- -The Pipelines operator's default namespace is openshift-operators, hence neither the namespace nor operator group resources must be created. An administrator must create only the subscription to start the installation. Following is an example of the Pipelines operator subscription. +The Pipelines operator's default namespace is openshift-operators, hence neither the namespace nor operator group resources must be created. An administrator must create only the subscription to start the installation. Following is an example of the Pipelines operator subscription creation. [subs=+quotes] ---- @@ -216,7 +216,7 @@ $ oc create -f pipelines-subs.yaml ---- [NOTE] -In case *installPlanApproval* is set to *Manual*, installation has to be approved first in order to start. +In case *installPlanApproval* is set to *Manual*, installation has to be approved first in order to start. Refer to the xref:section2.adoc#manual_approval[previous section] for more information. == Installation of the Red{nbsp}Hat Openshift Data Science operator @@ -247,7 +247,7 @@ operatorframework.io/suggested-namespace: redhat-ods-operator _...output ommited..._ ---- -Unless an administrator chooses to install it into the default openshift-operators namespace, the namespace has to be created first. +Unless an administrator chooses to install it into the openshift-operators namespace, the namespace has to be created first. ---- $ cat < rhods-ns.yaml @@ -262,7 +262,7 @@ $ oc create -f rhods-ns.yaml namespace/redhat-ods-operator created ---- -Within the new namespace an *Operator Group* resource has to be created +Within the new namespace an *Operator Group* resource has to be created. ---- $ cat < rhods-og.yaml apiVersion: operators.coreos.com/v1 @@ -300,12 +300,11 @@ subscription.operators.coreos.com/rhods-operator created [NOTE] -In case the *installPlanApproval* is set to *Manual*, installation has to be approved first in order to start. For more information xref:section2.adoc#manual_approval[see the note] - +In case the *installPlanApproval* is set to *Manual*, installation has to be approved first in order to start. Refer to the xref:section2.adoc#manual_approval[previous section] for more information. [NOTE] -It may take some time for all the operator's pods to start so Red{nbsp}Hat Openshift Data Science dashboard may not be available immediately. You can check their status in the *redhat-ods-applications* namespace. Once all pods are running and ready, you can open the dashboard in the Openshift web console. +It may take some time for all the operator's pods to start hence the *Red{nbsp}Hat Openshift Data Science* dashboard may not be available immediately. You can check their status in the *redhat-ods-applications* namespace. Once all pods are running and ready, you can open the dashboard in the Openshift Web Console. ---- $ oc get pods -n redhat-ods-applications From cd18ac107a7241f353608a82394c183c3208da7d Mon Sep 17 00:00:00 2001 From: jtesar-rh <74060005+jtesar-rh@users.noreply.github.com> Date: Wed, 25 Oct 2023 15:50:08 +0200 Subject: [PATCH 05/26] Update modules/chapter1/pages/section2.adoc MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-authored-by: Jaime Ramírez --- modules/chapter1/pages/section2.adoc | 1 + 1 file changed, 1 insertion(+) diff --git a/modules/chapter1/pages/section2.adoc b/modules/chapter1/pages/section2.adoc index fd04508..0173d96 100644 --- a/modules/chapter1/pages/section2.adoc +++ b/modules/chapter1/pages/section2.adoc @@ -3,6 +3,7 @@ Similarly to the Web Console installation, both *Red{nbsp}Hat Openshift Pipelines* operator and *Red{nbsp}Hat Openshift Data Science* operators have to be installed. == Installation of an operator using CLI +In OpenShift, the Operator Lifecycle Manager (OLM) helps users install and manage operators and their associated services. Operator Lifecycle Manager (OLM) uses following resources: Catalog Resource:: From d00417aba71ad471dd3c0c25c8e1f0c18c6a7497 Mon Sep 17 00:00:00 2001 From: jtesar-rh <74060005+jtesar-rh@users.noreply.github.com> Date: Wed, 25 Oct 2023 15:50:30 +0200 Subject: [PATCH 06/26] Update modules/chapter1/pages/section2.adoc MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-authored-by: Jaime Ramírez --- modules/chapter1/pages/section2.adoc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/chapter1/pages/section2.adoc b/modules/chapter1/pages/section2.adoc index 0173d96..531207b 100644 --- a/modules/chapter1/pages/section2.adoc +++ b/modules/chapter1/pages/section2.adoc @@ -113,7 +113,7 @@ Pipelines operator is available from Red{nbsp}Hat operators catalogue. [subs=+quotes] ---- -$ oc get catalogsource -n openshift-marketplace +$ *oc get catalogsource -n openshift-marketplace* NAME DISPLAY TYPE PUBLISHER AGE certified-operators Certified Operators grpc Red Hat 24h community-operators Community Operators grpc Red Hat 24h From 45be94acfd376bf84f90917f7328a74304883c61 Mon Sep 17 00:00:00 2001 From: jtesar-rh <74060005+jtesar-rh@users.noreply.github.com> Date: Wed, 25 Oct 2023 15:51:11 +0200 Subject: [PATCH 07/26] Update modules/chapter1/pages/section2.adoc MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-authored-by: Jaime Ramírez --- modules/chapter1/pages/section2.adoc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/chapter1/pages/section2.adoc b/modules/chapter1/pages/section2.adoc index 531207b..285c530 100644 --- a/modules/chapter1/pages/section2.adoc +++ b/modules/chapter1/pages/section2.adoc @@ -122,7 +122,7 @@ redhat-marketplace Red Hat Marketplace grpc Red Hat 24h ---- -To install the *Red{nbsp}Hat Openshift Pipelines* operator the package manifest must be located. +To install the *Red{nbsp}Hat Openshift Pipelines* operator, locate the `openshift-pipelines-operator-rh` package manifest. [subs=+quotes] ---- From 88f2a9af53e0a4c574c0e0d7d01b50745bd91377 Mon Sep 17 00:00:00 2001 From: jtesar-rh <74060005+jtesar-rh@users.noreply.github.com> Date: Wed, 25 Oct 2023 15:51:29 +0200 Subject: [PATCH 08/26] Update modules/chapter1/pages/section2.adoc MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-authored-by: Jaime Ramírez --- modules/chapter1/pages/section2.adoc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/chapter1/pages/section2.adoc b/modules/chapter1/pages/section2.adoc index 285c530..9dbaa15 100644 --- a/modules/chapter1/pages/section2.adoc +++ b/modules/chapter1/pages/section2.adoc @@ -126,7 +126,7 @@ To install the *Red{nbsp}Hat Openshift Pipelines* operator, locate the `openshif [subs=+quotes] ---- -$ oc get packagemanifest +$ oc get packagemanifest | grep pipelines ..._output omitted_... flux Red Hat Marketplace 24h ack-emrcontainers-controller Community Operators 24h From 69c78fd56a5d2d54d03f9de5c2a3f133a417c827 Mon Sep 17 00:00:00 2001 From: Jirka Tesar Date: Wed, 25 Oct 2023 16:24:23 +0200 Subject: [PATCH 09/26] Jaime comments implemented --- modules/chapter1/pages/section2.adoc | 70 ++++++++++++---------------- 1 file changed, 29 insertions(+), 41 deletions(-) diff --git a/modules/chapter1/pages/section2.adoc b/modules/chapter1/pages/section2.adoc index 9dbaa15..0ad8782 100644 --- a/modules/chapter1/pages/section2.adoc +++ b/modules/chapter1/pages/section2.adoc @@ -90,14 +90,14 @@ IMPORTANT: When *installPlanApproval* is set to *Manual*, the installation has -- [subs=+quotes] ---- -$ oc get installplan -n _operator_namespace_ +$ *oc get installplan -n _operator_namespace_* NAME CSV APPROVAL APPROVED install-vpgls _operator_csv_ Manual #false# <1> -$ oc patch installplan install-vpgls --type merge -p '{"spec":{"approved":true}}' -n _operator_namespace_ +$ *oc patch installplan install-vpgls --type merge -p '{"spec":{"approved":true}}' -n _operator_namespace_* installplan.operators.coreos.com/install-vpgls patched <2> -oc get installplan -n redhat-ods-operator +$ *oc get installplan -n redhat-ods-operator* NAME CSV APPROVAL APPROVED install-vpgls _operator_name_ Manual #true# <3> ---- @@ -126,22 +126,14 @@ To install the *Red{nbsp}Hat Openshift Pipelines* operator, locate the `openshif [subs=+quotes] ---- -$ oc get packagemanifest | grep pipelines -..._output omitted_... -flux Red Hat Marketplace 24h -ack-emrcontainers-controller Community Operators 24h -fujitsu-enterprise-operator Certified Operators 24h -#openshift-pipelines-operator-rh Red Hat Operators 24h# -rhoas-operator Community Operators 24h -silicom-sts-operator Community Operators 24h -openshiftartifactoryha-operator Certified Operators 24h -..._output omitted_ ... +$ *oc get packagemanifest | grep pipelines* +openshift-pipelines-operator-rh Red Hat Operators 24h ---- To get more information about the operator use *oc describe* [subs=+quotes] ---- -oc describe packagemanifest openshift-pipelines-operator-rh -n openshift-marketplace +$ *oc describe packagemanifest openshift-pipelines-operator-rh -n openshift-marketplace* Name: openshift-pipelines-operator-rh Namespace: openshift-marketplace Labels: catalog=redhat-operators @@ -194,11 +186,11 @@ Status: ..._output omitted_... ---- -The Pipelines operator's default namespace is openshift-operators, hence neither the namespace nor operator group resources must be created. An administrator must create only the subscription to start the installation. Following is an example of the Pipelines operator subscription creation. +The Pipelines operator's default namespace is _openshift-operators_, hence neither the namespace nor operator group resources must be created. Create only the subscription resource to start the installation. Following is an example of the Pipelines operator subscription creation. [subs=+quotes] ---- -$ cat < pipelines-subs.yaml +$ *cat < pipelines-subs.yaml* apiVersion: operators.coreos.com/v1alpha1 kind: Subscription metadata: @@ -213,11 +205,11 @@ spec: startingCSV: openshift-pipelines-operator-rh.v1.12.0 EOF -$ oc create -f pipelines-subs.yaml +$ *oc create -f pipelines-subs.yaml* ---- [NOTE] -In case *installPlanApproval* is set to *Manual*, installation has to be approved first in order to start. Refer to the xref:section2.adoc#manual_approval[previous section] for more information. +In case *installPlanApproval* is set to *Manual*, approve the installation first to start it. Refer to the xref:section2.adoc#manual_approval[previous section] for more information. == Installation of the Red{nbsp}Hat Openshift Data Science operator @@ -226,32 +218,25 @@ Red{nbsp}Hat Openshift Data Science operator is available through Red Hat Operat [subs=+quotes] ---- -$ oc get packagemanifest -_...output ommited..._ -cloudbees-ci-rhmp Red Hat Marketplace 3h34m -timemachine-operator Certified Operators 3h34m -apicast-community-operator Community Operators 3h34m -#rhods-operator Red Hat Operators 3h34m# -shipwright-operator Community Operators 3h34m -pachyderm-operator-rhmp Red Hat Marketplace 3h34m -nxiq-operator-certified Certified Operators 3h34m -_...output ommited..._ +$ *oc get packagemanifest | grep rhods-operator* +rhods-operator Red Hat Operators 3h34m ---- -The operator has a suggested namespace *redhat-ods-operator* to be installed into. However it can be installed into any namespace an administrator chooses. +The operator has a suggested namespace *redhat-ods-operator* to be installed into. However it can be installed into any namespace you choose. [subs=+quotes] ---- -$ oc describe packagemanifest rhods-operator +$ *oc describe packagemanifest rhods-operator* _...output ommited..._ operatorframework.io/suggested-namespace: redhat-ods-operator _...output ommited..._ ---- -Unless an administrator chooses to install it into the openshift-operators namespace, the namespace has to be created first. +Unless you choose to install it into the _openshift-operators_ namespace, create the namespace first. +[subs=+quotes] ---- -$ cat < rhods-ns.yaml +$ *cat < rhods-ns.yaml* apiVersion: v1 kind: Namespace metadata: @@ -259,13 +244,14 @@ metadata: spec: {} EOF -$ oc create -f rhods-ns.yaml +$ *oc create -f rhods-ns.yaml* namespace/redhat-ods-operator created ---- -Within the new namespace an *Operator Group* resource has to be created. +Within the new namespace create the *Operator Group* resource. +[subs=+quotes] ---- -$ cat < rhods-og.yaml +$ *cat < rhods-og.yaml* apiVersion: operators.coreos.com/v1 kind: OperatorGroup metadata: @@ -274,13 +260,14 @@ metadata: spec: {} EOF -$ oc create -f rhods-og.yaml +$ *oc create -f rhods-og.yaml* operatorgroup.operators.coreos.com/redhat-ods-operator created ---- -Finally the operator's subscription can be created to start the installation +Finally create the operator's subscription can to start the installation +[subs=+quotes] ---- -$ cat < rhods-subs.yaml +$ *cat < rhods-subs.yaml* apiVersion: operators.coreos.com/v1alpha1 kind: Subscription metadata: @@ -295,20 +282,21 @@ spec: startingCSV: rhods-operator.1.33.0 EOF -$ oc create -f rhods-subs.yaml +$ *oc create -f rhods-subs.yaml* subscription.operators.coreos.com/rhods-operator created ---- [NOTE] -In case the *installPlanApproval* is set to *Manual*, installation has to be approved first in order to start. Refer to the xref:section2.adoc#manual_approval[previous section] for more information. +In case the *installPlanApproval* is set to *Manual*, approve the installation first to start it. Refer to the xref:section2.adoc#manual_approval[previous section] for more information. [NOTE] It may take some time for all the operator's pods to start hence the *Red{nbsp}Hat Openshift Data Science* dashboard may not be available immediately. You can check their status in the *redhat-ods-applications* namespace. Once all pods are running and ready, you can open the dashboard in the Openshift Web Console. +[subs=+quotes] ---- -$ oc get pods -n redhat-ods-applications +$ *oc get pods -n redhat-ods-applications* NAME READY STATUS RESTARTS AGE etcd-cc4d875c-8trld 0/1 PodInitializing 0 7s modelmesh-controller-5749b94578-2j8nv 0/1 Running 0 7s From 5724a8675f0e08ffbe9fba0da62ece211b33ebf7 Mon Sep 17 00:00:00 2001 From: Jirka Tesar Date: Wed, 25 Oct 2023 16:28:13 +0200 Subject: [PATCH 10/26] Jaime comments implemented --- modules/chapter1/pages/section2.adoc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/chapter1/pages/section2.adoc b/modules/chapter1/pages/section2.adoc index 0ad8782..0829456 100644 --- a/modules/chapter1/pages/section2.adoc +++ b/modules/chapter1/pages/section2.adoc @@ -2,7 +2,7 @@ Similarly to the Web Console installation, both *Red{nbsp}Hat Openshift Pipelines* operator and *Red{nbsp}Hat Openshift Data Science* operators have to be installed. -== Installation of an operator using CLI +== Introduction to CLI-based operator installations In OpenShift, the Operator Lifecycle Manager (OLM) helps users install and manage operators and their associated services. Operator Lifecycle Manager (OLM) uses following resources: From f4bd47696a77b1921feb55664b3c41dda6ff07b7 Mon Sep 17 00:00:00 2001 From: Jirka Tesar Date: Thu, 26 Oct 2023 13:46:43 +0200 Subject: [PATCH 11/26] CLI installation steps numbered --- modules/chapter1/pages/section2.adoc | 42 ++++++++++++++++++---------- 1 file changed, 27 insertions(+), 15 deletions(-) diff --git a/modules/chapter1/pages/section2.adoc b/modules/chapter1/pages/section2.adoc index 0829456..f08ae3a 100644 --- a/modules/chapter1/pages/section2.adoc +++ b/modules/chapter1/pages/section2.adoc @@ -108,9 +108,10 @@ install-vpgls _operator_name_ Manual #true# <3> == Installation of the Red{nbsp}Hat Openshift Pipelines Operator -The following command lists available catalog sources. -Pipelines operator is available from Red{nbsp}Hat operators catalogue. +1. The following command lists available catalog sources. +Pipelines operator is available from Red{nbsp}Hat operators catalogue. ++ [subs=+quotes] ---- $ *oc get catalogsource -n openshift-marketplace* @@ -122,15 +123,18 @@ redhat-marketplace Red Hat Marketplace grpc Red Hat 24h ---- -To install the *Red{nbsp}Hat Openshift Pipelines* operator, locate the `openshift-pipelines-operator-rh` package manifest. - +2. To install the *Red{nbsp}Hat Openshift Pipelines* operator, locate the `openshift-pipelines-operator-rh` package manifest. ++ [subs=+quotes] ---- $ *oc get packagemanifest | grep pipelines* openshift-pipelines-operator-rh Red Hat Operators 24h ---- -To get more information about the operator use *oc describe* + + +3. To get more information about the operator use *oc describe*. This is an optional step. ++ [subs=+quotes] ---- $ *oc describe packagemanifest openshift-pipelines-operator-rh -n openshift-marketplace* @@ -186,8 +190,10 @@ Status: ..._output omitted_... ---- -The Pipelines operator's default namespace is _openshift-operators_, hence neither the namespace nor operator group resources must be created. Create only the subscription resource to start the installation. Following is an example of the Pipelines operator subscription creation. +4. The Pipelines operator's default namespace is _openshift-operators_, hence neither the namespace nor operator group resources must be created. Create only the subscription resource to start the installation. Following is an example of the Pipelines operator subscription creation. ++ +-- [subs=+quotes] ---- $ *cat < pipelines-subs.yaml* @@ -210,20 +216,20 @@ $ *oc create -f pipelines-subs.yaml* [NOTE] In case *installPlanApproval* is set to *Manual*, approve the installation first to start it. Refer to the xref:section2.adoc#manual_approval[previous section] for more information. - +-- == Installation of the Red{nbsp}Hat Openshift Data Science operator -Red{nbsp}Hat Openshift Data Science operator is available through Red Hat Operators catalogue. - +1. Red{nbsp}Hat Openshift Data Science operator is available through Red Hat Operators catalogue. ++ [subs=+quotes] ---- $ *oc get packagemanifest | grep rhods-operator* rhods-operator Red Hat Operators 3h34m ---- -The operator has a suggested namespace *redhat-ods-operator* to be installed into. However it can be installed into any namespace you choose. - +2. The operator has a suggested namespace *redhat-ods-operator* to be installed into. However it can be installed into any namespace you choose. ++ [subs=+quotes] ---- $ *oc describe packagemanifest rhods-operator* @@ -232,8 +238,9 @@ operatorframework.io/suggested-namespace: redhat-ods-operator _...output ommited..._ ---- -Unless you choose to install it into the _openshift-operators_ namespace, create the namespace first. - +3. Unless you choose to install it into the _openshift-operators_ namespace, create the namespace first. ++ +-- [subs=+quotes] ---- $ *cat < rhods-ns.yaml* @@ -247,8 +254,10 @@ EOF $ *oc create -f rhods-ns.yaml* namespace/redhat-ods-operator created ---- +-- -Within the new namespace create the *Operator Group* resource. +4. Within the new namespace create the *Operator Group* resource. ++ [subs=+quotes] ---- $ *cat < rhods-og.yaml* @@ -264,7 +273,9 @@ $ *oc create -f rhods-og.yaml* operatorgroup.operators.coreos.com/redhat-ods-operator created ---- -Finally create the operator's subscription can to start the installation +5. Finally create the operator's subscription to start the installation. ++ +-- [subs=+quotes] ---- $ *cat < rhods-subs.yaml* @@ -313,3 +324,4 @@ rhods-dashboard-7bd94f464f-n5rbz 1/2 Running 0 rhods-dashboard-7bd94f464f-pg984 1/2 Running 0 47s rhods-dashboard-7bd94f464f-xd255 1/2 Running 0 47s ---- +-- \ No newline at end of file From 17fee916661f1f5f5bd1c238979613d0d668cacb Mon Sep 17 00:00:00 2001 From: Jirka Tesar Date: Thu, 26 Oct 2023 17:26:24 +0200 Subject: [PATCH 12/26] section 2 -> section 3 --- modules/chapter1/pages/section2.adoc | 328 +-------------------------- modules/chapter1/pages/section3.adoc | 327 +++++++++++++++++++++++++- package-lock.json | 2 +- 3 files changed, 327 insertions(+), 330 deletions(-) diff --git a/modules/chapter1/pages/section2.adoc b/modules/chapter1/pages/section2.adoc index f08ae3a..c2bf1d5 100644 --- a/modules/chapter1/pages/section2.adoc +++ b/modules/chapter1/pages/section2.adoc @@ -1,327 +1 @@ -= Installation Using the Command Line Interface - -Similarly to the Web Console installation, both *Red{nbsp}Hat Openshift Pipelines* operator and *Red{nbsp}Hat Openshift Data Science* operators have to be installed. - -== Introduction to CLI-based operator installations -In OpenShift, the Operator Lifecycle Manager (OLM) helps users install and manage operators and their associated services. -Operator Lifecycle Manager (OLM) uses following resources: - -Catalog Resource:: - Each catalog source resource references an operator repository. Periodically, the OLM - examines the catalog sources in the cluster and retrieves information about the operators in - each source. - -Package manifest:: - The OLM creates a package manifest for each available operator. The package manifest - contains the required information to install an operator, such as the available channels. - -Operator group:: - Operator groups define how the OLM presents operators across namespaces. -Subscription:: - Cluster administrators create subscriptions to install operators. -Operator:: - The OLM creates operator resources to store information about installed operators. -Install plan:: - The OLM creates install plan resources as part of the installation and update process. When - requiring approvals, administrators must approve install plans. -Cluster service version (CSV):: - Each version of an operator has a corresponding CSV. The CSV contains the information that - the OLM requires to install the operator. - -When installing an operator, an administrator must create only the operator group (unless the target namespace is *openshift-operators* where the operator group resource already exists) and the subscription. Optionally a namespace can be created if it does not exists. - -Following are examples of the resources an adminstrator must create. - -Namespace:: --- -[subs=+quotes] ----- -apiVersion: v1 -kind: Namespace -metadata: - name: _operator_namespace_ <1> -spec: {} ----- -<1> Name of the namespace to install the operator into. --- -NOTE: Namespace has to be only created if it does not already exist. An operator can be installed into an existing namespace. - -Operator group:: --- -[subs=+quotes] ----- -apiVersion: operators.coreos.com/v1 -kind: OperatorGroup -metadata: - name: _Operator_group_name_ <1> - namespace: _operator_namespace_ <2> -spec: {} ----- -<1> Name of the operator group resource. -<2> Name of the namespace to create the operator group resource in. --- - -Subscription:: --- -[subs=+quotes] ----- -apiVersion: operators.coreos.com/v1alpha1 -kind: Subscription -metadata: - name: _Subscription_name_ <1> - namespace: _operator_namespace_ <2> -spec: - channel: _channel_ - installPlanApproval: _Manual/Automatic_ <3> - name: _Operator_name_ - source: _Catalog_source_ - sourceNamespace: openshift-marketplace - startingCSV: _Operator_CSV_ ----- -<1> Name of the subscription resource. -<2> Name of the namespace to create the subscription resource in. -<3> installPlanApproval can be either *Automatic* or *Manual*. --- - -[#manual_approval] - -IMPORTANT: When *installPlanApproval* is set to *Manual*, the installation has to be manually approved in order to start. - --- -[subs=+quotes] ----- -$ *oc get installplan -n _operator_namespace_* -NAME CSV APPROVAL APPROVED -install-vpgls _operator_csv_ Manual #false# <1> - -$ *oc patch installplan install-vpgls --type merge -p '{"spec":{"approved":true}}' -n _operator_namespace_* -installplan.operators.coreos.com/install-vpgls patched <2> - -$ *oc get installplan -n redhat-ods-operator* -NAME CSV APPROVAL APPROVED -install-vpgls _operator_name_ Manual #true# <3> ----- -<1> Approval has not been set. -<2> The patch command approves the installation. -<3> Approval has been set and installation starts. --- - -== Installation of the Red{nbsp}Hat Openshift Pipelines Operator - - -1. The following command lists available catalog sources. -Pipelines operator is available from Red{nbsp}Hat operators catalogue. -+ -[subs=+quotes] ----- -$ *oc get catalogsource -n openshift-marketplace* -NAME DISPLAY TYPE PUBLISHER AGE -certified-operators Certified Operators grpc Red Hat 24h -community-operators Community Operators grpc Red Hat 24h -redhat-marketplace Red Hat Marketplace grpc Red Hat 24h -#redhat-operators Red Hat Operators grpc Red Hat 24h# ----- - - -2. To install the *Red{nbsp}Hat Openshift Pipelines* operator, locate the `openshift-pipelines-operator-rh` package manifest. -+ -[subs=+quotes] ----- -$ *oc get packagemanifest | grep pipelines* -openshift-pipelines-operator-rh Red Hat Operators 24h ----- - - - -3. To get more information about the operator use *oc describe*. This is an optional step. -+ -[subs=+quotes] ----- -$ *oc describe packagemanifest openshift-pipelines-operator-rh -n openshift-marketplace* -Name: openshift-pipelines-operator-rh -Namespace: openshift-marketplace -Labels: catalog=redhat-operators -..._output omitted_... -Spec: -Status: - Catalog Source: redhat-operators - Catalog Source Display Name: Red Hat Operators - Catalog Source Namespace: openshift-marketplace - Catalog Source Publisher: Red Hat - Channels: - Current CSV: openshift-pipelines-operator-rh.v1.12.0 - Current CSV Desc: - Annotations: - Alm - Examples: [ -..._output omitted_... - Capabilities: Full Lifecycle - Categories: Developer Tools, Integration & Delivery - Certified: false - Description: Red Hat OpenShift Pipelines is a cloud-native CI/CD solution for building pipelines using Tekton concepts which run natively on OpenShift and Kubernetes. -..._output omitted_... - - Display Name: Red Hat OpenShift Pipelines - Install Modes: - Supported: false - Type: OwnNamespace - Supported: false - Type: SingleNamespace - Supported: false - Type: MultiNamespace - Supported: true - Type: AllNamespaces - Keywords: - tektoncd - openshift - build - pipeline - Links: - Name: Tekton Pipeline GitHub Repository - URL: https://github.com/tektoncd/pipeline - Name: Tekton Operator GitHub Repository - URL: https://github.com/tektoncd/operator - Maintainers: - Email: pipelines-extcomm@redhat.com - Name: Red Hat - Maturity: alpha - Provider: - Name: Red Hat - Related Images: -..._output omitted_... ----- - - -4. The Pipelines operator's default namespace is _openshift-operators_, hence neither the namespace nor operator group resources must be created. Create only the subscription resource to start the installation. Following is an example of the Pipelines operator subscription creation. -+ --- -[subs=+quotes] ----- -$ *cat < pipelines-subs.yaml* -apiVersion: operators.coreos.com/v1alpha1 -kind: Subscription -metadata: - name: openshift-pipelines-operator-rh - namespace: openshift-operators -spec: - channel: latest - installPlanApproval: Automatic - name: openshift-pipelines-operator-rh - source: redhat-operators - sourceNamespace: openshift-marketplace - startingCSV: openshift-pipelines-operator-rh.v1.12.0 -EOF - -$ *oc create -f pipelines-subs.yaml* ----- - -[NOTE] -In case *installPlanApproval* is set to *Manual*, approve the installation first to start it. Refer to the xref:section2.adoc#manual_approval[previous section] for more information. --- - -== Installation of the Red{nbsp}Hat Openshift Data Science operator - -1. Red{nbsp}Hat Openshift Data Science operator is available through Red Hat Operators catalogue. -+ -[subs=+quotes] ----- -$ *oc get packagemanifest | grep rhods-operator* -rhods-operator Red Hat Operators 3h34m ----- - -2. The operator has a suggested namespace *redhat-ods-operator* to be installed into. However it can be installed into any namespace you choose. -+ -[subs=+quotes] ----- -$ *oc describe packagemanifest rhods-operator* -_...output ommited..._ -operatorframework.io/suggested-namespace: redhat-ods-operator -_...output ommited..._ ----- - -3. Unless you choose to install it into the _openshift-operators_ namespace, create the namespace first. -+ --- -[subs=+quotes] ----- -$ *cat < rhods-ns.yaml* -apiVersion: v1 -kind: Namespace -metadata: - name: redhat-ods-operator -spec: {} -EOF - -$ *oc create -f rhods-ns.yaml* -namespace/redhat-ods-operator created ----- --- - -4. Within the new namespace create the *Operator Group* resource. -+ -[subs=+quotes] ----- -$ *cat < rhods-og.yaml* -apiVersion: operators.coreos.com/v1 -kind: OperatorGroup -metadata: - name: redhat-ods-operator - namespace: redhat-ods-operator -spec: {} -EOF - -$ *oc create -f rhods-og.yaml* -operatorgroup.operators.coreos.com/redhat-ods-operator created ----- - -5. Finally create the operator's subscription to start the installation. -+ --- -[subs=+quotes] ----- -$ *cat < rhods-subs.yaml* -apiVersion: operators.coreos.com/v1alpha1 -kind: Subscription -metadata: - name: rhods-operator - namespace: redhat-ods-operator -spec: - channel: stable - installPlanApproval: Automatic - name: rhods-operator - source: redhat-operators - sourceNamespace: openshift-marketplace - startingCSV: rhods-operator.1.33.0 -EOF - -$ *oc create -f rhods-subs.yaml* -subscription.operators.coreos.com/rhods-operator created ----- - - -[NOTE] -In case the *installPlanApproval* is set to *Manual*, approve the installation first to start it. Refer to the xref:section2.adoc#manual_approval[previous section] for more information. - - -[NOTE] -It may take some time for all the operator's pods to start hence the *Red{nbsp}Hat Openshift Data Science* dashboard may not be available immediately. You can check their status in the *redhat-ods-applications* namespace. Once all pods are running and ready, you can open the dashboard in the Openshift Web Console. - -[subs=+quotes] ----- -$ *oc get pods -n redhat-ods-applications* -NAME READY STATUS RESTARTS AGE -etcd-cc4d875c-8trld 0/1 PodInitializing 0 7s -modelmesh-controller-5749b94578-2j8nv 0/1 Running 0 7s -modelmesh-controller-5749b94578-jcxc7 0/1 ContainerCreating 0 7s -modelmesh-controller-5749b94578-rww94 0/1 ContainerCreating 0 7s -notebook-controller-deployment-685bb8f9d6-6dtbh 0/1 Running 0 29s -odh-model-controller-7d495b56cb-8pnn9 0/1 Running 0 7s -odh-model-controller-7d495b56cb-8xh5h 0/1 Running 0 7s -odh-model-controller-7d495b56cb-kcmqr 0/1 Running 0 7s -odh-notebook-controller-manager-866b7cf859-2wf2j 1/1 Running 0 29s -rhods-dashboard-7bd94f464f-7lvn8 1/2 Running 0 47s -rhods-dashboard-7bd94f464f-hksf6 1/2 Running 0 47s -rhods-dashboard-7bd94f464f-n5rbz 1/2 Running 0 47s -rhods-dashboard-7bd94f464f-pg984 1/2 Running 0 47s -rhods-dashboard-7bd94f464f-xd255 1/2 Running 0 47s ----- --- \ No newline at end of file += Section 2 diff --git a/modules/chapter1/pages/section3.adoc b/modules/chapter1/pages/section3.adoc index 17a0eda..f08ae3a 100644 --- a/modules/chapter1/pages/section3.adoc +++ b/modules/chapter1/pages/section3.adoc @@ -1,4 +1,327 @@ -= Section 3 += Installation Using the Command Line Interface -This is _Section 3_ of _Chapter 1_ in the *hello* quick course.... +Similarly to the Web Console installation, both *Red{nbsp}Hat Openshift Pipelines* operator and *Red{nbsp}Hat Openshift Data Science* operators have to be installed. +== Introduction to CLI-based operator installations +In OpenShift, the Operator Lifecycle Manager (OLM) helps users install and manage operators and their associated services. +Operator Lifecycle Manager (OLM) uses following resources: + +Catalog Resource:: + Each catalog source resource references an operator repository. Periodically, the OLM + examines the catalog sources in the cluster and retrieves information about the operators in + each source. + +Package manifest:: + The OLM creates a package manifest for each available operator. The package manifest + contains the required information to install an operator, such as the available channels. + +Operator group:: + Operator groups define how the OLM presents operators across namespaces. +Subscription:: + Cluster administrators create subscriptions to install operators. +Operator:: + The OLM creates operator resources to store information about installed operators. +Install plan:: + The OLM creates install plan resources as part of the installation and update process. When + requiring approvals, administrators must approve install plans. +Cluster service version (CSV):: + Each version of an operator has a corresponding CSV. The CSV contains the information that + the OLM requires to install the operator. + +When installing an operator, an administrator must create only the operator group (unless the target namespace is *openshift-operators* where the operator group resource already exists) and the subscription. Optionally a namespace can be created if it does not exists. + +Following are examples of the resources an adminstrator must create. + +Namespace:: +-- +[subs=+quotes] +---- +apiVersion: v1 +kind: Namespace +metadata: + name: _operator_namespace_ <1> +spec: {} +---- +<1> Name of the namespace to install the operator into. +-- +NOTE: Namespace has to be only created if it does not already exist. An operator can be installed into an existing namespace. + +Operator group:: +-- +[subs=+quotes] +---- +apiVersion: operators.coreos.com/v1 +kind: OperatorGroup +metadata: + name: _Operator_group_name_ <1> + namespace: _operator_namespace_ <2> +spec: {} +---- +<1> Name of the operator group resource. +<2> Name of the namespace to create the operator group resource in. +-- + +Subscription:: +-- +[subs=+quotes] +---- +apiVersion: operators.coreos.com/v1alpha1 +kind: Subscription +metadata: + name: _Subscription_name_ <1> + namespace: _operator_namespace_ <2> +spec: + channel: _channel_ + installPlanApproval: _Manual/Automatic_ <3> + name: _Operator_name_ + source: _Catalog_source_ + sourceNamespace: openshift-marketplace + startingCSV: _Operator_CSV_ +---- +<1> Name of the subscription resource. +<2> Name of the namespace to create the subscription resource in. +<3> installPlanApproval can be either *Automatic* or *Manual*. +-- + +[#manual_approval] + +IMPORTANT: When *installPlanApproval* is set to *Manual*, the installation has to be manually approved in order to start. + +-- +[subs=+quotes] +---- +$ *oc get installplan -n _operator_namespace_* +NAME CSV APPROVAL APPROVED +install-vpgls _operator_csv_ Manual #false# <1> + +$ *oc patch installplan install-vpgls --type merge -p '{"spec":{"approved":true}}' -n _operator_namespace_* +installplan.operators.coreos.com/install-vpgls patched <2> + +$ *oc get installplan -n redhat-ods-operator* +NAME CSV APPROVAL APPROVED +install-vpgls _operator_name_ Manual #true# <3> +---- +<1> Approval has not been set. +<2> The patch command approves the installation. +<3> Approval has been set and installation starts. +-- + +== Installation of the Red{nbsp}Hat Openshift Pipelines Operator + + +1. The following command lists available catalog sources. +Pipelines operator is available from Red{nbsp}Hat operators catalogue. ++ +[subs=+quotes] +---- +$ *oc get catalogsource -n openshift-marketplace* +NAME DISPLAY TYPE PUBLISHER AGE +certified-operators Certified Operators grpc Red Hat 24h +community-operators Community Operators grpc Red Hat 24h +redhat-marketplace Red Hat Marketplace grpc Red Hat 24h +#redhat-operators Red Hat Operators grpc Red Hat 24h# +---- + + +2. To install the *Red{nbsp}Hat Openshift Pipelines* operator, locate the `openshift-pipelines-operator-rh` package manifest. ++ +[subs=+quotes] +---- +$ *oc get packagemanifest | grep pipelines* +openshift-pipelines-operator-rh Red Hat Operators 24h +---- + + + +3. To get more information about the operator use *oc describe*. This is an optional step. ++ +[subs=+quotes] +---- +$ *oc describe packagemanifest openshift-pipelines-operator-rh -n openshift-marketplace* +Name: openshift-pipelines-operator-rh +Namespace: openshift-marketplace +Labels: catalog=redhat-operators +..._output omitted_... +Spec: +Status: + Catalog Source: redhat-operators + Catalog Source Display Name: Red Hat Operators + Catalog Source Namespace: openshift-marketplace + Catalog Source Publisher: Red Hat + Channels: + Current CSV: openshift-pipelines-operator-rh.v1.12.0 + Current CSV Desc: + Annotations: + Alm - Examples: [ +..._output omitted_... + Capabilities: Full Lifecycle + Categories: Developer Tools, Integration & Delivery + Certified: false + Description: Red Hat OpenShift Pipelines is a cloud-native CI/CD solution for building pipelines using Tekton concepts which run natively on OpenShift and Kubernetes. +..._output omitted_... + + Display Name: Red Hat OpenShift Pipelines + Install Modes: + Supported: false + Type: OwnNamespace + Supported: false + Type: SingleNamespace + Supported: false + Type: MultiNamespace + Supported: true + Type: AllNamespaces + Keywords: + tektoncd + openshift + build + pipeline + Links: + Name: Tekton Pipeline GitHub Repository + URL: https://github.com/tektoncd/pipeline + Name: Tekton Operator GitHub Repository + URL: https://github.com/tektoncd/operator + Maintainers: + Email: pipelines-extcomm@redhat.com + Name: Red Hat + Maturity: alpha + Provider: + Name: Red Hat + Related Images: +..._output omitted_... +---- + + +4. The Pipelines operator's default namespace is _openshift-operators_, hence neither the namespace nor operator group resources must be created. Create only the subscription resource to start the installation. Following is an example of the Pipelines operator subscription creation. ++ +-- +[subs=+quotes] +---- +$ *cat < pipelines-subs.yaml* +apiVersion: operators.coreos.com/v1alpha1 +kind: Subscription +metadata: + name: openshift-pipelines-operator-rh + namespace: openshift-operators +spec: + channel: latest + installPlanApproval: Automatic + name: openshift-pipelines-operator-rh + source: redhat-operators + sourceNamespace: openshift-marketplace + startingCSV: openshift-pipelines-operator-rh.v1.12.0 +EOF + +$ *oc create -f pipelines-subs.yaml* +---- + +[NOTE] +In case *installPlanApproval* is set to *Manual*, approve the installation first to start it. Refer to the xref:section2.adoc#manual_approval[previous section] for more information. +-- + +== Installation of the Red{nbsp}Hat Openshift Data Science operator + +1. Red{nbsp}Hat Openshift Data Science operator is available through Red Hat Operators catalogue. ++ +[subs=+quotes] +---- +$ *oc get packagemanifest | grep rhods-operator* +rhods-operator Red Hat Operators 3h34m +---- + +2. The operator has a suggested namespace *redhat-ods-operator* to be installed into. However it can be installed into any namespace you choose. ++ +[subs=+quotes] +---- +$ *oc describe packagemanifest rhods-operator* +_...output ommited..._ +operatorframework.io/suggested-namespace: redhat-ods-operator +_...output ommited..._ +---- + +3. Unless you choose to install it into the _openshift-operators_ namespace, create the namespace first. ++ +-- +[subs=+quotes] +---- +$ *cat < rhods-ns.yaml* +apiVersion: v1 +kind: Namespace +metadata: + name: redhat-ods-operator +spec: {} +EOF + +$ *oc create -f rhods-ns.yaml* +namespace/redhat-ods-operator created +---- +-- + +4. Within the new namespace create the *Operator Group* resource. ++ +[subs=+quotes] +---- +$ *cat < rhods-og.yaml* +apiVersion: operators.coreos.com/v1 +kind: OperatorGroup +metadata: + name: redhat-ods-operator + namespace: redhat-ods-operator +spec: {} +EOF + +$ *oc create -f rhods-og.yaml* +operatorgroup.operators.coreos.com/redhat-ods-operator created +---- + +5. Finally create the operator's subscription to start the installation. ++ +-- +[subs=+quotes] +---- +$ *cat < rhods-subs.yaml* +apiVersion: operators.coreos.com/v1alpha1 +kind: Subscription +metadata: + name: rhods-operator + namespace: redhat-ods-operator +spec: + channel: stable + installPlanApproval: Automatic + name: rhods-operator + source: redhat-operators + sourceNamespace: openshift-marketplace + startingCSV: rhods-operator.1.33.0 +EOF + +$ *oc create -f rhods-subs.yaml* +subscription.operators.coreos.com/rhods-operator created +---- + + +[NOTE] +In case the *installPlanApproval* is set to *Manual*, approve the installation first to start it. Refer to the xref:section2.adoc#manual_approval[previous section] for more information. + + +[NOTE] +It may take some time for all the operator's pods to start hence the *Red{nbsp}Hat Openshift Data Science* dashboard may not be available immediately. You can check their status in the *redhat-ods-applications* namespace. Once all pods are running and ready, you can open the dashboard in the Openshift Web Console. + +[subs=+quotes] +---- +$ *oc get pods -n redhat-ods-applications* +NAME READY STATUS RESTARTS AGE +etcd-cc4d875c-8trld 0/1 PodInitializing 0 7s +modelmesh-controller-5749b94578-2j8nv 0/1 Running 0 7s +modelmesh-controller-5749b94578-jcxc7 0/1 ContainerCreating 0 7s +modelmesh-controller-5749b94578-rww94 0/1 ContainerCreating 0 7s +notebook-controller-deployment-685bb8f9d6-6dtbh 0/1 Running 0 29s +odh-model-controller-7d495b56cb-8pnn9 0/1 Running 0 7s +odh-model-controller-7d495b56cb-8xh5h 0/1 Running 0 7s +odh-model-controller-7d495b56cb-kcmqr 0/1 Running 0 7s +odh-notebook-controller-manager-866b7cf859-2wf2j 1/1 Running 0 29s +rhods-dashboard-7bd94f464f-7lvn8 1/2 Running 0 47s +rhods-dashboard-7bd94f464f-hksf6 1/2 Running 0 47s +rhods-dashboard-7bd94f464f-n5rbz 1/2 Running 0 47s +rhods-dashboard-7bd94f464f-pg984 1/2 Running 0 47s +rhods-dashboard-7bd94f464f-xd255 1/2 Running 0 47s +---- +-- \ No newline at end of file diff --git a/package-lock.json b/package-lock.json index 2187397..8073c78 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,5 +1,5 @@ { - "name": "rhods-admin", + "name": "admin2", "lockfileVersion": 3, "requires": true, "packages": { From 1f13b92d5ba0d0f11c4556f0ad0db800d0f4b403 Mon Sep 17 00:00:00 2001 From: Jirka Tesar Date: Mon, 30 Oct 2023 18:38:21 +0100 Subject: [PATCH 13/26] Rhods version 2 installation initial commit --- modules/chapter1/pages/section3.adoc | 250 +++++++++++++++------------ 1 file changed, 142 insertions(+), 108 deletions(-) diff --git a/modules/chapter1/pages/section3.adoc b/modules/chapter1/pages/section3.adoc index f08ae3a..95832ce 100644 --- a/modules/chapter1/pages/section3.adoc +++ b/modules/chapter1/pages/section3.adoc @@ -106,6 +106,148 @@ install-vpgls _operator_name_ Manual #true# <3> <3> Approval has been set and installation starts. -- +== Installation of the Red{nbsp}Hat Openshift Data Science operator + +1. Red{nbsp}Hat Openshift Data Science operator is available through Red Hat Operators catalogue. ++ +[subs=+quotes] +---- +$ *oc get packagemanifest | grep rhods-operator* +rhods-operator Red Hat Operators 3h34m +---- + +2. The operator has a suggested namespace *redhat-ods-operator* to be installed into. However it can be installed into any namespace you choose. ++ +[subs=+quotes] +---- +$ *oc describe packagemanifest rhods-operator* +_...output ommited..._ +operatorframework.io/suggested-namespace: redhat-ods-operator +_...output ommited..._ +---- + +3. Unless you choose to install it into the _openshift-operators_ namespace, create the namespace first. ++ +-- +[subs=+quotes] +---- +$ *cat < rhods-ns.yaml* +apiVersion: v1 +kind: Namespace +metadata: + name: redhat-ods-operator +spec: {} +EOF + +$ *oc create -f rhods-ns.yaml* +namespace/redhat-ods-operator created +---- +-- + +4. Within the new namespace create the *Operator Group* resource. ++ +[subs=+quotes] +---- +$ *cat < rhods-og.yaml* +apiVersion: operators.coreos.com/v1 +kind: OperatorGroup +metadata: + name: redhat-ods-operator + namespace: redhat-ods-operator +spec: {} +EOF + +$ *oc create -f rhods-og.yaml* +operatorgroup.operators.coreos.com/redhat-ods-operator created +---- + +5. Finally create the operator's subscription to start the installation. ++ +-- +[subs=+quotes] +---- +$ *cat < rhods-subs.yaml* +apiVersion: operators.coreos.com/v1alpha1 +kind: Subscription +metadata: + name: rhods-operator + namespace: redhat-ods-operator +spec: + channel: alpha + installPlanApproval: Automatic + name: rhods-operator + source: redhat-operators + sourceNamespace: openshift-marketplace + startingCSV: rhods-operator.2.2.0 +EOF + +$ *oc create -f rhods-subs.yaml* +subscription.operators.coreos.com/rhods-operator created +---- + + +[NOTE] +In case the *installPlanApproval* is set to *Manual*, approve the installation first to start it. Refer to the xref:section2.adoc#manual_approval[previous section] for more information. +-- + +6. Create your Openshift DataScience Cluster ++ +---- +cat < rhods-cluster.yaml +apiVersion: datasciencecluster.opendatahub.io/v1 +kind: DataScienceCluster +metadata: + labels: + app.kubernetes.io/created-by: rhods-operator + app.kubernetes.io/instance: default + app.kubernetes.io/managed-by: kustomize + app.kubernetes.io/name: datasciencecluster + app.kubernetes.io/part-of: rhods-operator + name: mycluster +spec: + components: + codeflare: + managementState: Removed + dashboard: + managementState: Managed + datasciencepipelines: + managementState: Managed + kserve: + managementState: Removed + modelmeshserving: + managementState: Managed + ray: + managementState: Removed + workbenches: + managementState: Managed +EOF + +oc create -f rhods-cluster.yaml +---- + +[NOTE] +It may take some time for all the operator's pods to start hence the *Red{nbsp}Hat Openshift Data Science* dashboard may not be available immediately. You can check their status in the *redhat-ods-applications* namespace. Once all pods are running and ready, you can open the dashboard in the Openshift Web Console. + +[subs=+quotes] +---- +$ *oc get pods -n redhat-ods-applications* +NAME READY STATUS RESTARTS AGE +etcd-cc4d875c-8trld 0/1 PodInitializing 0 7s +modelmesh-controller-5749b94578-2j8nv 0/1 Running 0 7s +modelmesh-controller-5749b94578-jcxc7 0/1 ContainerCreating 0 7s +modelmesh-controller-5749b94578-rww94 0/1 ContainerCreating 0 7s +notebook-controller-deployment-685bb8f9d6-6dtbh 0/1 Running 0 29s +odh-model-controller-7d495b56cb-8pnn9 0/1 Running 0 7s +odh-model-controller-7d495b56cb-8xh5h 0/1 Running 0 7s +odh-model-controller-7d495b56cb-kcmqr 0/1 Running 0 7s +odh-notebook-controller-manager-866b7cf859-2wf2j 1/1 Running 0 29s +rhods-dashboard-7bd94f464f-7lvn8 1/2 Running 0 47s +rhods-dashboard-7bd94f464f-hksf6 1/2 Running 0 47s +rhods-dashboard-7bd94f464f-n5rbz 1/2 Running 0 47s +rhods-dashboard-7bd94f464f-pg984 1/2 Running 0 47s +rhods-dashboard-7bd94f464f-xd255 1/2 Running 0 47s +---- + == Installation of the Red{nbsp}Hat Openshift Pipelines Operator @@ -217,111 +359,3 @@ $ *oc create -f pipelines-subs.yaml* [NOTE] In case *installPlanApproval* is set to *Manual*, approve the installation first to start it. Refer to the xref:section2.adoc#manual_approval[previous section] for more information. -- - -== Installation of the Red{nbsp}Hat Openshift Data Science operator - -1. Red{nbsp}Hat Openshift Data Science operator is available through Red Hat Operators catalogue. -+ -[subs=+quotes] ----- -$ *oc get packagemanifest | grep rhods-operator* -rhods-operator Red Hat Operators 3h34m ----- - -2. The operator has a suggested namespace *redhat-ods-operator* to be installed into. However it can be installed into any namespace you choose. -+ -[subs=+quotes] ----- -$ *oc describe packagemanifest rhods-operator* -_...output ommited..._ -operatorframework.io/suggested-namespace: redhat-ods-operator -_...output ommited..._ ----- - -3. Unless you choose to install it into the _openshift-operators_ namespace, create the namespace first. -+ --- -[subs=+quotes] ----- -$ *cat < rhods-ns.yaml* -apiVersion: v1 -kind: Namespace -metadata: - name: redhat-ods-operator -spec: {} -EOF - -$ *oc create -f rhods-ns.yaml* -namespace/redhat-ods-operator created ----- --- - -4. Within the new namespace create the *Operator Group* resource. -+ -[subs=+quotes] ----- -$ *cat < rhods-og.yaml* -apiVersion: operators.coreos.com/v1 -kind: OperatorGroup -metadata: - name: redhat-ods-operator - namespace: redhat-ods-operator -spec: {} -EOF - -$ *oc create -f rhods-og.yaml* -operatorgroup.operators.coreos.com/redhat-ods-operator created ----- - -5. Finally create the operator's subscription to start the installation. -+ --- -[subs=+quotes] ----- -$ *cat < rhods-subs.yaml* -apiVersion: operators.coreos.com/v1alpha1 -kind: Subscription -metadata: - name: rhods-operator - namespace: redhat-ods-operator -spec: - channel: stable - installPlanApproval: Automatic - name: rhods-operator - source: redhat-operators - sourceNamespace: openshift-marketplace - startingCSV: rhods-operator.1.33.0 -EOF - -$ *oc create -f rhods-subs.yaml* -subscription.operators.coreos.com/rhods-operator created ----- - - -[NOTE] -In case the *installPlanApproval* is set to *Manual*, approve the installation first to start it. Refer to the xref:section2.adoc#manual_approval[previous section] for more information. - - -[NOTE] -It may take some time for all the operator's pods to start hence the *Red{nbsp}Hat Openshift Data Science* dashboard may not be available immediately. You can check their status in the *redhat-ods-applications* namespace. Once all pods are running and ready, you can open the dashboard in the Openshift Web Console. - -[subs=+quotes] ----- -$ *oc get pods -n redhat-ods-applications* -NAME READY STATUS RESTARTS AGE -etcd-cc4d875c-8trld 0/1 PodInitializing 0 7s -modelmesh-controller-5749b94578-2j8nv 0/1 Running 0 7s -modelmesh-controller-5749b94578-jcxc7 0/1 ContainerCreating 0 7s -modelmesh-controller-5749b94578-rww94 0/1 ContainerCreating 0 7s -notebook-controller-deployment-685bb8f9d6-6dtbh 0/1 Running 0 29s -odh-model-controller-7d495b56cb-8pnn9 0/1 Running 0 7s -odh-model-controller-7d495b56cb-8xh5h 0/1 Running 0 7s -odh-model-controller-7d495b56cb-kcmqr 0/1 Running 0 7s -odh-notebook-controller-manager-866b7cf859-2wf2j 1/1 Running 0 29s -rhods-dashboard-7bd94f464f-7lvn8 1/2 Running 0 47s -rhods-dashboard-7bd94f464f-hksf6 1/2 Running 0 47s -rhods-dashboard-7bd94f464f-n5rbz 1/2 Running 0 47s -rhods-dashboard-7bd94f464f-pg984 1/2 Running 0 47s -rhods-dashboard-7bd94f464f-xd255 1/2 Running 0 47s ----- --- \ No newline at end of file From 7bcce9cb2043aee663c4fc112715d3ab2f9e1420 Mon Sep 17 00:00:00 2001 From: Jirka Tesar Date: Mon, 30 Oct 2023 21:32:05 +0100 Subject: [PATCH 14/26] CLI install of RHODSv2 initial commit --- modules/chapter1/pages/section3.adoc | 116 +++++++++++++-------------- 1 file changed, 57 insertions(+), 59 deletions(-) diff --git a/modules/chapter1/pages/section3.adoc b/modules/chapter1/pages/section3.adoc index 95832ce..aeb50ac 100644 --- a/modules/chapter1/pages/section3.adoc +++ b/modules/chapter1/pages/section3.adoc @@ -64,6 +64,7 @@ spec: {} Subscription:: -- [subs=+quotes] +[#subscription] ---- apiVersion: operators.coreos.com/v1alpha1 kind: Subscription @@ -71,20 +72,22 @@ metadata: name: _Subscription_name_ <1> namespace: _operator_namespace_ <2> spec: - channel: _channel_ - installPlanApproval: _Manual/Automatic_ <3> + channel: _channel_ <3> + installPlanApproval: _Manual/Automatic_ <4> name: _Operator_name_ source: _Catalog_source_ sourceNamespace: openshift-marketplace - startingCSV: _Operator_CSV_ + startingCSV: _Operator_CSV_ <5> ---- <1> Name of the subscription resource. <2> Name of the namespace to create the subscription resource in. -<3> installPlanApproval can be either *Automatic* or *Manual*. +<3> Update channel to install the operator from. For more information about finding available channels see this xref:section3.adoc#findchannel[note]. +<4> installPlanApproval can be either *Automatic* or *Manual*. +<5> Staring Cluster Service Version of the operator. For more information about finding available CSVs see this xref:section3.adoc#findchannel[note]. + -- [#manual_approval] - IMPORTANT: When *installPlanApproval* is set to *Manual*, the installation has to be manually approved in order to start. -- @@ -106,6 +109,41 @@ install-vpgls _operator_name_ Manual #true# <3> <3> Approval has been set and installation starts. -- +-- +[#findchannel] +NOTE: It can be little challenging to find available channels and their Cluster Service Versions (CSVs) from the CLI. _JQuery_ is a powerfull tool to filter values from resource manifests. + +The following example lists available channels for the *rhods-operator* operator. +[subs=+quotes] +---- +*$ oc get packagemanifest rhods-operator -o json|jq '.status.channels[].name'* +"beta" +"embedded" +"stable" +"alpha" +---- + +To find available CSVs for a particular channel you can use the following command. + +[subs=+quotes] +---- +*$ oc get packagemanifest rhods-operator -o json| \ + jq '.status.channels[]|select(.name=="#alpha#").entries'* <1> + [ + { + "name": "rhods-operator.2.2.0", <2> + "version": "2.2.0" + }, + { + "name": "rhods-operator.2.1.0", + "version": "2.1.0" + } +] +---- +<1> *alpha* is the name of the channel. +<2> The value of the _name_ attribute is used as a value of the xref:section3.adoc#subscription[startingCSV] attribute in the subscription to select the starting channel. +-- + == Installation of the Red{nbsp}Hat Openshift Data Science operator 1. Red{nbsp}Hat Openshift Data Science operator is available through Red Hat Operators catalogue. @@ -187,7 +225,7 @@ subscription.operators.coreos.com/rhods-operator created [NOTE] -In case the *installPlanApproval* is set to *Manual*, approve the installation first to start it. Refer to the xref:section2.adoc#manual_approval[previous section] for more information. +In case the *installPlanApproval* is set to *Manual*, approve the installation first to start it. Refer to the xref:section3.adoc#manual_approval[previous section] for more information. -- 6. Create your Openshift DataScience Cluster @@ -248,24 +286,19 @@ rhods-dashboard-7bd94f464f-pg984 1/2 Running 0 rhods-dashboard-7bd94f464f-xd255 1/2 Running 0 47s ---- -== Installation of the Red{nbsp}Hat Openshift Pipelines Operator +== Installation of other operators required by Openshift Data Science +You may need to install other operators depending on the components and features of Openshift Data Science you want to use: + +* Red Hat Openshift Pipelines operator +* NVIDIA GPU Operator +* Node Feature Discovery Operator + +The following exercise shows installation of the Red Hat Openshift Pipelines operator. Installation of the two other operators is very similar. -1. The following command lists available catalog sources. -Pipelines operator is available from Red{nbsp}Hat operators catalogue. -+ -[subs=+quotes] ----- -$ *oc get catalogsource -n openshift-marketplace* -NAME DISPLAY TYPE PUBLISHER AGE -certified-operators Certified Operators grpc Red Hat 24h -community-operators Community Operators grpc Red Hat 24h -redhat-marketplace Red Hat Marketplace grpc Red Hat 24h -#redhat-operators Red Hat Operators grpc Red Hat 24h# ----- -2. To install the *Red{nbsp}Hat Openshift Pipelines* operator, locate the `openshift-pipelines-operator-rh` package manifest. +1. To install the *Red{nbsp}Hat Openshift Pipelines* operator, locate the `openshift-pipelines-operator-rh` package manifest. + [subs=+quotes] ---- @@ -273,9 +306,7 @@ $ *oc get packagemanifest | grep pipelines* openshift-pipelines-operator-rh Red Hat Operators 24h ---- - - -3. To get more information about the operator use *oc describe*. This is an optional step. +2. To get more information about the operator use *oc describe*. You need to find available channels and CSVs associated with them so you can use them later when creating the operator's subscription. + [subs=+quotes] ---- @@ -295,45 +326,11 @@ Status: Current CSV Desc: Annotations: Alm - Examples: [ -..._output omitted_... - Capabilities: Full Lifecycle - Categories: Developer Tools, Integration & Delivery - Certified: false - Description: Red Hat OpenShift Pipelines is a cloud-native CI/CD solution for building pipelines using Tekton concepts which run natively on OpenShift and Kubernetes. -..._output omitted_... - - Display Name: Red Hat OpenShift Pipelines - Install Modes: - Supported: false - Type: OwnNamespace - Supported: false - Type: SingleNamespace - Supported: false - Type: MultiNamespace - Supported: true - Type: AllNamespaces - Keywords: - tektoncd - openshift - build - pipeline - Links: - Name: Tekton Pipeline GitHub Repository - URL: https://github.com/tektoncd/pipeline - Name: Tekton Operator GitHub Repository - URL: https://github.com/tektoncd/operator - Maintainers: - Email: pipelines-extcomm@redhat.com - Name: Red Hat - Maturity: alpha - Provider: - Name: Red Hat - Related Images: ..._output omitted_... ---- -4. The Pipelines operator's default namespace is _openshift-operators_, hence neither the namespace nor operator group resources must be created. Create only the subscription resource to start the installation. Following is an example of the Pipelines operator subscription creation. +3. The Pipelines operator's default namespace is _openshift-operators_, hence neither the namespace nor operator group resources must be created. Create only the subscription resource to start the installation. Following is an example of the Pipelines operator subscription creation. + -- [subs=+quotes] @@ -356,6 +353,7 @@ EOF $ *oc create -f pipelines-subs.yaml* ---- + [NOTE] -In case *installPlanApproval* is set to *Manual*, approve the installation first to start it. Refer to the xref:section2.adoc#manual_approval[previous section] for more information. +In case *installPlanApproval* is set to *Manual*, approve the installation first to start it. Refer to the xref:section3.adoc#manual_approval[previous section] for more information. -- From b04b7c251f5c5fd9ed04957a4f7626c8b803e0d2 Mon Sep 17 00:00:00 2001 From: Jirka Tesar Date: Wed, 1 Nov 2023 15:48:31 +0100 Subject: [PATCH 15/26] RHODSv2 operator installation --- modules/chapter1/pages/section3.adoc | 149 +++++++++++---------------- 1 file changed, 60 insertions(+), 89 deletions(-) diff --git a/modules/chapter1/pages/section3.adoc b/modules/chapter1/pages/section3.adoc index aeb50ac..b4b11d2 100644 --- a/modules/chapter1/pages/section3.adoc +++ b/modules/chapter1/pages/section3.adoc @@ -1,6 +1,6 @@ = Installation Using the Command Line Interface -Similarly to the Web Console installation, both *Red{nbsp}Hat Openshift Pipelines* operator and *Red{nbsp}Hat Openshift Data Science* operators have to be installed. +This section covers installation of the *Red{nbsp}Hat Openshift Data Science* from the command line interface. Command line installation requires a bit more understanding of openshift resources than web insterface installation hence before we get to the actual installation we will go over some theory related to the CLI-based operator installation. == Introduction to CLI-based operator installations In OpenShift, the Operator Lifecycle Manager (OLM) helps users install and manage operators and their associated services. @@ -42,7 +42,7 @@ metadata: name: _operator_namespace_ <1> spec: {} ---- -<1> Name of the namespace to install the operator into. +<1> Name of the namespace to create. -- NOTE: Namespace has to be only created if it does not already exist. An operator can be installed into an existing namespace. @@ -63,6 +63,7 @@ spec: {} Subscription:: -- +When a subscription is created the OLM starts the installation of the operator based on details set in the subscription resource. [subs=+quotes] [#subscription] ---- @@ -73,45 +74,23 @@ metadata: namespace: _operator_namespace_ <2> spec: channel: _channel_ <3> - installPlanApproval: _Manual/Automatic_ <4> + startingCSV: _Operator_CSV_ <4> + installPlanApproval: _Manual/Automatic_ <5> name: _Operator_name_ source: _Catalog_source_ sourceNamespace: openshift-marketplace - startingCSV: _Operator_CSV_ <5> ---- <1> Name of the subscription resource. <2> Name of the namespace to create the subscription resource in. -<3> Update channel to install the operator from. For more information about finding available channels see this xref:section3.adoc#findchannel[note]. -<4> installPlanApproval can be either *Automatic* or *Manual*. -<5> Staring Cluster Service Version of the operator. For more information about finding available CSVs see this xref:section3.adoc#findchannel[note]. - +<3> Update channel to install the operator from. For more information about finding available channels see the xref:section3.adoc#findchannel[Finding Update Channels and Cluster Service Versions] section. +<4> Staring Cluster Service Version of the operator. For more information about finding available CSVs see the xref:section3.adoc#findchannel[Finding Update Channels and Cluster Service Versions] section. +<5> installPlanApproval can be either *Automatic* or *Manual*. For more details about manual installation approval se the xref:section3.adoc#manual_approval[Approving Installation Manualy] section -- -[#manual_approval] -IMPORTANT: When *installPlanApproval* is set to *Manual*, the installation has to be manually approved in order to start. - --- -[subs=+quotes] ----- -$ *oc get installplan -n _operator_namespace_* -NAME CSV APPROVAL APPROVED -install-vpgls _operator_csv_ Manual #false# <1> - -$ *oc patch installplan install-vpgls --type merge -p '{"spec":{"approved":true}}' -n _operator_namespace_* -installplan.operators.coreos.com/install-vpgls patched <2> - -$ *oc get installplan -n redhat-ods-operator* -NAME CSV APPROVAL APPROVED -install-vpgls _operator_name_ Manual #true# <3> ----- -<1> Approval has not been set. -<2> The patch command approves the installation. -<3> Approval has been set and installation starts. --- - --- [#findchannel] -NOTE: It can be little challenging to find available channels and their Cluster Service Versions (CSVs) from the CLI. _JQuery_ is a powerfull tool to filter values from resource manifests. +=== Finding Update Channels and Cluster Service Versions +-- +It can be a little challenging to find available channels and their Cluster Service Versions (CSVs) from the command line interface. _JQuery_ is a powerfull tool to filter values from JSON resource manifests. The following example lists available channels for the *rhods-operator* operator. [subs=+quotes] @@ -135,23 +114,46 @@ To find available CSVs for a particular channel you can use the following comman "version": "2.2.0" }, { - "name": "rhods-operator.2.1.0", + "name": "rhods-operator.2.1.0", <2> "version": "2.1.0" } ] ---- <1> *alpha* is the name of the channel. -<2> The value of the _name_ attribute is used as a value of the xref:section3.adoc#subscription[startingCSV] attribute in the subscription to select the starting channel. +<2> The value of the _name_ attribute is used as a value of the xref:section3.adoc#subscription[startingCSV] attribute in the subscription to select the starting version. +-- + +[#manual_approval] +=== Approving Installation Manualy +As a part of the installation process OLM creates an *installplan* resource in the namespace the operator will be installed into . The *installplan* resource contains information about the installation and updates. When the *installPlanApproval* parameter of a subscription is set to *Manual*, the installation has to be manually approved by patching the corresponding *installplan* resource in order to start. +-- +[subs=+quotes] +---- +$ *oc get installplan -n _operator_namespace_* +NAME CSV APPROVAL APPROVED +install-vpgls _operator_csv_ Manual #false# <1> + +$ *oc patch installplan install-vpgls --type merge -p '{"spec":{"approved":true}}' -n _operator_namespace_* +installplan.operators.coreos.com/install-vpgls patched <2> + +$ *oc get installplan -n redhat-ods-operator* +NAME CSV APPROVAL APPROVED +install-vpgls _operator_name_ Manual #true# <3> +---- +<1> Approval has not been set. +<2> The patch command approves the installation. +<3> Approval has been set and installation starts. -- -== Installation of the Red{nbsp}Hat Openshift Data Science operator -1. Red{nbsp}Hat Openshift Data Science operator is available through Red Hat Operators catalogue. +== Demo: Installation of the Red{nbsp}Hat Openshift Data Science operator + +1. Red{nbsp}Hat Openshift Data Science operator is available through Red Hat Operators catalogue. To install it, locate the manifest. + [subs=+quotes] ---- $ *oc get packagemanifest | grep rhods-operator* -rhods-operator Red Hat Operators 3h34m +rhods-operator Red Hat Operators 3h34m ---- 2. The operator has a suggested namespace *redhat-ods-operator* to be installed into. However it can be installed into any namespace you choose. @@ -164,7 +166,7 @@ operatorframework.io/suggested-namespace: redhat-ods-operator _...output ommited..._ ---- -3. Unless you choose to install it into the _openshift-operators_ namespace, create the namespace first. +3. Unless you choose to install it into the _openshift-operators_ namespace, create the *Namespace* and *Operator Group* in it first. + -- [subs=+quotes] @@ -179,13 +181,7 @@ EOF $ *oc create -f rhods-ns.yaml* namespace/redhat-ods-operator created ----- --- -4. Within the new namespace create the *Operator Group* resource. -+ -[subs=+quotes] ----- $ *cat < rhods-og.yaml* apiVersion: operators.coreos.com/v1 kind: OperatorGroup @@ -198,8 +194,8 @@ EOF $ *oc create -f rhods-og.yaml* operatorgroup.operators.coreos.com/redhat-ods-operator created ---- - -5. Finally create the operator's subscription to start the installation. +-- +4. Now create the operator's subscription to start the installation. + -- [subs=+quotes] @@ -209,26 +205,26 @@ apiVersion: operators.coreos.com/v1alpha1 kind: Subscription metadata: name: rhods-operator - namespace: redhat-ods-operator + namespace: redhat-ods-operator <1> spec: - channel: alpha - installPlanApproval: Automatic + channel: alpha <2> + startingCSV: rhods-operator.2.2.0 <3> + installPlanApproval: Automatic <4> name: rhods-operator source: redhat-operators sourceNamespace: openshift-marketplace - startingCSV: rhods-operator.2.2.0 EOF $ *oc create -f rhods-subs.yaml* subscription.operators.coreos.com/rhods-operator created ---- - - -[NOTE] -In case the *installPlanApproval* is set to *Manual*, approve the installation first to start it. Refer to the xref:section3.adoc#manual_approval[previous section] for more information. +<1> The namespace to install the operator into. +<2> The update channel to install the operator from. To find all available channels see the the xref:section3.adoc#findchannel[Finding Update Channels and Cluster Service Versions] section. +<3> The Cluster Service Version (CSV) to install. To find all available CVSs for the selected channel see the the xref:section3.adoc#findchannel[Finding Update Channels and Cluster Service Versions] section. +<4> In case the *installPlanApproval* is set to *Manual*, approve the installation first to start it. Refer to the xref:section3.adoc#manual_approval[Approving Installation Manualy] section for more information. -- -6. Create your Openshift DataScience Cluster +5. Finally create your Openshift DataScience Cluster resource to configure your cluster. + ---- cat < rhods-cluster.yaml @@ -294,9 +290,9 @@ You may need to install other operators depending on the components and features * NVIDIA GPU Operator * Node Feature Discovery Operator -The following exercise shows installation of the Red Hat Openshift Pipelines operator. Installation of the two other operators is very similar. - +The following demo shows installation of the Red Hat Openshift Pipelines operator. Installation of the two other operators is very similar. +=== Demo: Installation of the *Red{nbsp}Hat Openshift Pipelines* operator 1. To install the *Red{nbsp}Hat Openshift Pipelines* operator, locate the `openshift-pipelines-operator-rh` package manifest. + @@ -306,31 +302,7 @@ $ *oc get packagemanifest | grep pipelines* openshift-pipelines-operator-rh Red Hat Operators 24h ---- -2. To get more information about the operator use *oc describe*. You need to find available channels and CSVs associated with them so you can use them later when creating the operator's subscription. -+ -[subs=+quotes] ----- -$ *oc describe packagemanifest openshift-pipelines-operator-rh -n openshift-marketplace* -Name: openshift-pipelines-operator-rh -Namespace: openshift-marketplace -Labels: catalog=redhat-operators -..._output omitted_... -Spec: -Status: - Catalog Source: redhat-operators - Catalog Source Display Name: Red Hat Operators - Catalog Source Namespace: openshift-marketplace - Catalog Source Publisher: Red Hat - Channels: - Current CSV: openshift-pipelines-operator-rh.v1.12.0 - Current CSV Desc: - Annotations: - Alm - Examples: [ -..._output omitted_... ----- - - -3. The Pipelines operator's default namespace is _openshift-operators_, hence neither the namespace nor operator group resources must be created. Create only the subscription resource to start the installation. Following is an example of the Pipelines operator subscription creation. +2. The Pipelines operator's default namespace is _openshift-operators_, hence neither the namespace nor operator group resources must be created. Create only the subscription resource to start the installation. Following is an example of the Pipelines operator subscription creation. + -- [subs=+quotes] @@ -342,18 +314,17 @@ metadata: name: openshift-pipelines-operator-rh namespace: openshift-operators spec: - channel: latest - installPlanApproval: Automatic + channel: latest <1> + startingCSV: openshift-pipelines-operator-rh.v1.12.1 <2> + installPlanApproval: Automatic <3> name: openshift-pipelines-operator-rh source: redhat-operators sourceNamespace: openshift-marketplace - startingCSV: openshift-pipelines-operator-rh.v1.12.0 EOF $ *oc create -f pipelines-subs.yaml* ---- - - -[NOTE] -In case *installPlanApproval* is set to *Manual*, approve the installation first to start it. Refer to the xref:section3.adoc#manual_approval[previous section] for more information. +<1> The update channel to install the operator from. To find all available channels see the xref:section3.adoc#findchannel[Finding Update Channels and Cluster Service Versions] section. +<2> The Cluster Service Version (CSV) to install. To find all available CVSs for the update channel see the xref:section3.adoc#findchannel[Finding Update Channels and Cluster Service Versions] section. +<3> In case the *installPlanApproval* is set to *Manual*, approve the installation first to start it. Refer to the xref:section3.adoc#manual_approval[Approving Installation Manualy] section for more information. -- From 80d1ffb10cb5a7b024b587939e0b2f00d7d8a188 Mon Sep 17 00:00:00 2001 From: Jirka Tesar Date: Wed, 1 Nov 2023 22:24:47 +0100 Subject: [PATCH 16/26] Minor changes --- modules/chapter1/pages/section3.adoc | 69 ++++++++++++++++++++++------ 1 file changed, 54 insertions(+), 15 deletions(-) diff --git a/modules/chapter1/pages/section3.adoc b/modules/chapter1/pages/section3.adoc index b4b11d2..d5b18b4 100644 --- a/modules/chapter1/pages/section3.adoc +++ b/modules/chapter1/pages/section3.adoc @@ -1,6 +1,6 @@ = Installation Using the Command Line Interface -This section covers installation of the *Red{nbsp}Hat Openshift Data Science* from the command line interface. Command line installation requires a bit more understanding of openshift resources than web insterface installation hence before we get to the actual installation we will go over some theory related to the CLI-based operator installation. +This section covers installation of the *Red{nbsp}Hat Openshift Data Science* from the command line interface. Command line installation requires a bit more understanding of openshift resources than the web based installation hence before we get to the actual installation we will go over some theory related to the CLI-based operator installation. == Introduction to CLI-based operator installations In OpenShift, the Operator Lifecycle Manager (OLM) helps users install and manage operators and their associated services. @@ -28,7 +28,7 @@ Cluster service version (CSV):: Each version of an operator has a corresponding CSV. The CSV contains the information that the OLM requires to install the operator. -When installing an operator, an administrator must create only the operator group (unless the target namespace is *openshift-operators* where the operator group resource already exists) and the subscription. Optionally a namespace can be created if it does not exists. +When installing an operator, an administrator must create only the *Operator Group* (unless the target namespace is *openshift-operators* where the *Operator Group* resource already exists) and the *Subscription*. Optionally a *Namespace* can be created if it does not exists. Other resources are created by the OLM. Following are examples of the resources an adminstrator must create. @@ -63,7 +63,7 @@ spec: {} Subscription:: -- -When a subscription is created the OLM starts the installation of the operator based on details set in the subscription resource. +When a *Subscription* resource is created the OLM starts the installation of the operator based on the details set in the *Subscription* resource. [subs=+quotes] [#subscription] ---- @@ -83,14 +83,15 @@ spec: <1> Name of the subscription resource. <2> Name of the namespace to create the subscription resource in. <3> Update channel to install the operator from. For more information about finding available channels see the xref:section3.adoc#findchannel[Finding Update Channels and Cluster Service Versions] section. -<4> Staring Cluster Service Version of the operator. For more information about finding available CSVs see the xref:section3.adoc#findchannel[Finding Update Channels and Cluster Service Versions] section. -<5> installPlanApproval can be either *Automatic* or *Manual*. For more details about manual installation approval se the xref:section3.adoc#manual_approval[Approving Installation Manualy] section +<4> Starting Cluster Service Version of the operator. For more information about finding available CSVs see the xref:section3.adoc#findchannel[Finding Update Channels and Cluster Service Versions] section. +<5> *installPlanApproval* attribute can be either *Automatic* or *Manual*. For more details about manual installation approval se the xref:section3.adoc#manual_approval[Approving Installation Manualy] section. -- [#findchannel] === Finding Update Channels and Cluster Service Versions -- -It can be a little challenging to find available channels and their Cluster Service Versions (CSVs) from the command line interface. _JQuery_ is a powerfull tool to filter values from JSON resource manifests. +Update channels, CSVs and other details about the operator can be found in a resource *packagemanifest*. +It can be however a little challenging to search the *packagemanifest* as it is quite complex. _JQuery_ is a powerfull tool to filter values from JSON resource manifests. The following example lists available channels for the *rhods-operator* operator. [subs=+quotes] @@ -125,7 +126,7 @@ To find available CSVs for a particular channel you can use the following comman [#manual_approval] === Approving Installation Manualy -As a part of the installation process OLM creates an *installplan* resource in the namespace the operator will be installed into . The *installplan* resource contains information about the installation and updates. When the *installPlanApproval* parameter of a subscription is set to *Manual*, the installation has to be manually approved by patching the corresponding *installplan* resource in order to start. +As a part of the installation process OLM creates an *installplan* resource in the namespace the operator will be installed into. The *installplan* resource contains information about the installation and updates. When the *installPlanApproval* parameter of a *Subscription* is set to *Manual*, the installation has to be manually approved by patching the corresponding *installplan* resource in order to start. -- [subs=+quotes] ---- @@ -144,6 +145,35 @@ install-vpgls _operator_name_ Manual #true# <3> <2> The patch command approves the installation. <3> Approval has been set and installation starts. -- +[#installprogress] +=== Checking Installation Progress + +Installation progress can be found in the operator's status. +The following example shows how to find the status of the *Openshift Pipelines* operator installation. +[subs=+quotes] +---- +*$ oc get operators* +NAME AGE +mcg-operator.openshift-storage 7h24m +ocs-operator.openshift-storage 7h24m +odf-csi-addons-operator.openshift-storage 7h24m +odf-operator.openshift-storage 7h25m +#openshift-pipelines-operator-rh.openshift-operators# 20m <1> + +*$ oc get operator openshift-pipelines-operator-rh.openshift-operators -o json| \ +jq '.status.components.refs[]|select(.kind=="ClusterServiceVersion").conditions[]'* + +{ + "lastTransitionTime": "2023-11-01T21:01:25Z", + "lastUpdateTime": "2023-11-01T21:01:26Z", + "message": "installing: waiting for deployment openshift-pipelines-operator to become ready: deployment \"openshift-pipelines-operator\" not available: Deployment does not have minimum availability.", + "reason": "InstallWaiting", <2> + "status": "True", + "type": "Installing" <2> +} +---- +<1> Operator's resource name +<2> Status of the installation. Operator is installed when *reason* reads _InstallSucceeded_ and *type* reads _Succeeded_. == Demo: Installation of the Red{nbsp}Hat Openshift Data Science operator @@ -220,7 +250,7 @@ subscription.operators.coreos.com/rhods-operator created ---- <1> The namespace to install the operator into. <2> The update channel to install the operator from. To find all available channels see the the xref:section3.adoc#findchannel[Finding Update Channels and Cluster Service Versions] section. -<3> The Cluster Service Version (CSV) to install. To find all available CVSs for the selected channel see the the xref:section3.adoc#findchannel[Finding Update Channels and Cluster Service Versions] section. +<3> The Cluster Service Version (CSV) to install. To find all available CSVs for the selected channel see the the xref:section3.adoc#findchannel[Finding Update Channels and Cluster Service Versions] section. <4> In case the *installPlanApproval* is set to *Manual*, approve the installation first to start it. Refer to the xref:section3.adoc#manual_approval[Approving Installation Manualy] section for more information. -- @@ -237,13 +267,13 @@ metadata: app.kubernetes.io/managed-by: kustomize app.kubernetes.io/name: datasciencecluster app.kubernetes.io/part-of: rhods-operator - name: mycluster + name: mycluster <1> spec: components: codeflare: - managementState: Removed + managementState: Removed <2> dashboard: - managementState: Managed + managementState: Managed <3> datasciencepipelines: managementState: Managed kserve: @@ -258,6 +288,11 @@ EOF oc create -f rhods-cluster.yaml ---- +<1> Name of the cluster +<2> Use *Remove* for components that *will not* be installed. +<3> Use *Managed* foc components that will be installed. + +6. You may check the installation progress using the operator's status information. For more information see the xref:section3.adoc#installprogress[Checking Installation Progress] section. [NOTE] It may take some time for all the operator's pods to start hence the *Red{nbsp}Hat Openshift Data Science* dashboard may not be available immediately. You can check their status in the *redhat-ods-applications* namespace. Once all pods are running and ready, you can open the dashboard in the Openshift Web Console. @@ -286,9 +321,10 @@ rhods-dashboard-7bd94f464f-xd255 1/2 Running 0 You may need to install other operators depending on the components and features of Openshift Data Science you want to use: -* Red Hat Openshift Pipelines operator -* NVIDIA GPU Operator -* Node Feature Discovery Operator +* https://www.redhat.com/en/technologies/cloud-computing/openshift/pipelines[Red{nbsp}Hat Openshift Pipelines Operator] +* https://docs.nvidia.com/datacenter/cloud-native/gpu-operator/latest/index.html[NVIDIA GPU Operator] +* https://docs.openshift.com/container-platform/4.13/hardware_enablement/psap-node-feature-discovery-operator.html[Node Feature Discovery Operator] + The following demo shows installation of the Red Hat Openshift Pipelines operator. Installation of the two other operators is very similar. @@ -302,7 +338,7 @@ $ *oc get packagemanifest | grep pipelines* openshift-pipelines-operator-rh Red Hat Operators 24h ---- -2. The Pipelines operator's default namespace is _openshift-operators_, hence neither the namespace nor operator group resources must be created. Create only the subscription resource to start the installation. Following is an example of the Pipelines operator subscription creation. +2. The Pipelines operator's default namespace is _openshift-operators_, hence neither the namespace nor operator group resources must be created. Create only the *Subscription* resource to start the installation. + -- [subs=+quotes] @@ -328,3 +364,6 @@ $ *oc create -f pipelines-subs.yaml* <2> The Cluster Service Version (CSV) to install. To find all available CVSs for the update channel see the xref:section3.adoc#findchannel[Finding Update Channels and Cluster Service Versions] section. <3> In case the *installPlanApproval* is set to *Manual*, approve the installation first to start it. Refer to the xref:section3.adoc#manual_approval[Approving Installation Manualy] section for more information. -- +3. You may check the installation progress using the operator's status information. For more information see the xref:section3.adoc#installprogress[Checking Installation Progress] section. + + From 8d377624b858377b3072598e2b074e11695711fd Mon Sep 17 00:00:00 2001 From: Jirka Tesar Date: Sun, 5 Nov 2023 17:02:24 +0100 Subject: [PATCH 17/26] quick operator status check --- modules/chapter1/pages/section3.adoc | 21 ++++++++++++++++++--- 1 file changed, 18 insertions(+), 3 deletions(-) diff --git a/modules/chapter1/pages/section3.adoc b/modules/chapter1/pages/section3.adoc index d5b18b4..4a2f818 100644 --- a/modules/chapter1/pages/section3.adoc +++ b/modules/chapter1/pages/section3.adoc @@ -149,7 +149,22 @@ install-vpgls _operator_name_ Manual #true# <3> === Checking Installation Progress Installation progress can be found in the operator's status. -The following example shows how to find the status of the *Openshift Pipelines* operator installation. +The following example shows a quick check of the current status of the *Openshift Pipelines* operator. +[subs=+quotes] +---- +*$ oc get olm|grep ^clusterserviceversion|grep openshift-pipelines-operator* +clusterserviceversion.../openshift-pipelines-operator... #Pending# <1> + +*$ oc get olm|grep ^clusterserviceversion|grep openshift-pipelines-operator* +openshift-pipelines-operator* +clusterserviceversion.../openshift-pipelines-operator... #Succeeded# <2> + +---- +<1> The operator is installing. +<2> The operator has been successfully installed. + +If you are interested in more details, you can get the operator's manifest and check it's status attribude. _JQuery_ can be used to filter the status out. + [subs=+quotes] ---- *$ oc get operators* @@ -158,7 +173,7 @@ mcg-operator.openshift-storage 7h24m ocs-operator.openshift-storage 7h24m odf-csi-addons-operator.openshift-storage 7h24m odf-operator.openshift-storage 7h25m -#openshift-pipelines-operator-rh.openshift-operators# 20m <1> +#openshift-pipelines-operator-rh.openshift-operators# 20m <1> *$ oc get operator openshift-pipelines-operator-rh.openshift-operators -o json| \ jq '.status.components.refs[]|select(.kind=="ClusterServiceVersion").conditions[]'* @@ -166,7 +181,7 @@ jq '.status.components.refs[]|select(.kind=="ClusterServiceVersion").conditions[ { "lastTransitionTime": "2023-11-01T21:01:25Z", "lastUpdateTime": "2023-11-01T21:01:26Z", - "message": "installing: waiting for deployment openshift-pipelines-operator to become ready: deployment \"openshift-pipelines-operator\" not available: Deployment does not have minimum availability.", + "message": "installing: waiting for deployment openshift-pipelines-...", "reason": "InstallWaiting", <2> "status": "True", "type": "Installing" <2> From 36832b1a2a1203926372351e6f00eae7b56c7a58 Mon Sep 17 00:00:00 2001 From: Jirka Tesar Date: Tue, 7 Nov 2023 16:53:42 +0100 Subject: [PATCH 18/26] Removed 1st two steps from demo --- modules/chapter1/pages/section3.adoc | 26 ++++---------------------- 1 file changed, 4 insertions(+), 22 deletions(-) diff --git a/modules/chapter1/pages/section3.adoc b/modules/chapter1/pages/section3.adoc index 4a2f818..e03f55f 100644 --- a/modules/chapter1/pages/section3.adoc +++ b/modules/chapter1/pages/section3.adoc @@ -193,25 +193,7 @@ jq '.status.components.refs[]|select(.kind=="ClusterServiceVersion").conditions[ == Demo: Installation of the Red{nbsp}Hat Openshift Data Science operator -1. Red{nbsp}Hat Openshift Data Science operator is available through Red Hat Operators catalogue. To install it, locate the manifest. -+ -[subs=+quotes] ----- -$ *oc get packagemanifest | grep rhods-operator* -rhods-operator Red Hat Operators 3h34m ----- - -2. The operator has a suggested namespace *redhat-ods-operator* to be installed into. However it can be installed into any namespace you choose. -+ -[subs=+quotes] ----- -$ *oc describe packagemanifest rhods-operator* -_...output ommited..._ -operatorframework.io/suggested-namespace: redhat-ods-operator -_...output ommited..._ ----- - -3. Unless you choose to install it into the _openshift-operators_ namespace, create the *Namespace* and *Operator Group* in it first. +. Unless you choose to install it into the _openshift-operators_ namespace, create the *Namespace* and *Operator Group* in it first. + -- [subs=+quotes] @@ -240,7 +222,7 @@ $ *oc create -f rhods-og.yaml* operatorgroup.operators.coreos.com/redhat-ods-operator created ---- -- -4. Now create the operator's subscription to start the installation. +. Now create the operator's subscription to start the installation. + -- [subs=+quotes] @@ -269,7 +251,7 @@ subscription.operators.coreos.com/rhods-operator created <4> In case the *installPlanApproval* is set to *Manual*, approve the installation first to start it. Refer to the xref:section3.adoc#manual_approval[Approving Installation Manualy] section for more information. -- -5. Finally create your Openshift DataScience Cluster resource to configure your cluster. +. Finally create your Openshift DataScience Cluster resource to configure your cluster. + ---- cat < rhods-cluster.yaml @@ -307,7 +289,7 @@ oc create -f rhods-cluster.yaml <2> Use *Remove* for components that *will not* be installed. <3> Use *Managed* foc components that will be installed. -6. You may check the installation progress using the operator's status information. For more information see the xref:section3.adoc#installprogress[Checking Installation Progress] section. +. You may check the installation progress using the operator's status information. For more information see the xref:section3.adoc#installprogress[Checking Installation Progress] section. [NOTE] It may take some time for all the operator's pods to start hence the *Red{nbsp}Hat Openshift Data Science* dashboard may not be available immediately. You can check their status in the *redhat-ods-applications* namespace. Once all pods are running and ready, you can open the dashboard in the Openshift Web Console. From 6db4544eaa21f6ef486e16c2db322241ca4f3e94 Mon Sep 17 00:00:00 2001 From: Jirka Tesar Date: Tue, 7 Nov 2023 16:58:13 +0100 Subject: [PATCH 19/26] annotation and label added to ns creation --- modules/chapter1/pages/section3.adoc | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/modules/chapter1/pages/section3.adoc b/modules/chapter1/pages/section3.adoc index e03f55f..5055d01 100644 --- a/modules/chapter1/pages/section3.adoc +++ b/modules/chapter1/pages/section3.adoc @@ -202,6 +202,10 @@ $ *cat < rhods-ns.yaml* apiVersion: v1 kind: Namespace metadata: + annotations: + openshift.io/display-name: "Red Hat OpenShift Data Science" + labels: + openshift.io/cluster-monitoring: 'true' name: redhat-ods-operator spec: {} EOF From 1d297b285cc7646cd4722e56c6edcdde34cfd32c Mon Sep 17 00:00:00 2001 From: Jirka Tesar Date: Tue, 7 Nov 2023 17:02:12 +0100 Subject: [PATCH 20/26] Removed description of the namespace attribute in subscription --- modules/chapter1/pages/section3.adoc | 15 +++++++-------- 1 file changed, 7 insertions(+), 8 deletions(-) diff --git a/modules/chapter1/pages/section3.adoc b/modules/chapter1/pages/section3.adoc index 5055d01..f856269 100644 --- a/modules/chapter1/pages/section3.adoc +++ b/modules/chapter1/pages/section3.adoc @@ -236,11 +236,11 @@ apiVersion: operators.coreos.com/v1alpha1 kind: Subscription metadata: name: rhods-operator - namespace: redhat-ods-operator <1> + namespace: redhat-ods-operator spec: - channel: alpha <2> - startingCSV: rhods-operator.2.2.0 <3> - installPlanApproval: Automatic <4> + channel: alpha <1> + startingCSV: rhods-operator.2.2.0 <2> + installPlanApproval: Automatic <3> name: rhods-operator source: redhat-operators sourceNamespace: openshift-marketplace @@ -249,10 +249,9 @@ EOF $ *oc create -f rhods-subs.yaml* subscription.operators.coreos.com/rhods-operator created ---- -<1> The namespace to install the operator into. -<2> The update channel to install the operator from. To find all available channels see the the xref:section3.adoc#findchannel[Finding Update Channels and Cluster Service Versions] section. -<3> The Cluster Service Version (CSV) to install. To find all available CSVs for the selected channel see the the xref:section3.adoc#findchannel[Finding Update Channels and Cluster Service Versions] section. -<4> In case the *installPlanApproval* is set to *Manual*, approve the installation first to start it. Refer to the xref:section3.adoc#manual_approval[Approving Installation Manualy] section for more information. +<1> The update channel to install the operator from. To find all available channels see the the xref:section3.adoc#findchannel[Finding Update Channels and Cluster Service Versions] section. +<2> The Cluster Service Version (CSV) to install. To find all available CSVs for the selected channel see the the xref:section3.adoc#findchannel[Finding Update Channels and Cluster Service Versions] section. +<3> In case the *installPlanApproval* is set to *Manual*, approve the installation first to start it. Refer to the xref:section3.adoc#manual_approval[Approving Installation Manualy] section for more information. -- . Finally create your Openshift DataScience Cluster resource to configure your cluster. From 53d6d73f6f69396d7627f4ff49d6dc8f3dc41092 Mon Sep 17 00:00:00 2001 From: Jirka Tesar Date: Tue, 7 Nov 2023 17:03:47 +0100 Subject: [PATCH 21/26] Data science cluster changed to default --- modules/chapter1/pages/section3.adoc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/chapter1/pages/section3.adoc b/modules/chapter1/pages/section3.adoc index f856269..65c1448 100644 --- a/modules/chapter1/pages/section3.adoc +++ b/modules/chapter1/pages/section3.adoc @@ -267,7 +267,7 @@ metadata: app.kubernetes.io/managed-by: kustomize app.kubernetes.io/name: datasciencecluster app.kubernetes.io/part-of: rhods-operator - name: mycluster <1> + name: default <1> spec: components: codeflare: From 2db10f7183e4e8371b5559b8dafea7adff9071b4 Mon Sep 17 00:00:00 2001 From: Jirka Tesar Date: Tue, 7 Nov 2023 17:07:04 +0100 Subject: [PATCH 22/26] StartingCSV attribute removed --- modules/chapter1/pages/section3.adoc | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) diff --git a/modules/chapter1/pages/section3.adoc b/modules/chapter1/pages/section3.adoc index 65c1448..9fdfce4 100644 --- a/modules/chapter1/pages/section3.adoc +++ b/modules/chapter1/pages/section3.adoc @@ -239,8 +239,7 @@ metadata: namespace: redhat-ods-operator spec: channel: alpha <1> - startingCSV: rhods-operator.2.2.0 <2> - installPlanApproval: Automatic <3> + installPlanApproval: Automatic <2> name: rhods-operator source: redhat-operators sourceNamespace: openshift-marketplace @@ -250,8 +249,7 @@ $ *oc create -f rhods-subs.yaml* subscription.operators.coreos.com/rhods-operator created ---- <1> The update channel to install the operator from. To find all available channels see the the xref:section3.adoc#findchannel[Finding Update Channels and Cluster Service Versions] section. -<2> The Cluster Service Version (CSV) to install. To find all available CSVs for the selected channel see the the xref:section3.adoc#findchannel[Finding Update Channels and Cluster Service Versions] section. -<3> In case the *installPlanApproval* is set to *Manual*, approve the installation first to start it. Refer to the xref:section3.adoc#manual_approval[Approving Installation Manualy] section for more information. +<2> In case the *installPlanApproval* is set to *Manual*, approve the installation first to start it. Refer to the xref:section3.adoc#manual_approval[Approving Installation Manualy] section for more information. -- . Finally create your Openshift DataScience Cluster resource to configure your cluster. @@ -351,8 +349,7 @@ metadata: namespace: openshift-operators spec: channel: latest <1> - startingCSV: openshift-pipelines-operator-rh.v1.12.1 <2> - installPlanApproval: Automatic <3> + installPlanApproval: Automatic <2> name: openshift-pipelines-operator-rh source: redhat-operators sourceNamespace: openshift-marketplace @@ -361,8 +358,7 @@ EOF $ *oc create -f pipelines-subs.yaml* ---- <1> The update channel to install the operator from. To find all available channels see the xref:section3.adoc#findchannel[Finding Update Channels and Cluster Service Versions] section. -<2> The Cluster Service Version (CSV) to install. To find all available CVSs for the update channel see the xref:section3.adoc#findchannel[Finding Update Channels and Cluster Service Versions] section. -<3> In case the *installPlanApproval* is set to *Manual*, approve the installation first to start it. Refer to the xref:section3.adoc#manual_approval[Approving Installation Manualy] section for more information. +<2> In case the *installPlanApproval* is set to *Manual*, approve the installation first to start it. Refer to the xref:section3.adoc#manual_approval[Approving Installation Manualy] section for more information. -- 3. You may check the installation progress using the operator's status information. For more information see the xref:section3.adoc#installprogress[Checking Installation Progress] section. From 76a5073767824b606d87eee6e8ef44622775d3f9 Mon Sep 17 00:00:00 2001 From: Jirka Tesar Date: Tue, 7 Nov 2023 17:11:46 +0100 Subject: [PATCH 23/26] Finding available CSVs removed --- modules/chapter1/pages/section3.adoc | 36 ++++++---------------------- 1 file changed, 7 insertions(+), 29 deletions(-) diff --git a/modules/chapter1/pages/section3.adoc b/modules/chapter1/pages/section3.adoc index 9fdfce4..3c5e0cd 100644 --- a/modules/chapter1/pages/section3.adoc +++ b/modules/chapter1/pages/section3.adoc @@ -74,23 +74,21 @@ metadata: namespace: _operator_namespace_ <2> spec: channel: _channel_ <3> - startingCSV: _Operator_CSV_ <4> - installPlanApproval: _Manual/Automatic_ <5> + installPlanApproval: _Manual/Automatic_ <4> name: _Operator_name_ source: _Catalog_source_ sourceNamespace: openshift-marketplace ---- <1> Name of the subscription resource. <2> Name of the namespace to create the subscription resource in. -<3> Update channel to install the operator from. For more information about finding available channels see the xref:section3.adoc#findchannel[Finding Update Channels and Cluster Service Versions] section. -<4> Starting Cluster Service Version of the operator. For more information about finding available CSVs see the xref:section3.adoc#findchannel[Finding Update Channels and Cluster Service Versions] section. -<5> *installPlanApproval* attribute can be either *Automatic* or *Manual*. For more details about manual installation approval se the xref:section3.adoc#manual_approval[Approving Installation Manualy] section. +<3> Update channel to install the operator from. For more information about finding available channels see the xref:section3.adoc#findchannel[Finding Update Channels] section. +<4> *installPlanApproval* attribute can be either *Automatic* or *Manual*. For more details about manual installation approval se the xref:section3.adoc#manual_approval[Approving Installation Manualy] section. -- [#findchannel] -=== Finding Update Channels and Cluster Service Versions +=== Finding Update Channels -- -Update channels, CSVs and other details about the operator can be found in a resource *packagemanifest*. +Update channels and other details about the operator can be found in a resource *packagemanifest*. It can be however a little challenging to search the *packagemanifest* as it is quite complex. _JQuery_ is a powerfull tool to filter values from JSON resource manifests. The following example lists available channels for the *rhods-operator* operator. @@ -102,26 +100,6 @@ The following example lists available channels for the *rhods-operator* operator "stable" "alpha" ---- - -To find available CSVs for a particular channel you can use the following command. - -[subs=+quotes] ----- -*$ oc get packagemanifest rhods-operator -o json| \ - jq '.status.channels[]|select(.name=="#alpha#").entries'* <1> - [ - { - "name": "rhods-operator.2.2.0", <2> - "version": "2.2.0" - }, - { - "name": "rhods-operator.2.1.0", <2> - "version": "2.1.0" - } -] ----- -<1> *alpha* is the name of the channel. -<2> The value of the _name_ attribute is used as a value of the xref:section3.adoc#subscription[startingCSV] attribute in the subscription to select the starting version. -- [#manual_approval] @@ -248,7 +226,7 @@ EOF $ *oc create -f rhods-subs.yaml* subscription.operators.coreos.com/rhods-operator created ---- -<1> The update channel to install the operator from. To find all available channels see the the xref:section3.adoc#findchannel[Finding Update Channels and Cluster Service Versions] section. +<1> The update channel to install the operator from. To find all available channels see the the xref:section3.adoc#findchannel[Finding Update Channels] section. <2> In case the *installPlanApproval* is set to *Manual*, approve the installation first to start it. Refer to the xref:section3.adoc#manual_approval[Approving Installation Manualy] section for more information. -- @@ -357,7 +335,7 @@ EOF $ *oc create -f pipelines-subs.yaml* ---- -<1> The update channel to install the operator from. To find all available channels see the xref:section3.adoc#findchannel[Finding Update Channels and Cluster Service Versions] section. +<1> The update channel to install the operator from. To find all available channels see the xref:section3.adoc#findchannel[Finding Update Channels] section. <2> In case the *installPlanApproval* is set to *Manual*, approve the installation first to start it. Refer to the xref:section3.adoc#manual_approval[Approving Installation Manualy] section for more information. -- 3. You may check the installation progress using the operator's status information. For more information see the xref:section3.adoc#installprogress[Checking Installation Progress] section. From 8fb44dd33eff3f2ab5fea1eaf9c30b3cc1091e79 Mon Sep 17 00:00:00 2001 From: Jirka Tesar Date: Tue, 7 Nov 2023 17:21:32 +0100 Subject: [PATCH 24/26] Typos fixed --- modules/chapter1/pages/section3.adoc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/modules/chapter1/pages/section3.adoc b/modules/chapter1/pages/section3.adoc index 3c5e0cd..5dcd0c7 100644 --- a/modules/chapter1/pages/section3.adoc +++ b/modules/chapter1/pages/section3.adoc @@ -265,8 +265,8 @@ EOF oc create -f rhods-cluster.yaml ---- <1> Name of the cluster -<2> Use *Remove* for components that *will not* be installed. -<3> Use *Managed* foc components that will be installed. +<2> Use *Removed* for components that *will not* be installed. +<3> Use *Managed* for components that will be installed. . You may check the installation progress using the operator's status information. For more information see the xref:section3.adoc#installprogress[Checking Installation Progress] section. From bf500fe778717e557e05cb78774bab9e9a14abbf Mon Sep 17 00:00:00 2001 From: Jirka Tesar Date: Mon, 13 Nov 2023 16:22:15 +0100 Subject: [PATCH 25/26] Reviewes notes implemented --- modules/chapter1/pages/section3.adoc | 178 ++++++++++++++++++--------- 1 file changed, 122 insertions(+), 56 deletions(-) diff --git a/modules/chapter1/pages/section3.adoc b/modules/chapter1/pages/section3.adoc index 5dcd0c7..69a644b 100644 --- a/modules/chapter1/pages/section3.adoc +++ b/modules/chapter1/pages/section3.adoc @@ -160,17 +160,87 @@ jq '.status.components.refs[]|select(.kind=="ClusterServiceVersion").conditions[ "lastTransitionTime": "2023-11-01T21:01:25Z", "lastUpdateTime": "2023-11-01T21:01:26Z", "message": "installing: waiting for deployment openshift-pipelines-...", - "reason": "InstallWaiting", <2> - "status": "True", - "type": "Installing" <2> + "reason": "InstallWaiting", <1> + "status": "True", <2> + "type": "Installing" <3> } ---- -<1> Operator's resource name -<2> Status of the installation. Operator is installed when *reason* reads _InstallSucceeded_ and *type* reads _Succeeded_. +<1> Reason for the condition. +<2> Status of the conditions. +<3> Type of the condition. *Type* _Installing_ together with *status* _True_ indicate that the installation is in progress. *Type* _Succeeded_ together with *status* _True_ and *reason* _InstallSucceeded_ indicate that the installation has been successfull. + +== Installation of Red{nbsp}Hat Openshift Data Science dependencies + +As described in the xref::section1.adoc[General Information about Installation] section you may need to install other operators depending on the components and features of Openshift Data Science you want to use. +In general not installing dependencies before the *Red{nbsp}Hat Openshift Data Science* does not impact the installation process itself, however it may impact initialization of the components that depend on them. Hence it's better to install the dependencies beforehand. + +https://www.redhat.com/en/technologies/cloud-computing/openshift/pipelines[Red{nbsp}Hat Openshift Pipelines Operator]:: +The *Red Hat Openshift Pipelines Operator* is required if you want to install the *Red Hat Openshift Data Science Pipelines* component. +https://docs.nvidia.com/datacenter/cloud-native/gpu-operator/latest/index.html[NVIDIA GPU Operator]:: +The *NVIDIA GPU Operator* is required for GPU support in *Red Hat Openshift Data Science*. +https://docs.openshift.com/container-platform/4.13/hardware_enablement/psap-node-feature-discovery-operator.html[Node Feature Discovery Operator]:: +The *Node Feature Discovery Operator* is a prerequisity for the *NVIDIA GPU Operator*. + + +The following demonstration shows the installation of the https://www.redhat.com/en/technologies/cloud-computing/openshift/pipelines[Red{nbsp}Hat Openshift Pipelines Operator] which is a dependency of the *Data Science Pipelines* component installed by default. Installation of the two other operators is very similar. + +=== Demo: Installation of the *Red{nbsp}Hat Openshift Pipelines* Operator +[WARNING] +If you have already installed the *Red{nbsp}Hat Openshift Data Science* operator during the previous demonstration, you have to uninstall it. Follow the xref:section5.adoc#demo[uninstallation demonstration] first. + +. Log in as a user with the _cluster-admin_ role assigned. ++ +[subs=+quotes] +---- +$ *oc login -u admin -p _password_ https://api...:6443* +Login successful. + +You have access to 74 projects, the list has been suppressed. You can list all projects with 'oc projects' + +Using project "default". +---- + +. The Pipelines operator's default namespace is _openshift-operators_, hence neither the namespace nor operator group resources must be created. Create only the *Subscription* resource to start the installation. ++ +-- +[subs=+quotes] +---- +$ *cat < pipelines-subs.yaml* +apiVersion: operators.coreos.com/v1alpha1 +kind: Subscription +metadata: + name: openshift-pipelines-operator-rh + namespace: openshift-operators +spec: + channel: latest <1> + installPlanApproval: Automatic <2> + name: openshift-pipelines-operator-rh + source: redhat-operators + sourceNamespace: openshift-marketplace +EOF + +$ *oc create -f pipelines-subs.yaml* +---- +<1> The update channel to install the operator from. To find all available channels see the xref:section3.adoc#findchannel[Finding Update Channels] section. +<2> In case the *installPlanApproval* is set to *Manual*, approve the installation first to start it. Refer to the xref:section3.adoc#manual_approval[Approving Installation Manualy] section for more information. +-- +. You may check the installation progress using the operator's status information. For more information see the xref:section3.adoc#installprogress[Checking Installation Progress] section. == Demo: Installation of the Red{nbsp}Hat Openshift Data Science operator +. Log in as a user with the _cluster-admin_ role assigned. ++ +[subs=+quotes] +---- +$ *oc login -u admin -p _password_ https://api...:6443* +Login successful. + +You have access to 74 projects, the list has been suppressed. You can list all projects with 'oc projects' + +Using project "default". +---- + . Unless you choose to install it into the _openshift-operators_ namespace, create the *Namespace* and *Operator Group* in it first. + -- @@ -216,8 +286,8 @@ metadata: name: rhods-operator namespace: redhat-ods-operator spec: - channel: alpha <1> - installPlanApproval: Automatic <2> + channel: embedded <1> + installPlanApproval: Manual <2> name: rhods-operator source: redhat-operators sourceNamespace: openshift-marketplace @@ -227,9 +297,34 @@ $ *oc create -f rhods-subs.yaml* subscription.operators.coreos.com/rhods-operator created ---- <1> The update channel to install the operator from. To find all available channels see the the xref:section3.adoc#findchannel[Finding Update Channels] section. -<2> In case the *installPlanApproval* is set to *Manual*, approve the installation first to start it. Refer to the xref:section3.adoc#manual_approval[Approving Installation Manualy] section for more information. +<2> Installplans will be approved manually. -- +. Approve the installation manually. Refer to the xref:section3.adoc#manual_approval[Approving Installation Manualy] section for more information ++ +[subs=+quotes] +---- +$ *oc get installplan -n redhat-ods-operator* +NAME CSV APPROVAL APPROVED +install-qsrhj rhods-operator.2.1.2 Manual #false# + +$ *oc patch installplan install-qsrhj --type merge -p '{"spec":{"approved":true}}' -n redhat-ods-operator* +installplan.operators.coreos.com/install-qsrhj patched <2> + +$ *oc get installplan -n redhat-ods-operator* +NAME CSV APPROVAL APPROVED +install-qsrhj redhat-ods-operator Manual #true# <3> +---- + +. Check the installation progress using the operator's status information. For more information see the xref:section3.adoc#installprogress[Checking Installation Progress] section. ++ +[subs=+quotes] +---- +*$ oc get olm|grep ^clusterserviceversion|grep redhat-ods-operator* +clusterserviceversion.../openshift-pipelines-operator... #Succeeded# <1> +---- +<1> Make sure that the status is *Succeeded* + . Finally create your Openshift DataScience Cluster resource to configure your cluster. + ---- @@ -268,10 +363,27 @@ oc create -f rhods-cluster.yaml <2> Use *Removed* for components that *will not* be installed. <3> Use *Managed* for components that will be installed. -. You may check the installation progress using the operator's status information. For more information see the xref:section3.adoc#installprogress[Checking Installation Progress] section. +. Now the cluster has been configured and you can check the contition of individual components of the *Red{nbsp}Hat Openshift Data Science*. ++ +[subs=+quotes] +---- +$ *oc get DataScienceCluster default -o json| jq '.status.conditions'* +_...output ommited..._ + { + "lastHeartbeatTime": "2023-11-13T11:04:37Z", + "lastTransitionTime": "2023-11-13T11:04:37Z", + "message": "Component reconciled successfully", + "reason": "ReconcileCompleted", + "status": "True", <1> + "type": "workbenchesReady" <2> + } +_...output ommited..._ +---- +<1> Status of the condition +<2> Type of the condition. *Type* _workbenchesReady_ together with *status* _True_ indicate that the *Workbench* component is ready. [NOTE] -It may take some time for all the operator's pods to start hence the *Red{nbsp}Hat Openshift Data Science* dashboard may not be available immediately. You can check their status in the *redhat-ods-applications* namespace. Once all pods are running and ready, you can open the dashboard in the Openshift Web Console. +It may take some time for all the application pods to start hence the *Red{nbsp}Hat Openshift Data Science* dashboard may not be available immediately. You may check the condition of componens or alternatively you can check the status of the application pods in the *redhat-ods-applications* namespace. Once all pods are running and ready, you can open the dashboard in the Openshift Web Console. [subs=+quotes] ---- @@ -293,51 +405,5 @@ rhods-dashboard-7bd94f464f-pg984 1/2 Running 0 rhods-dashboard-7bd94f464f-xd255 1/2 Running 0 47s ---- -== Installation of other operators required by Openshift Data Science - -You may need to install other operators depending on the components and features of Openshift Data Science you want to use: - -* https://www.redhat.com/en/technologies/cloud-computing/openshift/pipelines[Red{nbsp}Hat Openshift Pipelines Operator] -* https://docs.nvidia.com/datacenter/cloud-native/gpu-operator/latest/index.html[NVIDIA GPU Operator] -* https://docs.openshift.com/container-platform/4.13/hardware_enablement/psap-node-feature-discovery-operator.html[Node Feature Discovery Operator] - - -The following demo shows installation of the Red Hat Openshift Pipelines operator. Installation of the two other operators is very similar. - -=== Demo: Installation of the *Red{nbsp}Hat Openshift Pipelines* operator - -1. To install the *Red{nbsp}Hat Openshift Pipelines* operator, locate the `openshift-pipelines-operator-rh` package manifest. -+ -[subs=+quotes] ----- -$ *oc get packagemanifest | grep pipelines* -openshift-pipelines-operator-rh Red Hat Operators 24h ----- - -2. The Pipelines operator's default namespace is _openshift-operators_, hence neither the namespace nor operator group resources must be created. Create only the *Subscription* resource to start the installation. -+ --- -[subs=+quotes] ----- -$ *cat < pipelines-subs.yaml* -apiVersion: operators.coreos.com/v1alpha1 -kind: Subscription -metadata: - name: openshift-pipelines-operator-rh - namespace: openshift-operators -spec: - channel: latest <1> - installPlanApproval: Automatic <2> - name: openshift-pipelines-operator-rh - source: redhat-operators - sourceNamespace: openshift-marketplace -EOF - -$ *oc create -f pipelines-subs.yaml* ----- -<1> The update channel to install the operator from. To find all available channels see the xref:section3.adoc#findchannel[Finding Update Channels] section. -<2> In case the *installPlanApproval* is set to *Manual*, approve the installation first to start it. Refer to the xref:section3.adoc#manual_approval[Approving Installation Manualy] section for more information. --- -3. You may check the installation progress using the operator's status information. For more information see the xref:section3.adoc#installprogress[Checking Installation Progress] section. From 711bbae943ab86417aa2eda6f30a62df81462ba5 Mon Sep 17 00:00:00 2001 From: Jirka Tesar Date: Mon, 13 Nov 2023 18:19:18 +0100 Subject: [PATCH 26/26] refs to chaper 5 added --- modules/chapter1/pages/section3.adoc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/chapter1/pages/section3.adoc b/modules/chapter1/pages/section3.adoc index 69a644b..a52d490 100644 --- a/modules/chapter1/pages/section3.adoc +++ b/modules/chapter1/pages/section3.adoc @@ -186,7 +186,7 @@ The following demonstration shows the installation of the https://www.redhat.com === Demo: Installation of the *Red{nbsp}Hat Openshift Pipelines* Operator [WARNING] -If you have already installed the *Red{nbsp}Hat Openshift Data Science* operator during the previous demonstration, you have to uninstall it. Follow the xref:section5.adoc#demo[uninstallation demonstration] first. +If you have already installed the *Red{nbsp}Hat Openshift Data Science* operator during the previous demonstration, you have to uninstall it. Follow the xref:section5.adoc#demo-rhods[Uninstalling Red{nbsp}Hat Openshift Data Science] demo to uninstall the *Red{nbsp}Hat Openshift Data Science* operator first and xref:section5.adoc#demo-pipelines[Uninstalling Red{nbsp}Hat Openshift Pipelines] to uninstall *Red{nbsp}Hat Openshift Pipelines* first. . Log in as a user with the _cluster-admin_ role assigned. +