Skip to content

Commit 8d569bf

Browse files
authored
Merge pull request #46348 from abrennan89/SRVKS-914-2
[SRVKS-914]: Update config structure and cert docs
2 parents 2cf9705 + 0a615e2 commit 8d569bf

7 files changed

+69
-76
lines changed

modules/knative-serving-advanced-config.adoc

Lines changed: 0 additions & 66 deletions
This file was deleted.
Lines changed: 47 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,47 @@
1+
// Module included in the following assemblies
2+
//
3+
// * serverless/admin_guide/serverless-configuration.adoc
4+
5+
:_content-type: PROCEDURE
6+
[id="knative-serving-controller-custom-certs-secrets_{context}"]
7+
= Configuring tag-to-digest resolution by using a secret
8+
9+
If the `controller-custom-certs` spec uses the `Secret` type, the secret is mounted as a secret volume. Knative components consume the secret directly, assuming that the secret has the required certificates.
10+
11+
.Prerequisites
12+
13+
ifdef::openshift-enterprise[]
14+
* You have cluster administrator permissions on {product-title}.
15+
endif::[]
16+
17+
ifdef::openshift-dedicated[]
18+
* You have cluster or dedicated administrator permissions on {product-title}.
19+
endif::[]
20+
21+
* You have installed the {ServerlessOperatorName} and Knative Serving on your cluster.
22+
23+
.Procedure
24+
25+
. Create a secret:
26+
+
27+
.Example command
28+
[source,yaml]
29+
----
30+
$ oc -n knative-serving create secret generic custom-secret --from-file=<secret_name>.crt=<path_to_certificate>
31+
----
32+
33+
. Configure the `controller-custom-certs` spec in the `KnativeServing` custom resource (CR) to use the `Secret` type:
34+
+
35+
.Example KnativeServing CR
36+
[source,yaml]
37+
----
38+
apiVersion: operator.knative.dev/v1alpha1
39+
kind: KnativeServing
40+
metadata:
41+
name: knative-serving
42+
namespace: knative-serving
43+
spec:
44+
controller-custom-certs:
45+
name: custom-secret
46+
type: Secret
47+
----
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
// Module included in the following assemblies
2+
//
3+
// * serverless/admin_guide/serverless-configuration.adoc
4+
5+
:_content-type: CONCEPT
6+
[id="serverless-tag-to-digest-resolution_{context}"]
7+
= Tag-to-digest resolution
8+
9+
If the Knative Serving controller has access to the container registry, Knative Serving resolves image tags to a digest when you create a revision of a service. This is known as _tag-to-digest resolution_, and helps to provide consistency for deployments.
10+
11+
To give the controller access to the container registry on {product-title}, you must create a secret and then configure controller custom certificates. You can configure controller custom certificates by modifying the `controller-custom-certs` spec in the `KnativeServing` custom resource (CR). The secret must reside in the same namespace as the `KnativeServing` CR.
12+
13+
If a secret is not included in the `KnativeServing` CR, this setting defaults to using public key infrastructure (PKI). When using PKI, the cluster-wide certificates are automatically injected into the Knative Serving controller by using the `config-service-sa` config map. The {ServerlessOperatorName} populates the `config-service-sa` config map with cluster-wide certificates and mounts the config map as a volume to the controller.

serverless/admin_guide/serverless-configuration.adoc

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,11 +30,15 @@ include::modules/serverless-kourier-gateway-service-type.adoc[leveloffset=+1]
3030
include::modules/serverless-enabling-pvc-support.adoc[leveloffset=+1]
3131
// enable init containers
3232
include::modules/serverless-admin-init-containers.adoc[leveloffset=+1]
33+
// Tag to digest resolution
34+
include::modules/serverless-tag-to-digest-resolution.adoc[leveloffset=+1]
35+
include::modules/knative-serving-controller-custom-certs-secrets.adoc[leveloffset=+2]
3336

3437
ifdef::openshift-enterprise[]
3538
[id="additional-resources_knative-serving-CR-config"]
3639
[role="_additional-resources"]
3740
== Additional resources
3841
* xref:../../operators/understanding/crds/crd-managing-resources-from-crds.adoc[Managing resources from custom resource definitions]
3942
* xref:../../storage/understanding-persistent-storage.adoc#understanding-persistent-storage[Understanding persistent storage]
43+
* xref:../../networking/configuring-a-custom-pki.adoc[Configuring a custom PKI]
4044
endif::[]

serverless/admin_guide/serverless-ha.adoc

Lines changed: 3 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -6,14 +6,10 @@ include::_attributes/common-attributes.adoc[]
66

77
toc::[]
88

9-
High availability (HA) is a standard feature of Kubernetes APIs that helps to ensure that APIs stay operational if a disruption occurs.
10-
In an HA deployment, if an active controller crashes or is deleted, another controller is available to take over processing of the APIs that were being serviced by the controller that is now unavailable.
9+
High availability (HA) is a standard feature of Kubernetes APIs that helps to ensure that APIs stay operational if a disruption occurs. In an HA deployment, if an active controller crashes or is deleted, another controller is readily available. This controller takes over processing of the APIs that were being serviced by the controller that is now unavailable.
1110

12-
HA in {ServerlessProductName} is available through leader election, which is enabled by default after the Knative Serving or Eventing control plane is installed.
13-
14-
When using a leader election HA pattern, instances of controllers are already scheduled and running inside the cluster before they are required.
15-
These controller instances compete to use a shared resource, known as the leader election lock.
16-
The instance of the controller that has access to the leader election lock resource at any given time is referred to as the leader.
11+
HA in {ServerlessProductName} is available through leader election, which is enabled by default after the Knative Serving or Eventing control plane is installed. When using a leader election HA pattern, instances of controllers are already scheduled and running inside the cluster before they are required.
12+
These controller instances compete to use a shared resource, known as the leader election lock. The instance of the controller that has access to the leader election lock resource at any given time is called the leader.
1713

1814
[id="serverless-ha-configuring-replicas"]
1915
== Configuring high availability replicas on {ServerlessProductName}

serverless/install/installing-knative-eventing.adoc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ toc::[]
88

99
To use event-driven architecture on your cluster, install Knative Eventing. You can create Knative components such as event sources, brokers, and channels and then use them to send events to applications or external systems.
1010

11-
After you install the {ServerlessOperatorName}, install Knative Eventing by using the {product-title} web console. You can install Knative Eventing by using the default settings or configure more advanced settings in the `KnativeEventing` custom resource (CR).
11+
After you install the {ServerlessOperatorName}, you can install Knative Eventing by using the default settings, or configure more advanced settings in the `KnativeEventing` custom resource (CR). For more information about configuration options for the `KnativeEventing` CR, see xref:../../serverless/admin_guide/serverless-configuration.adoc#serverless-configuration[Global configuration].
1212

1313
include::modules/serverless-install-eventing-web-console.adoc[leveloffset=+1]
1414
include::modules/serverless-install-eventing-yaml.adoc[leveloffset=+1]

serverless/install/installing-knative-serving.adoc

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,11 +8,10 @@ toc::[]
88

99
Installing Knative Serving allows you to create Knative services and functions on your cluster. It also allows you to use additional functionality such as autoscaling and networking options for your applications.
1010

11-
After you install the {ServerlessOperatorName}, you can install Knative Serving by using the default settings, or configure more advanced settings in the `KnativeServing` custom resource (CR). For more information about configuration options for the `KnativeServing` CR, see xref:../../serverless/install/installing-knative-serving.adoc#knative-serving-advanced-config_installing-knative-serving[Advanced configuration options].
11+
After you install the {ServerlessOperatorName}, you can install Knative Serving by using the default settings, or configure more advanced settings in the `KnativeServing` custom resource (CR). For more information about configuration options for the `KnativeServing` CR, see xref:../../serverless/admin_guide/serverless-configuration.adoc#serverless-configuration[Global configuration].
1212

1313
include::modules/serverless-install-serving-web-console.adoc[leveloffset=+1]
1414
include::modules/serverless-install-serving-yaml.adoc[leveloffset=+1]
15-
include::modules/knative-serving-advanced-config.adoc[leveloffset=+1]
1615

1716
[id="next-steps_installing-knative-serving"]
1817
== Next steps

0 commit comments

Comments
 (0)