Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

RHIDP-5374: Consistent mentions to the product custom resource #859

Merged
merged 4 commits into from
Jan 29, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -75,9 +75,9 @@ $ oc create configmap rbac-policies \
--from-file=rbac-conditional-policies.yaml
----

. Update your {product-short} `Backstage` custom resource to mount in the {product-short} filesystem your files from the `rbac-policies` config map:
. Update link:{configuring-book-url}[your `{product-custom-resource-type}` custom resource] to mount in the {product-short} filesystem your files from the `rbac-policies` config map:
+
.`Backstage` Custom resource fragment
.`{product-custom-resource-type}` custom resource fragment
[source,yaml]
----
apiVersion: rhdh.redhat.com/v1alpha3
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ For Operator-based deployment, the approach you use for proxy configuration is b
----


* As a developer, set the proxy information in your custom resource (CR) file as shown in the following example:
* As a developer, set the proxy information in your `{product-custom-resource-type}` CR file as shown in the following example:
pabel-rh marked this conversation as resolved.
Show resolved Hide resolved
+
.Example: Setting proxy variables in a CR file
[source, yaml]
Expand Down
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
[id="configuring-the-deployment"]
= Configuring {product} deployment when using the operator
= Configuring {product} deployment when using the Operator

The {product} operator exposes a `rhdh.redhat.com/v1alpha2` API Version of its Custom Resource Definition (CRD). This CRD exposes a generic `spec.deployment.patch` field, which gives you full control over the {product-short} Deployment resource. This field can be a fragment of the standard `apps.Deployment` Kubernetes object.
The {product} Operator exposes a `rhdh.redhat.com/v1alpha2` API Version of its custom resource (CR). This CR exposes a generic `spec.deployment.patch` field, which gives you full control over the {product-short} Deployment resource. This field can be a fragment of the standard `apps.Deployment` Kubernetes object.

.Procedure

. Create a {product-short} Custom Resource Definition with the following fields:
. Create a `{product-custom-resource-type}` CR with the following fields:

--
.Example
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ EOF
<3> Optional: Provide the value based on the required link:https://www.postgresql.org/docs/15/libpq-connect.html#LIBPQ-CONNECT-SSLMODE[Secure Sockets Layer (SSL) mode].
<4> Optional: Provide the value only if you need a TLS connection for your PostgreSQL instance.

. Create a `{product-custom-resource-type}` custom resource (CR):
. Create your `{product-custom-resource-type}` custom resource (CR):
+
[source,terminal,subs="+attributes,+quotes"]
----
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ done
You can stop port forwarding when the copying of the data is complete. For more information about handling large databases and using the compression tools, see the link:https://www.postgresql.org/docs/current/backup-dump.html#BACKUP-DUMP-LARGE[Handling Large Databases] section on the PostgreSQL website.
====

. Reconfigure your `Backstage` custom resource (CR). For more information, see link:{configuring-book-url}#proc-configuring-postgresql-instance-using-operator_configuring-external-postgresql-databases[Configuring an external PostgreSQL instance using the Operator].
. Reconfigure your `{product-custom-resource-type}` custom resource (CR). For more information, see link:{configuring-book-url}#proc-configuring-postgresql-instance-using-operator_configuring-external-postgresql-databases[Configuring an external PostgreSQL instance using the Operator].
. Check that the following code is present at the end of your `Backstage` CR after reconfiguration:
+
[source,yaml]
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
[id="using-the-operator-to-run-rhdh-with-your-custom-configuration"]
= Using the {product} operator to run {product-short} with your custom configuration

To use the {product-short} operator to run {product} with your custom configuration, create a {product-custom-resource-type} custom resource that:
To use the {product-short} operator to run {product} with your custom configuration, create your {product-custom-resource-type} custom resource (CR) that:

* Mounts files provisioned in your custom config maps.
* Injects environment variables provisioned in your custom secrets.
Expand All @@ -13,7 +13,7 @@ To use the {product-short} operator to run {product} with your custom configurat

.Procedure

. Author your {product-custom-resource-type} custom resource in a `{my-product-cr-name}.yaml` file to use your custom config maps and secrets.
. Author your {product-custom-resource-type} CR in a `{my-product-cr-name}.yaml` file to use your custom config maps and secrets.
pabel-rh marked this conversation as resolved.
Show resolved Hide resolved
+
.Minimal `{my-product-cr-name}.yaml` custom resource example
====
Expand Down Expand Up @@ -78,7 +78,7 @@ spec:
Mandatory fields::

No fields are mandatory.
You can create an empty {product-custom-resource-type} custom resource
You can create an empty {product-custom-resource-type} CR
and run {product-short} with the default configuration.

Optional fields::
Expand Down Expand Up @@ -198,7 +198,7 @@ spec:
`spec.deployment`:::
Optionally, xref:configuring-the-deployment[enter your deployment configuration].

. Apply your {product-custom-resource-type} custom resource to start or update your {product-short} instance.
. Apply your {product-custom-resource-type} CR to start or update your {product-short} instance.
+
[source,terminal,subs="+attributes,+quotes"]
----
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
[id="proc-techdocs-configure-odf-operator_{context}"]
= Making object storage accessible to containers by using the Operator

Creating a `ObjectBucketClaim` Custom Resource (CR) automatically generates both the {product-short} `ObjectBucketClaim` config map and secret. The config map and secret contain `ObjectBucket` access information. Adding the access information to the Operator configuration makes it accessible to the {product-short} container by adding the following environment variables to the container:
Creating a `ObjectBucketClaim` custom resource (CR) automatically generates both the {product-short} `ObjectBucketClaim` config map and secret. The config map and secret contain `ObjectBucket` access information. Adding the access information to the Operator configuration makes it accessible to the {product-short} container by adding the following environment variables to the container:

* `BUCKET_NAME`
* `BUCKET_HOST`
Expand All @@ -21,7 +21,7 @@ These variables are then used in the TechDocs plugin configuration.

.Procedure

* In the {product-short} `Backstage` CR, enter the name of the {product-short} `ObjectBucketClaim` config map as the value for the `spec.application.extraEnvs.configMaps` field and enter the {product-short} `ObjectBucketClaim` secret name as the value for the `spec.application.extraEnvs.secrets` field. For example:
* In your `{product-custom-resource-type}` CR, enter the name of the {product-short} `ObjectBucketClaim` config map as the value for the `spec.application.extraEnvs.configMaps` field and enter the {product-short} `ObjectBucketClaim` secret name as the value for the `spec.application.extraEnvs.secrets` field. For example:
+
[source,yaml]
----
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
[id="proc-config-dynamic-plugins-rhdh-operator_{context}"]
= Installing dynamic plugins with the {product} Operator

You can store the configuration for dynamic plugins in a `ConfigMap` object that your `Backstage` custom resource (CR) can reference.
You can store the configuration for dynamic plugins in a `ConfigMap` object that your `{product-custom-resource-type}` custom resource (CR) can reference.

[NOTE]
====
Expand Down Expand Up @@ -50,7 +50,7 @@ data:
+
image::rhdh/operator-install-2.png[]

. Add the `dynamicPluginsConfigMapName` field to your `Backstage` CR. For example:
. Add the `dynamicPluginsConfigMapName` field to your `{product-custom-resource-type}` CR. For example:
+
[source,yaml]
----
Expand Down
2 changes: 1 addition & 1 deletion modules/dynamic-plugins/proc-topology-configure.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -231,7 +231,7 @@ annotations:

The Red Hat OpenShift Dev Spaces instance is not accessible using the source code editor if the `backstage.io/kubernetes-namespace` annotation is added to the `catalog-info.yaml` file.

To retrieve the instance URL, you require the CheCluster Custom Resource (CR). As the CheCluster CR is created in the openshift-devspaces namespace, the instance URL is not retrieved if the namespace annotation value is not openshift-devspaces.
To retrieve the instance URL, you require the CheCluster custom resource (CR). As the CheCluster CR is created in the openshift-devspaces namespace, the instance URL is not retrieved if the namespace annotation value is not openshift-devspaces.

=== Label selector query annotation
You can write your own custom label, which RHDH uses to find the Kubernetes resources. The label selector takes precedence over the ID annotations:
Expand Down
4 changes: 2 additions & 2 deletions modules/installation/proc-deploy-rhdh-instance-eks.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ kubectl patch serviceaccount default \
----
--

. Create a Custom Resource file using the following template:
. Create your `{product-custom-resource-type}` custom resource using the following template:
+
--
[source,yaml,subs="+attributes,+quotes"]
Expand Down Expand Up @@ -143,7 +143,7 @@ spec:
pathType: Prefix
backend:
service:
# TODO: my-rhdh is the name of your Backstage Custom Resource.
# TODO: my-rhdh is the name of your `{product-custom-resource-type}` custom resource.
# Adjust if you changed it!
name: backstage-my-rhdh
port:
Expand Down
6 changes: 3 additions & 3 deletions modules/installation/proc-deploy-rhdh-instance-gke.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -84,10 +84,10 @@ kubectl patch serviceaccount default \
----
--

. Create a Custom Resource file using the following template:
. Create your `{product-custom-resource-type}` custom resource (CR) file using the following template:
+
--
.Custom Resource fragment
.Custom resource fragment
[source,yaml,subs="attributes+"]
----
apiVersion: rhdh.redhat.com/v1alpha3
Expand Down Expand Up @@ -173,7 +173,7 @@ spec:
pathType: Prefix
backend:
service:
# TODO: my-rhdh is the name of your Backstage Custom Resource.
# TODO: my-rhdh is the name of your `{product-custom-resource-type}` custom resource.
# Adjust if you changed it!
name: backstage-my-rhdh
port:
Expand Down
2 changes: 1 addition & 1 deletion modules/installation/proc-rhdh-deploy-aks-operator.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -128,7 +128,7 @@ stringData:
----
--

. Create a Custom Resource (CR) manifest file named `rhdh.yaml` and include the previously created `rhdh-pull-secret` as follows:
. Create your `{product-custom-resource-type}` custom resource (CR) manifest file named `rhdh.yaml` and include the previously created `rhdh-pull-secret` as follows:
+
--
[source,yaml]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ spec:
- port: http-metrics
path: '/metrics'
----
<1> Replace `<custom_resource_name>` with the name of your {product} CR.
<1> Replace `<custom_resource_name>` with the name of your `{product-custom-resource-type}` custom resource.
<2> Replace `<project_name>` with the name of the {ocp-short} project where your {product} instance is running.

. Apply the `ServiceMonitor` CR by running the following command:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ You can configure integration with your Segment source by using the Operator.

.Procedure

. Add the following YAML code in your `Backstage` custom resource (CR):
. Add the following YAML code in your `{product-custom-resource-type}` custom resource (CR):
+
[source,yaml]
----
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ data:
disabled: true
----

. Set the value of the `dynamicPluginsConfigMapName` parameter to the name of the ConfigMap file in your `Backstage` custom resource:
. Set the value of the `dynamicPluginsConfigMapName` parameter to the name of your `dynamic-plugins-rhdh` config map in your `{product-custom-resource-type}` custom resource:
+
[source,yaml]
----
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ data:
disabled: false
----

. Set the value of the `dynamicPluginsConfigMapName` parameter to the name of the ConfigMap file in your `Backstage` custom resource:
. Set the value of the `dynamicPluginsConfigMapName` parameter to the name of your `dynamic-plugins-rhdh` config map in your `{product-custom-resource-type}` custom resource:
+
[source,yaml]
----
Expand Down