57 lines
1.4 KiB
Text
57 lines
1.4 KiB
Text
|
|
[id="modifying-app_{context}"]
|
|
= Modifying the {appserver_name} instance
|
|
|
|
The {appserver_name} servlet application requires additional configuration before it is secured by {project_name}.
|
|
|
|
.Prerequisites
|
|
|
|
* You created a client named *vanilla* in the *demo* realm.
|
|
|
|
* You saved a template XML file for this client.
|
|
|
|
.Procedure
|
|
|
|
. Go to the `standalone/configuration` directory in your {appserver_name} root directory.
|
|
. Open the `standalone.xml` file and search for the following text:
|
|
+
|
|
[source,xml]
|
|
----
|
|
<subsystem xmlns="urn:jboss:domain:keycloak:1.1"/>
|
|
----
|
|
|
|
. Change the XML entry from self-closing to using a pair of opening and closing tags as shown here:
|
|
+
|
|
[source,xml]
|
|
----
|
|
<subsystem xmlns="urn:jboss:domain:keycloak:1.1">
|
|
</subsystem>
|
|
----
|
|
|
|
. Paste the contents of the XML template within the `<subsystem>` element, as shown in this example:
|
|
+
|
|
[source,xml]
|
|
----
|
|
<subsystem xmlns="urn:jboss:domain:keycloak:1.1">
|
|
<secure-deployment name="WAR MODULE NAME.war">
|
|
<realm>demo</realm>
|
|
<auth-server-url>http://localhost:8180/auth</auth-server-url>
|
|
<public-client>true</public-client>
|
|
<ssl-required>EXTERNAL</ssl-required>
|
|
<resource>vanilla</resource>
|
|
</secure-deployment>
|
|
</subsystem>
|
|
----
|
|
|
|
. Change `WAR MODULE NAME.war` to `vanilla.war`:
|
|
+
|
|
[source,xml]
|
|
----
|
|
<subsystem xmlns="urn:jboss:domain:keycloak:1.1">
|
|
<secure-deployment name="vanilla.war">
|
|
...
|
|
</subsystem>
|
|
----
|
|
|
|
. Reboot the application server.
|
|
|