squakez commented on code in PR #4873:
URL: https://github.com/apache/camel-k/pull/4873#discussion_r1389189199


##########
docs/modules/ROOT/pages/installation/knative.adoc:
##########
@@ -0,0 +1,35 @@
+= Knative installation
+
+"https://knative.dev[Knative] is an Open-Source Enterprise-level solution to 
build Serverless and Event Driven Applications. The effort done in this project 
is a great complement to Camel K, which can leverage natively some feature 
offered by Knative. In particular, Camel K will be able to leverage "scale to 
0" (hence, serverless) feature offered by Knative.
+
+NOTE: Knative is an optional configuration. It is not required to run Camel K.
+
+[[install-knative]]
+== Knative roles configuration
+
+Camel K needs to have certain privileges to use the resources used by Knative. 
We have identified them, so, it follows a few configuration that you will need 
to apply in order to make Camel K work with Knative.
+
+NOTE: We assume you have already both the Knative operator and the Camel K 
operator up and running. If not, the first step is to install both operator. 
See the guide on xref:installation/installation.adoc[how to install Camel K] 
and the guide on https://knative.dev/docs/install/[how to install Knative] 
respectively.
+
+Once all the resources are installed in the cluster, you'll need to perform 
the following action:
+
+```bash
+kubectl apply -k 
https://github.com/apache/camel-k/tree/main/config/rbac/knative?ref=v2.1.0
+```
+
+The configuration above is using the released version `2.1.0`. You may want to 
use instead another version or the latest development available on `main` 
branch. Before continuing with the configuration, you need to make sure to know 
which are the namespaces on which the Operator is running and on which your 
Integration is going to run (they could be the same). In order to change it, 
you must perform some customization locally in a similar fashion:
+
+```bash
+git clone https://github.com/apache/camel-k.git
+cd camel-k/config/rbac/knative
+sed -i "s/namespace: placeholder/namespace: $OPERATOR_NAMESPACE/" 
operator-cluster-role-binding-custom-resource-definitions.yaml

Review Comment:
   Basically the operator could be installed in any namespace, ie `global-ns`. 
The service account `camel-k-operator` is already existing on that namespace 
and we must instruct the kustomize procedure that this is the namespaced 
resource we want to provide as a subject for the RoleBinding. I've tried to do 
some test, but I could not make it work without explicitly setting the 
namespace replacement :/



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscr...@camel.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to