Skip to content

Commit af20f87

Browse files
stevsmitSteven Smith
andauthored
Moves QBO documentation to its own book (#1437)
Co-authored-by: Steven Smith <[email protected]>
1 parent 53ad016 commit af20f87

11 files changed

+108
-86
lines changed
Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
:_mod-docs-content-type: PROCEDURE
2+
[id="creating-quay-integration-custom-resource-cli"]
3+
= Creating the QuayIntegration custom resource using the CLI
4+
5+
Use the following procedure to create the `QuayIntegration` custom resource using the command-line interface.
6+
7+
.Procedure
8+
9+
. Create a `quay-integration.yaml`:
10+
+
11+
----
12+
$ touch quay-integration.yaml
13+
----
14+
15+
. Use the following configuration for a minimal deployment of the `QuayIntegration` custom resource:
16+
+
17+
[source,yaml]
18+
----
19+
apiVersion: quay.redhat.com/v1
20+
kind: QuayIntegration
21+
metadata:
22+
name: example-quayintegration
23+
spec:
24+
clusterID: openshift <1>
25+
credentialsSecret:
26+
namespace: openshift-operators
27+
name: quay-integration<2>
28+
quayHostname: https://<QUAY_URL> <3>
29+
insecureRegistry: false <4>
30+
----
31+
<1> The clusterID value should be unique across the entire ecosystem. This value is required and defaults to `openshift`.
32+
<2> The `credentialsSecret` property refers to the namespace and name of the secret containing the token that was previously created.
33+
<3> Replace the `QUAY_URL` with the hostname of your {productname} instance.
34+
<4> If {productname} is using self signed certificates, set the property to `insecureRegistry: true`.
35+
36+
For a list of all configuration fields, see "QuayIntegration configuration fields".
37+
38+
. Create the `QuayIntegration` custom resource:
39+
+
40+
----
41+
$ oc create -f quay-integration.yaml
42+
----
Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
:_mod-docs-content-type: PROCEDURE
2+
[id="creating-quay-integration-custom-resource-web-console"]
3+
= Creating the QuayIntegration custom resource using the web console
4+
5+
Follow this procedure to create the `QuayIntegration` custom resource using the web console.
6+
7+
.Procedure
8+
9+
. Open the *Administrator* perspective of the web console and navigate to *Operators* -> *Installed Operators*.
10+
11+
. Click *Red Hat {qbo}*.
12+
13+
. On the *Details* page of the {qbo}, click *Create Instance* on the *Quay Integration* API card.
14+
15+
. On the *Create QuayIntegration* page, enter the following required information in either *Form view* or *YAML view*:
16+
+
17+
* *Name*: The name that will refer to the `QuayIntegration` custom resource object.
18+
* *Cluster ID*: The ID associated with this cluster. This value should be unique across the entire ecosystem. Defaults to `openshift` if left unspecified.
19+
* *Credentials secret*: Refers to the namespace and name of the secret containing the token that was previously created.
20+
* *Quay hostname*: The hostname of the Quay registry.
21+
22+
After the `QuayIntegration` custom resource is created, your {ocp} cluster is linked to your {productname} instance. Organizations within your {productname} registry should be created for the related namespace for the {ocp} environment.

modules/proc_creating-ocp-secret-for-oauth-token.adoc

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,20 +2,20 @@
22
[id="creating-ocp-secret-for-oauth-token"]
33
= Creating an {ocp} secret for the OAuth token
44

5-
In this procedure, you will add the previously obtained access token to communicate with your {productname} deployment. The access token will be stored within {ocp} as a secret.
5+
Use the following procedure to add the previously obtained access token to communicate with your {productname} deployment. The access token is stored within {ocp} as a secret.
66

77
.Prerequisites
88

99
* You have set up {productname} and obtained an access token.
1010
* You have deployed the {qbo} on {ocp}.
11-
* An {ocp} 4.6 or greater environment for which you have cluster administrator permissions.
12-
* You have installed the OpenShift CLI (oc).
11+
* You have installed the OpenShift CLI (`oc`).
1312
1413
.Procedure
1514

1615
* Create a secret that contains the access token in the `openshift-operators` namespace:
1716
+
1817
[source,terminal]
1918
----
20-
$ oc create secret -n openshift-operators generic <secret-name> --from-literal=token=<access_token>
19+
$ oc create secret -n openshift-operators generic <secret_name> --from-literal=token=<access_token> <1>
2120
----
21+
<1> Specifies the access token generated during "Setting up Red Hat Quay for the Quay Bridge Operator".
Lines changed: 5 additions & 70 deletions
Original file line numberDiff line numberDiff line change
@@ -1,78 +1,13 @@
1-
:_mod-docs-content-type: PROCEDURE
1+
:_mod-docs-content-type: CONCEPT
22
[id="creating-quay-integration-cr"]
33
= Creating the QuayIntegration custom resource
44

5-
In this procedure, you will create a `QuayIntegration` custom resource, which can be completed from either the web console or from the command line.
5+
Create a `QuayIntegration` custom resource (CR) to connect an {ocp} cluster to a {productname} registry. The `QuayIntegration` CR defines the {productname} hostname, authentication details, and configuration options that the {qbo} uses to synchronize {ocp} projects with {productname} organizations, robot accounts, and other features.
6+
7+
The `QuayIntegration` custom resource can be created by using the {ocp} web console, or from the command-line interface.
68

79
.Prerequisites
810

911
* You have set up {productname} and obtained an access token.
1012
* You have deployed the {qbo} on {ocp}.
11-
* An {ocp} 4.6 or greater environment for which you have cluster administrator permissions.
12-
* Optional: You have installed the OpenShift CLI (oc).
13-
14-
[id="creating-quay-integration-custom-resource-cli"]
15-
== Optional: Creating the QuayIntegration custom resource using the CLI
16-
17-
Follow this procedure to create the `QuayIntegration` custom resource using the command line.
18-
19-
.Procedure
20-
21-
. Create a `quay-integration.yaml`:
22-
+
23-
----
24-
$ touch quay-integration.yaml
25-
----
26-
27-
. Use the following configuration for a minimal deployment of the `QuayIntegration` custom resource:
28-
+
29-
[source,yaml]
30-
----
31-
apiVersion: quay.redhat.com/v1
32-
kind: QuayIntegration
33-
metadata:
34-
name: example-quayintegration
35-
spec:
36-
clusterID: openshift <1>
37-
credentialsSecret:
38-
namespace: openshift-operators
39-
name: quay-integration<2>
40-
quayHostname: https://<QUAY_URL> <3>
41-
insecureRegistry: false <4>
42-
----
43-
<1> The clusterID value should be unique across the entire ecosystem. This value is required and defaults to `openshift`.
44-
<2> The `credentialsSecret` property refers to the namespace and name of the secret containing the token that was previously created.
45-
<3> Replace the `QUAY_URL` with the hostname of your {productname} instance.
46-
<4> If {productname} is using self signed certificates, set the property to `insecureRegistry: true`.
47-
48-
For a list of all configuration fields, see "QuayIntegration configuration fields".
49-
50-
. Create the `QuayIntegration` custom resource:
51-
+
52-
----
53-
$ oc create -f quay-integration.yaml
54-
----
55-
56-
[id="creating-quay-integration-custom-resource-web-console"]
57-
== Optional: Creating the QuayIntegration custom resource using the web console
58-
59-
Follow this procedure to create the `QuayIntegration` custom resource using the web console.
60-
61-
.Procedure
62-
63-
. Open the *Administrator* perspective of the web console and navigate to *Operators* -> *Installed Operators*.
64-
65-
. Click *Red Hat {qbo}*.
66-
67-
. On the *Details* page of the {qbo}, click *Create Instance* on the *Quay Integration* API card.
68-
69-
. On the *Create QuayIntegration* page, enter the following required information in either *Form view* or *YAML view*:
70-
+
71-
* *Name*: The name that will refer to the `QuayIntegration` custom resource object.
72-
* *Cluster ID*: The ID associated with this cluster. This value should be unique across the entire ecosystem. Defaults to `openshift` if left unspecified.
73-
* *Credentials secret*: Refers to the namespace and name of the secret containing the token that was previously created.
74-
* *Quay hostname*: The hostname of the Quay registry.
75-
76-
For a list of all configuration fields, see "link:https://access.redhat.com/documentation/en-us/red_hat_quay/{producty}/html-single/configure_red_hat_quay/index#quay-integration-config-fields[QuayIntegration configuration fields]".
77-
78-
After the `QuayIntegration` custom resource is created, your {ocp} cluster will be linked to your {productname} instance. Organizations within your {productname} registry should be created for the related namespace for the {ocp} environment.
13+
* Optional: You have installed the OpenShift CLI (`oc`).

modules/proc_installing-qbo-on-ocp.adoc

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,19 +2,19 @@
22
[id="installing-qbo-on-ocp"]
33
= Installing the {qbo} on {ocp}
44

5-
In this procedure, you will install the {qbo} on {ocp}.
5+
Use the following procedure to install the {qbo} on {ocp}.
66

7-
.Prerequiites
7+
.Prerequisites
88

9-
* You have set up {productname} and obtained an Access Token.
10-
* An {ocp} 4.6 or greater environment for which you have cluster administrator permissions.
9+
* You have set up {productname} and obtained an OAuth access token.
10+
* You are logged in to {ocp} as a user with administrative privileges.
1111
1212
.Procedure
1313

1414
. Open the *Administrator* perspective of the web console and navigate to *Operators**OperatorHub* on the navigation pane.
1515

1616
. Search for `{qbo}`, click the *{qbo}* title, and then click *Install*.
1717

18-
. Select the version to install, for example, *stable-3.7*, and then click *Install*.
18+
. Select the version to install, for example, *stable-{producty}*, and then click *Install*.
1919

2020
. Click *View Operator* when the installation finishes to go to the {qbo}'s *Details* page. Alternatively, you can click *Installed Operators* → *Red Hat Quay Bridge Operator* to go to the *Details* page.

modules/proc_setting-up-quay-for-qbo.adoc

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,11 @@
22
[id="setting-up-quay-for-qbo"]
33
= Setting up {productname} for the {qbo}
44

5-
In this procedure, you will create a dedicated {productname} organization, and from a new application created within that organization you will generate an OAuth token to be used with the {qbo} in {ocp}.
5+
Use the following procedure to create a dedicated {productname} organization, and then generate an OAuth token to be used with the {qbo} in {ocp} created within that organization.
6+
7+
.Prerequisites
8+
9+
* You are logged in to {productname} as a user with administrative privileges.
610
711
.Procedure
812

@@ -25,6 +29,7 @@ In this procedure, you will create a dedicated {productname} organization, and f
2529
* *Create Repositories*
2630
* *View all visible repositories*
2731
* *Read/Write to any accessible repositories*
32+
* *Super User Access*
2833
* *Administer User*
2934
* *Read User Information*
3035

modules/quay-bridge-operator-test.adoc

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
:_mod-docs-content-type: CONCEPT
22
[id="quay-bridge-operator-test"]
3-
= Using {qbo}
3+
= Using the {qbo}
44

55
Use the following procedure to use the {qbo}.
66

@@ -104,9 +104,7 @@ $ oc new-app --template=httpd-example
104104
Run 'oc status' to view your app.
105105
----
106106
+
107-
After running this command, `BuildConfig`, `ImageStream`, `Service,` `Route`, and `DeploymentConfig` resources are created. When the `ImageStream` resource is created, an associated repository is created in {productname}. For example:
108-
+
109-
image:e2e-demo-httpd-example.png[Example repository]
107+
After running this command, `BuildConfig`, `ImageStream`, `Service,` `Route`, and `DeploymentConfig` resources are created. When the `ImageStream` resource is created, an associated repository is created in {productname}.
110108

111109
. The `ImageChangeTrigger` for the `BuildConfig` triggers a new Build when the Apache HTTPD image, located in the `openshift` namespace, is resolved. As the new Build is created, the `MutatingWebhookConfiguration` automatically rewriters the output to point at {productname}. You can confirm that the build is complete by querying the output field of the build by running the following command:
112110
+

modules/secrets-garbage-collected.adoc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ There is no automatic mechanism to prune secrets in a {productname} Operator dep
88

99
[source,terminal]
1010
----
11-
$ oc delete secret <secret-name>
11+
$ oc delete secret <secret_name>
1212
----
1313

1414

quay_bridge_operator/docinfo.xml

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
<productname>{productname}</productname>
2+
<productnumber>{producty}</productnumber>
3+
<subtitle>{productname}</subtitle>
4+
<abstract>
5+
<para>{qbo}</para>
6+
</abstract>
7+
<authorgroup>
8+
<orgname>Red Hat OpenShift Documentation Team</orgname>
9+
</authorgroup>
10+
<xi:include href="Common_Content/Legal_Notice.xml" xmlns:xi="http://www.w3.org/2001/XInclude" />

modules/conc_quay-bridge-operator.adoc renamed to quay_bridge_operator/master.adoc

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
1-
:_mod-docs-content-type: CONCEPT
1+
include::modules/attributes.adoc[]
2+
23
[id="quay-bridge-operator"]
34
= Integrating {productname} into {ocp} with the {qbo}
45

@@ -14,3 +15,11 @@ The features enabled with the {qbo} include:
1415
* Automatically importing an image stream tag after a build completes.
1516

1617
By using the following procedures, you can enable bi-directional communication between your {productname} and {ocp} clusters.
18+
19+
include::modules/proc_setting-up-quay-for-qbo.adoc[leveloffset=+1]
20+
include::modules/proc_installing-qbo-on-ocp.adoc[leveloffset=+1]
21+
include::modules/proc_creating-ocp-secret-for-oauth-token.adoc[leveloffset=+1]
22+
include::modules/proc_creating-quay-integration-cr.adoc[leveloffset=+1]
23+
include::modules/creating-quay-integration-custom-resource-cli.adoc[leveloffset=+2]
24+
include::modules/creating-quay-integration-custom-resource-web-console.adoc[leveloffset=+2]
25+
include::modules/quay-bridge-operator-test.adoc[leveloffset=+1]

0 commit comments

Comments
 (0)