Skip to content

Commit

Permalink
Issue-596: Improve installation of operator guide
Browse files Browse the repository at this point in the history
  • Loading branch information
domhanak committed Apr 22, 2024
1 parent 9a25a3f commit 9638a76
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 39 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -14,11 +14,13 @@
This guide describes how to install the {operator_name} in a Kubernetes or OpenShift cluster. The operator is in an xref:cloud/operator/known-issues.adoc[early development stage] (community only) and has been tested on OpenShift {openshift_version_min}+, Kubernetes {kubernetes_version}+, and link:{minikube_url}[Minikube].

.Prerequisites
* A Kubernetes or OpenShift cluster with admin privileges. Alternatively, you can use Minikube or KIND.
* `kubectl` command-line tool is installed. Otherwise, Minikube provides it.
* A Kubernetes or OpenShift cluster with admin privileges and `kubectl` installed.
* Alternatively, you can use Minikube or KIND in your local environment. See xref:getting-started/preparing-environment.adoc#proc-minimal-local-environment-setup[minimal environment setup] and xref:getting-started/preparing-environment.adoc#proc-starting-cluster-fo-local-development[starting the cluster for local development] guides.
== {product_name} Operator OpenShift installation

=== Install

To install the operator on OpenShift refer to the "link:{openshift_operator_install_url}[Adding Operators to a cluster]" from the OpenShift's documentation.

When searching for the operator in the *Filter by keyword* field, use the word `{operator_openshift_keyword}`. If you're installing from the CLI, the operator's catalog name is `{operator_openshift_catalog}`.
Expand All @@ -29,6 +31,8 @@ To remove the operator on OpenShift refer to the "link:{openshift_operator_unins

== {product_name} Operator Kubernetes installation

=== Install

To install the operator on Kubernetes refer to the "link:{kubernetes_operator_install_url}[How to install an Operator from OperatorHub.io]" from the OperatorHub's documentation.

When link:{operatorhub_url}[searching for the operator in the *Search OperatorHub* field], use the word `{operator_k8s_keyword}`.
Expand All @@ -46,37 +50,11 @@ When searching for the subscription to remove, use the word `{operator_k8s_subsc
If you're running on Kubernetes or OpenShift, it is highly recommended to install the operator from the OperatorHub or OpenShift Console instead since the installation is managed by OLM. Use this method only if you need a snapshot version or you're running locally on Minikube or KIND.
====

=== Prepare a Minikube instance

[NOTE]
====
You can safely skip this section if you're not using Minikube.
====

.Prerequisites
* A machine with at least 8GB memory and a link:https://en.wikipedia.org/wiki/Multi-core_processor[CPU with 8 cores]
* Docker or Podman installed

Run the following command to create a new instance capable of installing the operator and deploy workflows:

[source,shell,subs="attributes+"]
----
minikube start --cpus 4 --memory 4096 --addons registry --addons metrics-server --insecure-registry "10.0.0.0/24" --insecure-registry "localhost:5000"
----

[NOTE]
====
To speed up the build time, you can increase the CPUs and memory options so that your Minikube instance will have more resources. For example, use `--cpus 12 --memory 16384`. If you have already created your Minikube instance, you will need to recreate it for these changes to apply.
====

If Minikube does not work with the default driver, also known as `docker`, you can try to start with the `podman` driver as follows:

.Start Minikube with the Podman driver
[source,shell,subs="attributes+"]
----
minikube start [...] --driver podman
----
* You have set up your environment according to the xref:getting-started/preparing-environment.adoc#proc-minimal-local-environment-setup[minimal environment setup] guide.
* You have the cluster instance up and running. See xref:getting-started/preparing-environment.adoc#proc-starting-cluster-fo-local-development[starting the cluster for local development] guide.

[[proc-install-serverless-operator-snapshot]]
=== Install

To install the {product_name} Operator, you can use the following command:
Expand All @@ -86,11 +64,11 @@ To install the {product_name} Operator, you can use the following command:
----
kubectl create -f https://raw.githubusercontent.com/apache/incubator-kie-kogito-serverless-operator/{operator_version}/operator.yaml
----
You can also specify a version:
Replace `main` with specific version if needed:
----
kubectl create -f https://raw.githubusercontent.com/kiegroup/kogito-serverless-operator/v<version>/operator.yaml
kubectl create -f https://raw.githubusercontent.com/kiegroup/kogito-serverless-operator/<version>/operator.yaml
----
`<version>` could be `1.43.0` for instance.
`<version>` could be `1.44.1` for instance.

You can follow the deployment of the {product_name} Operator:

Expand Down Expand Up @@ -144,7 +122,7 @@ To uninstall the correct version of the operator, first you must get the current
----
kubectl get deployment sonataflow-operator-controller-manager -n sonataflow-operator-system -o jsonpath="{.spec.template.spec.containers[?(@.name=='manager')].image}"
quay.io/kiegroup/kogito-serverless-operator-nightly:1.41.0
quay.io/kiegroup/kogito-serverless-operator-nightly:latest
----

.Uninstalling the operator
Expand All @@ -155,9 +133,7 @@ kubectl delete -f https://raw.githubusercontent.com/apache/incubator-kie-kogito-

[TIP]
====
If you're running a snapshot version, use this URL instead `https://raw.githubusercontent.com/apache/incubator-kie-kogito-serverless-operator/main/operator.yaml`.
The URL should be the same used when installing the operator.
The URL should be the same as the one you used when installing the operator.
====

== Additional resources
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,9 @@
This guide lists the different ways to set up your environment for {product_name} development.
If you are new, start with the minimal one.

.Prerequisites
* A machine with at least 8GB memory and a link:https://en.wikipedia.org/wiki/Multi-core_processor[CPU with 8 cores]
[[proc-minimal-local-environment-setup]]
== Minimal local environment setup

Expand All @@ -14,7 +17,7 @@ start the development on your local machine using our guides.
. Install link:{minikube_start_url}[minikube] or link:{kind_install_url}[kind].
. Install link:{kubectl_install_url}[Kubernetes CLI].
. Install link:{knative_quickstart_url}[Knative using quickstart]. This will also set up Knative Serving and Eventing for you and the cluster should be running.
. xref:cloud/operator/install-serverless-operator.adoc[]
. Install the xref:cloud/operator/install-serverless-operator.adoc#_sonataflow_operator_manual_installation[{product_name} operator manually].
. Install xref:testing-and-troubleshooting/kn-plugin-workflow-overview.adoc[Knative Workflow CLI].
. Install link:{visual_studio_code_url}[Visual Studio Code] with link:{visual_studio_code_swf_extension_url}[our extension] that simplifies development of workflows by providing visual aids and auto-complete features.

Expand Down

0 comments on commit 9638a76

Please sign in to comment.