Skip to content

Commit

Permalink
Add new requirement for some objects to have part-of label
Browse files Browse the repository at this point in the history
Signed-off-by: Mykola Morhun <mmorhun@redhat.com>
  • Loading branch information
mmorhun committed Nov 23, 2021
1 parent 208dfee commit 06f12c0
Show file tree
Hide file tree
Showing 4 changed files with 29 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -16,26 +16,28 @@
$ {orch-cli} create namespace {prod-namespace}
----

. Create a secret to store {prod-short} server database credentials:
. Create a secret to store {prod-short} server database credentials and label it:
+
[subs="+quotes,attributes"]
----
$ {orch-cli} create secret generic <server-database-credentials> \ <1>
--from-literal=user=<database-user> \ <2>
--from-literal=password=<database-password> \ <3>
-n {prod-namespace}
$ {orch-cli} label secret <server-database-credentials> app.kubernetes.io/part-of=che.eclipse.org -n {prod-namespace}
----
<1> Secret name to store {prod-short} server database credentials
<2> {prod-short} server database username
<3> {prod-short} server database password

. Create a secret to store {identity-provider} database credentials:
. Create a secret to store {identity-provider} database credentials and label it:
+
[subs="+quotes,attributes"]
----
$ {orch-cli} create secret generic <identity-database-credentials> \ <1>
--from-literal=password=<identity-database-password> \ <2>
-n {prod-namespace}
$ {orch-cli} label secret _<identity-database-credentials>_ app.kubernetes.io/part-of=che.eclipse.org -n {prod-namespace}
----
<1> Secret name to store {identity-provider} database credentials
<2> {identity-provider} database password
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,14 +25,15 @@ IMPORTANT: Ask a DNS provider to point the custom hostname to the cluster ingres
$ {orch-cli} create {orch-namespace} {prod-namespace}
----

. Create a TLS secret:
. Create a TLS secret and label it:
+
[subs="+quotes,attributes"]
----
$ {orch-cli} create secret TLS $\{secret} \ <1>
--key $\{key_file} \ <2>
--cert $\{cert_file} \ <3>
-n {prod-namespace}
$ {orch-cli} label secret $\{secret} app.kubernetes.io/part-of=che.eclipse.org -n {prod-namespace}
----
<1> The TLS secret name
<2> A file with the private key
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -58,11 +58,18 @@ endif::[]
====
ifeval::["{project-context}" == "che"]
.For {prod-short} deployed using Operators
.For {prod-short} deployed using Operator
endif::[]
Update the `gitSelfSignedCert` property. To do that, execute:
. Add required labels to the ConfigMap:
+
[subs="+quotes,attributes"]
----
$ {orch-cli} label configmap che-git-self-signed-cert app.kubernetes.io/part-of=che.eclipse.org -n {prod-namespace}
----
. Update the `gitSelfSignedCert` property. To do that, execute:
+
[subs="+attributes"]
----
$ {orch-cli} patch checluster/{prod-checluster} -n {prod-namespace} --type=json \
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,13 @@ $ {orch-cli} create configmap ca-certs --from-file=__<certificate-file-path>__ -
+
To apply more than one certificate, add another `--from-file=_<certificate-file-path>_` option to the above command.

. Add required labels to the ConfigMap:
+
[subs="+attributes,+quotes"]
----
$ {orch-cli} label configmap ca-certs app.kubernetes.io/part-of=che.eclipse.org -n {prod-namespace}
----

. During the installation process, when creating the `CheCluster` custom resource, configure the right name for the created ConfigMap.
+
====
Expand Down Expand Up @@ -123,6 +130,13 @@ $ {orch-cli} create configmap __<config-map-name>__ --from-file=__<certificate-f
+
To apply more than one certificate, add another `--from-file=_<certificate-file-path>_` option to the above command.

. Add required labels to the ConfigMap:
+
[subs="+attributes,+quotes"]
----
$ {orch-cli} label configmap ca-certs app.kubernetes.io/part-of=che.eclipse.org -n {prod-namespace}
----

. Configure the {prod-short} installation to use the ConfigMap:
+
====
Expand Down

0 comments on commit 06f12c0

Please sign in to comment.