Skip to content

Commit c263201

Browse files
authored
Merge pull request #14085 from bergerhoffer/OSDOCS-176-provision
OSDOCS-176: Added examples of provisioning template applications and …
2 parents 8f58475 + 0689176 commit c263201

11 files changed

+277
-6
lines changed

_topic_map.yml

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -91,8 +91,14 @@ Topics:
9191
File: installing-service-catalog
9292
- Name: Installing the template service broker
9393
File: installing-template-service-broker
94-
- Name: Installing the OpenShift Ansible broker
94+
- Name: Provisioning template applications
95+
File: provisioning-template-application
96+
- Name: Installing the OpenShift Ansible Broker
9597
File: installing-ansible-service-broker
98+
- Name: Configuring the OpenShift Ansible Broker
99+
File: configuring-ansible-service-broker
100+
- Name: Provisioning service bundles
101+
File: provisioning-service-bundle
96102
- Name: Deployments
97103
Dir: deployments
98104
Topics:
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
[id='sb-configuring-asb']
2+
= Configuring the {asb-name}
3+
include::modules/common-attributes.adoc[]
4+
:context: sb-configuring-asb
5+
6+
toc::[]
7+
8+
IMPORTANT: The {asb-name} is deprecated in this release. Equivalent and better functionality is present in the Operator Framework and
9+
Operator Life Cycle Manager (OLM).
10+
11+
// Configuring the {asb-name} Operator
12+
include::modules/sb-configuring-ansible-service-broker.adoc[leveloffset=+1]
13+
14+
// {asb-name} configuration options
15+
include::modules/sb-configuring-ansible-service-broker-options.adoc[leveloffset=+2]

applications/service_brokers/installing-ansible-service-broker.adoc

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,3 +23,6 @@ include::modules/sb-install-asb-operator.adoc[leveloffset=+1]
2323

2424
// Starting the {asb-name}
2525
include::modules/sb-start-asb.adoc[leveloffset=+1]
26+
27+
// {asb-name} configuration options
28+
include::modules/sb-configuring-ansible-service-broker-options.adoc[leveloffset=+2]
Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
[id='sb-provisioning-service-bundles']
2+
= Provisioning service bundles
3+
include::modules/common-attributes.adoc[]
4+
:context: sb-provisioning-service-bundles
5+
6+
toc::[]
7+
8+
// Provisioning service bundles
9+
include::modules/sb-provision-service-bundle.adoc[leveloffset=+1]
Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
[id='sb-provisioning-template-application']
2+
= Provisioning template applications
3+
include::modules/common-attributes.adoc[]
4+
:context: sb-provisioning-template-application
5+
6+
toc::[]
7+
8+
// Provisioning template applications
9+
include::modules/sb-provision-template-application.adoc[leveloffset=+1]

modules/common-attributes.adoc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,4 +9,4 @@
99
:prewrap!:
1010
:op-system-first: Red Hat Enterprise Linux CoreOS (RHCOS)
1111
:op-system: RHCOS
12-
:asb-name: OpenShift Ansible broker
12+
:asb-name: OpenShift Ansible Broker
Lines changed: 95 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,95 @@
1+
// Module included in the following assemblies:
2+
//
3+
// * applications/service_brokers/installing-ansible-service-broker.adoc
4+
// * applications/service_brokers/configuring-ansible-service-broker.adoc
5+
6+
[id='sb-ansible-service-broker-config-options-{context}']
7+
= {asb-name} configuration options
8+
9+
You can set the following options for your {asb-name}.
10+
11+
.{asb-name} configuration options
12+
[options="header",cols="1,2,1a"]
13+
|===
14+
|YAML key |Description |Default value
15+
16+
|`brokerName`
17+
|The name used to identify the broker instance.
18+
|`ansible-service-broker`
19+
20+
|`brokerNamespace`
21+
|The namespace where the broker resides.
22+
|`openshift-ansible-service-broker`
23+
24+
|`brokerImage`
25+
|The fully qualified image used for the broker.
26+
|`docker.io/ansibleplaybookbundle/origin-ansible-service-broker:v3.11`
27+
28+
|`brokerImagePullPolicy`
29+
|The pull policy used for the broker image itself.
30+
|`IfNotPresent`
31+
32+
|`brokerNodeSelector`
33+
|The node selector string used for the broker's deployment.
34+
|`''`
35+
36+
|`registries`
37+
|Expressed as a yaml list of broker registry configs, allowing the user to configure the image registries the broker will discover and source its APBs from.
38+
|See the xref:sb-default-registries-array-{context}[default registries array].
39+
40+
|`logLevel`
41+
|The log level used for the broker's logs.
42+
|`info`
43+
44+
|`apbPullPolicy`
45+
|The pull policy used for APB Pods.
46+
|`IfNotPresent`
47+
48+
|`sandboxRole`
49+
|The role granted to the service account used to execute APBs.
50+
|`admin`
51+
52+
|`keepNamespace`
53+
|Whether the transient namespace created to run the APB is deleted after the conclusion of the APB, regardless of the result.
54+
|`false`
55+
56+
|`keepNamespaceOnError`
57+
|Whether the transient namespace created to run the APB is deleted after the conclusion of the APB, only in the event of an error result.
58+
|`false`
59+
60+
|`bootstrapOnStartup`
61+
|Whether or not the broker should run its bootstrap routine on startup.
62+
|`true`
63+
64+
|`refreshInterval`
65+
|The interval of time between broker bootstraps, refreshing its inventory of APBs.
66+
|`600s`
67+
68+
|`launchApbOnBind`
69+
|_Experimental:_ Toggles the broker executing APBs on bind operations.
70+
|`false`
71+
72+
|`autoEscalate`
73+
|Whether the broker should escalate the permissions of a user while running the APB. This should typically remain `false` since the broker performs originating user authorization to ensure that the user has permissions granted to the APB sandbox.
74+
|`false`
75+
76+
|`outputRequest`
77+
|Whether to output the low level HTTP requests that the broker receives.
78+
|`false`
79+
80+
|===
81+
82+
[id='sb-default-registries-array-{context}']
83+
.Default array for `registries`
84+
[source,yaml]
85+
----
86+
- type: dockerhub
87+
name: dh
88+
url: https://registry.hub.docker.com
89+
org: ansibleplaybookbundle
90+
tag: latest
91+
white_list:
92+
- ".*-apb$"
93+
black_list:
94+
- ".*automation-broker-apb$"
95+
----
Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
// Module included in the following assemblies:
2+
//
3+
// * applications/service_brokers/installing-ansible-service-broker.adoc
4+
5+
[id='sb-configuring-ansible-service-broker-{context}']
6+
= Configuring the {asb-name}
7+
8+
The following procedure customizes the settings for your {asb-name}.
9+
10+
.Prerequisites
11+
12+
* You have installed and started the {asb-name}.
13+
14+
.Procedure
15+
16+
This procedure assumes that you used the `ansible-service-broker` project and name for the {asb-name}.
17+
18+
. Navigate in the web console to *Catalog* -> *Installed Operators* and select the `ansible-service-broker` project.
19+
. Select the *OpenShift Ansible Service Broker Operator*.
20+
. On the *Automation Broker* tab, select `ansible-service-broker`.
21+
. On the *YAML* tab, add or update any {asb-name} configuration options under the `spec` field.
22+
+
23+
For example:
24+
+
25+
----
26+
spec:
27+
keepNamespace: true
28+
sandboxRole: edit
29+
----
30+
+
31+
. Click *Save* to apply these changes.
Lines changed: 48 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,48 @@
1+
// Module included in the following assemblies:
2+
//
3+
// * applications/service_brokers/provisioning-service-bundle.adoc
4+
5+
[id='sb-provision-service-bundle-{context}']
6+
= Provisioning service bundles
7+
8+
The following procedure provisions an example PostgreSQL service bundle (APB)
9+
that was made available by the {asb-name}.
10+
11+
.Prerequisites
12+
13+
* You have enabled the service catalog.
14+
* You have installed and started the {asb-name}.
15+
16+
.Procedure
17+
18+
. Create a project.
19+
.. Navigate in the web console to *Home* -> *Projects* and click
20+
*Create Project*.
21+
.. Enter `test-postgresql-apb` in the *Name* field and click *Create*.
22+
23+
. Create a service instance.
24+
.. Navigate to the *Catalog* -> *Developer Catalog* page.
25+
.. Select the *PostgreSQL (APB)* service bundle and click
26+
*Create Service Instance*.
27+
.. Review the default selections and set any other required fields, and click
28+
*Create*.
29+
.. Go to *Catalog* -> *Provisioned Services* and verify that the
30+
*dh-postgresql-apb* service instance is created and has a status of *Ready*.
31+
+
32+
You can check the progress on the *Home* -> *Events* page. After a few moments,
33+
you should see an event for *dh-postgresql-apb* with the message "The
34+
instance was provisioned successfully".
35+
36+
. Create a service binding.
37+
+
38+
.. From the *Provisioned Services* page, click *dh-postgresql-apb* and click
39+
*Create Service Binding*.
40+
.. Review the default service binding name and click *Create*.
41+
+
42+
This creates a new secret for binding using the name provided.
43+
44+
. Review the secret that was created.
45+
.. Navigate to *Workloads* -> *Secrets* and verify that a secret named
46+
*dh-postgresql-apb* was created.
47+
.. Click *dh-postgresql-apb* and review the key-value pairs in the *Data*
48+
section, which are used for binding to other apps.
Lines changed: 48 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,48 @@
1+
// Module included in the following assemblies:
2+
//
3+
// * applications/service_brokers/provisioning-template-application-bundle.adoc
4+
5+
[id='sb-provision-template-application-{context}']
6+
= Provisioning template applications
7+
8+
The following procedure provisions an example PostgreSQL template application
9+
that was made available by the template service broker.
10+
11+
.Prerequisites
12+
13+
* You have enabled the service catalog.
14+
* You have installed and started the template service broker.
15+
16+
.Procedure
17+
18+
. Create a project.
19+
.. Navigate in the web console to *Home* -> *Projects* and click
20+
*Create Project*.
21+
.. Enter `test-postgresql` in the *Name* field and click *Create*.
22+
23+
. Create a service instance.
24+
.. Navigate to the *Catalog* -> *Developer Catalog* page.
25+
.. Select the *PostgreSQL (Ephemeral)* template application and click
26+
*Create Service Instance*.
27+
.. Review the default selections and set any other required fields, and click
28+
*Create*.
29+
.. Go to *Catalog* -> *Provisioned Services* and verify that the
30+
*postgresql-ephemeral* service instance is created and has a status of *Ready*.
31+
+
32+
You can check the progress on the *Home* -> *Events* page. After a few moments,
33+
you should see an event for *postgresql-ephemeral* with the message "The
34+
instance was provisioned successfully".
35+
36+
. Create a service binding.
37+
+
38+
.. From the *Provisioned Services* page, click *postgresql-ephemeral* and click
39+
*Create Service Binding*.
40+
.. Review the default service binding name and click *Create*.
41+
+
42+
This creates a new secret for binding using the name provided.
43+
44+
. Review the secret that was created.
45+
.. Navigate to *Workloads* -> *Secrets* and verify that a secret named
46+
*postgresql-ephemeral* was created.
47+
.. Click *postgresql-ephemeral* and review the key-value pairs in the *Data*
48+
section, which are used for binding to other apps.

0 commit comments

Comments
 (0)