Skip to content

Commit ff39fa0

Browse files
authored
Feat/update det comp registration (#197)
* Remove component sections from oidc guide. * Fix oidc guide
1 parent 491df38 commit ff39fa0

5 files changed

Lines changed: 47 additions & 118 deletions

File tree

docs/docs/OpenID-Connect-Guide.md

Lines changed: 5 additions & 38 deletions
Original file line numberDiff line numberDiff line change
@@ -26,12 +26,6 @@ with what role. The `OIDC_USER_CLAIM_NAME` and `OIDC_ADMIN_CLAIM_NAME` environme
2626
specify the name of the claim that must be present. The `OIDC_USER_CLAIM_VALUE` and
2727
`OIDC_ADMIN_CLAIM_VALUE` environment variables specify the required value of the claim.
2828

29-
If Workflow Manager is configured to use OIDC, then the component services must also be configured
30-
to use OIDC. The component services will use OIDC if either the `OIDC_JWT_ISSUER_URI` or
31-
`OIDC_ISSUER_URI` environment variables are set on the component service. When a component service
32-
is configured to use OIDC, the `OIDC_CLIENT_ID` and `OIDC_CLIENT_SECRET` environment variables are
33-
used to specify the client ID and secret that will be used during component registration.
34-
3529

3630
### Workflow Manager Environment Variables
3731

@@ -70,22 +64,6 @@ used to specify the client ID and secret that will be used during component regi
7064
[template variables supported by Spring.](https://docs.spring.io/spring-security/reference/servlet/oauth2/client/authorization-grants.html#oauth2Client-auth-code-redirect-uri)
7165

7266

73-
### Component Environment Variables
74-
75-
- `OIDC_JWT_ISSUER_URI` or `OIDC_ISSUER_URI` (Required): URI for the OIDC provider that will be used
76-
to authenticate REST clients. The OIDC configuration endpoint must exist at the value of this
77-
environment variable with `/.well-known/openid-configuration` appended. If both environment
78-
variables are provided, `OIDC_JWT_ISSUER_URI` will be used. If `OIDC_JWT_ISSUER_URI` is set on
79-
Workflow Manager, it should be set to the same value on the component services. If
80-
`OIDC_JWT_ISSUER_URI` is not set on Workflow Manager, `OIDC_ISSUER_URI` should be set to the
81-
same value on Workflow Manager and the component services. When either environment variable is
82-
set, the `WFM_USER` and `WFM_PASSWORD` environment variables are ignored.
83-
- `OIDC_CLIENT_ID` (Required): The client ID that the component service will use when registering
84-
the component with Workflow Manager.
85-
- `OIDC_CLIENT_SECRET` (Required): The client secret that the component service will use when
86-
registering the component with Workflow Manager.
87-
88-
8967
## Example with Keycloak
9068

9169
The following example explains how to test Workflow Manager with Keycloak as the OIDC provider.
@@ -110,9 +88,8 @@ docker run -p 9090:8080 -e KEYCLOAK_ADMIN=admin -e KEYCLOAK_ADMIN_PASSWORD=admin
11088
4\. Create a new realm:
11189

11290
- Create a new realm using the drop down box in upper left that says "master".
113-
- Use the realm name you entered and the gateway IP address from step 1 to set Workflow
114-
Manager and the component services' `OIDC_ISSUER_URI` environment variable to:
115-
`http://<docker-gateway-ip>:9090/realms/<realm-name>`
91+
- Use the realm name you entered and the gateway IP address from step 1 to set Workflow Manager's
92+
`OIDC_ISSUER_URI` environment variable to: `http://<docker-gateway-ip>:9090/realms/<realm-name>`
11693

11794
5\. Create the client that Workflow Manager will use to authenticate users:
11895

@@ -158,30 +135,20 @@ docker run -p 9090:8080 -e KEYCLOAK_ADMIN=admin -e KEYCLOAK_ADMIN_PASSWORD=admin
158135
- After creating a user, set a password in the "Credentials" tab.
159136
- Use the "Role mapping" tab to add the user to one of roles created in step 6.
160137

161-
10\. Add Component Registration REST client:
162-
163-
- Use the "Clients" menu to create a new client.
164-
- Capability config:
165-
- The client needs to have "Client authentication" and "Service accounts roles" enabled.
166-
- Use the "Service account roles" tab to add the client to one of the roles created in step 6.
167-
- Set the component services' `WFM_USER` environment variable to the client ID you entered.
168-
- Set component services' `WFM_PASSWORD` environment variable to the "Client secret" in the
169-
"Credentials" tab.
170-
171-
11\. Add external REST clients:
138+
10\. Add external REST clients:
172139

173140
- Use the "Clients" menu to create a new client.
174141
- Capability config:
175142
- The client needs to have "Client authentication" and "Service accounts roles" enabled.
176143
- Use the "Service account roles" tab to add the client to one of the roles created in step 6.
177144

178-
12\. Start Workflow Manager. When you initially navigate to Workflow Manager, you will be
145+
11\. Start Workflow Manager. When you initially navigate to Workflow Manager, you will be
179146
redirected to the Keycloak log in page. You can log in using the users created in step 9.
180147

181148

182149

183150
### Test REST authentication
184-
Using the Docker gateway IP address from step 1, the client ID and secret from step 11, and the
151+
Using the Docker gateway IP address from step 1, the client ID and secret from step 10, and the
185152
realm name from step 4, run the following command:
186153
```bash
187154
curl -d grant_type=client_credentials -u '<client-id>:<client-secret>' 'http://<docker-gateway-ip>:9090/realms/<realm-name>/protocol/openid-connect/token'

docs/site/OpenID-Connect-Guide/index.html

Lines changed: 5 additions & 38 deletions
Original file line numberDiff line numberDiff line change
@@ -276,11 +276,6 @@ <h2 id="configuration">Configuration</h2>
276276
with what role. The <code>OIDC_USER_CLAIM_NAME</code> and <code>OIDC_ADMIN_CLAIM_NAME</code> environment variables
277277
specify the name of the claim that must be present. The <code>OIDC_USER_CLAIM_VALUE</code> and
278278
<code>OIDC_ADMIN_CLAIM_VALUE</code> environment variables specify the required value of the claim.</p>
279-
<p>If Workflow Manager is configured to use OIDC, then the component services must also be configured
280-
to use OIDC. The component services will use OIDC if either the <code>OIDC_JWT_ISSUER_URI</code> or
281-
<code>OIDC_ISSUER_URI</code> environment variables are set on the component service. When a component service
282-
is configured to use OIDC, the <code>OIDC_CLIENT_ID</code> and <code>OIDC_CLIENT_SECRET</code> environment variables are
283-
used to specify the client ID and secret that will be used during component registration.</p>
284279
<h3 id="workflow-manager-environment-variables">Workflow Manager Environment Variables</h3>
285280
<ul>
286281
<li><code>OIDC_ISSUER_URI</code> (Required): URI for the OIDC provider that will be used to authenticate users
@@ -317,21 +312,6 @@ <h3 id="workflow-manager-environment-variables">Workflow Manager Environment Var
317312
OIDC provider is different from the OIDC provider's public host name. The value can use the
318313
<a href="https://docs.spring.io/spring-security/reference/servlet/oauth2/client/authorization-grants.html#oauth2Client-auth-code-redirect-uri">template variables supported by Spring.</a></li>
319314
</ul>
320-
<h3 id="component-environment-variables">Component Environment Variables</h3>
321-
<ul>
322-
<li><code>OIDC_JWT_ISSUER_URI</code> or <code>OIDC_ISSUER_URI</code> (Required): URI for the OIDC provider that will be used
323-
to authenticate REST clients. The OIDC configuration endpoint must exist at the value of this
324-
environment variable with <code>/.well-known/openid-configuration</code> appended. If both environment
325-
variables are provided, <code>OIDC_JWT_ISSUER_URI</code> will be used. If <code>OIDC_JWT_ISSUER_URI</code> is set on
326-
Workflow Manager, it should be set to the same value on the component services. If
327-
<code>OIDC_JWT_ISSUER_URI</code> is not set on Workflow Manager, <code>OIDC_ISSUER_URI</code> should be set to the
328-
same value on Workflow Manager and the component services. When either environment variable is
329-
set, the <code>WFM_USER</code> and <code>WFM_PASSWORD</code> environment variables are ignored.</li>
330-
<li><code>OIDC_CLIENT_ID</code> (Required): The client ID that the component service will use when registering
331-
the component with Workflow Manager.</li>
332-
<li><code>OIDC_CLIENT_SECRET</code> (Required): The client secret that the component service will use when
333-
registering the component with Workflow Manager.</li>
334-
</ul>
335315
<h2 id="example-with-keycloak">Example with Keycloak</h2>
336316
<p>The following example explains how to test Workflow Manager with Keycloak as the OIDC provider.
337317
It is just an example and should not be used in production.</p>
@@ -349,9 +329,8 @@ <h2 id="example-with-keycloak">Example with Keycloak</h2>
349329
<p>4. Create a new realm:</p>
350330
<ul>
351331
<li>Create a new realm using the drop down box in upper left that says "master".</li>
352-
<li>Use the realm name you entered and the gateway IP address from step 1 to set Workflow
353-
Manager and the component services' <code>OIDC_ISSUER_URI</code> environment variable to:
354-
<code>http://&lt;docker-gateway-ip&gt;:9090/realms/&lt;realm-name&gt;</code></li>
332+
<li>Use the realm name you entered and the gateway IP address from step 1 to set Workflow Manager's
333+
<code>OIDC_ISSUER_URI</code> environment variable to: <code>http://&lt;docker-gateway-ip&gt;:9090/realms/&lt;realm-name&gt;</code></li>
355334
</ul>
356335
<p>5. Create the client that Workflow Manager will use to authenticate users:</p>
357336
<ul>
@@ -402,19 +381,7 @@ <h2 id="example-with-keycloak">Example with Keycloak</h2>
402381
<li>After creating a user, set a password in the "Credentials" tab.</li>
403382
<li>Use the "Role mapping" tab to add the user to one of roles created in step 6.</li>
404383
</ul>
405-
<p>10. Add Component Registration REST client:</p>
406-
<ul>
407-
<li>Use the "Clients" menu to create a new client.</li>
408-
<li>Capability config:<ul>
409-
<li>The client needs to have "Client authentication" and "Service accounts roles" enabled.</li>
410-
<li>Use the "Service account roles" tab to add the client to one of the roles created in step 6.</li>
411-
</ul>
412-
</li>
413-
<li>Set the component services' <code>WFM_USER</code> environment variable to the client ID you entered.</li>
414-
<li>Set component services' <code>WFM_PASSWORD</code> environment variable to the "Client secret" in the
415-
"Credentials" tab.</li>
416-
</ul>
417-
<p>11. Add external REST clients:</p>
384+
<p>10. Add external REST clients:</p>
418385
<ul>
419386
<li>Use the "Clients" menu to create a new client.</li>
420387
<li>Capability config:<ul>
@@ -423,10 +390,10 @@ <h2 id="example-with-keycloak">Example with Keycloak</h2>
423390
</ul>
424391
</li>
425392
</ul>
426-
<p>12. Start Workflow Manager. When you initially navigate to Workflow Manager, you will be
393+
<p>11. Start Workflow Manager. When you initially navigate to Workflow Manager, you will be
427394
redirected to the Keycloak log in page. You can log in using the users created in step 9.</p>
428395
<h3 id="test-rest-authentication">Test REST authentication</h3>
429-
<p>Using the Docker gateway IP address from step 1, the client ID and secret from step 11, and the
396+
<p>Using the Docker gateway IP address from step 1, the client ID and secret from step 10, and the
430397
realm name from step 4, run the following command:</p>
431398
<pre><code class="language-bash">curl -d grant_type=client_credentials -u '&lt;client-id&gt;:&lt;client-secret&gt;' 'http://&lt;docker-gateway-ip&gt;:9090/realms/&lt;realm-name&gt;/protocol/openid-connect/token'
432399
</code></pre>

docs/site/index.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -408,5 +408,5 @@ <h1 id="overview">Overview</h1>
408408

409409
<!--
410410
MkDocs version : 0.17.5
411-
Build Date UTC : 2025-06-27 10:50:29
411+
Build Date UTC : 2025-07-10 17:36:41
412412
-->

0 commit comments

Comments
 (0)