Update docs for change of themes and providers directories to reflect 1.9.x refactoring.
This commit is contained in:
parent
14ea988b24
commit
b7f4d52de1
2 changed files with 24 additions and 26 deletions
|
@ -199,7 +199,7 @@ public class MyEventListenerProviderFactory implements EventListenerProviderFact
|
|||
<title>Register a provider using file-system</title>
|
||||
<para>
|
||||
To register your provider simply copy the JAR including the ProviderFactory and Provider classes and the
|
||||
provider configuration file to <literal>standalone/configuration/providers</literal>.
|
||||
provider configuration file to server's root <literal>providers</literal> directory.
|
||||
</para>
|
||||
<para>
|
||||
You can also define multiple provider class-path if you want to create isolated class-loaders. To do this
|
||||
|
|
|
@ -65,8 +65,9 @@
|
|||
<section>
|
||||
<title>Default themes</title>
|
||||
<para>
|
||||
Keycloak comes bundled with default themes in <literal>standalone/configuration/themes</literal>. You should
|
||||
not edit the bundled themes directly. Instead create a new theme that extends a bundled theme.
|
||||
Keycloak comes bundled with default themes in the server's root <literal>themes</literal> directory.
|
||||
You should not edit the bundled themes directly. Instead create a new theme that extends a
|
||||
bundled theme.
|
||||
</para>
|
||||
</section>
|
||||
|
||||
|
@ -101,26 +102,25 @@
|
|||
"cacheTemplates": false,
|
||||
"cacheThemes": false,
|
||||
"folder": {
|
||||
"dir": "${jboss.server.config.dir}/themes"
|
||||
"dir": "${jboss.home.dir}/themes"
|
||||
}
|
||||
},
|
||||
]]></programlisting>
|
||||
Remember to re-enable caching in production as it will significantly impact performance.
|
||||
</para>
|
||||
<para>
|
||||
To create a new theme create a directory for the theme in <literal>.../standalone/configuration/themes</literal>.
|
||||
To create a new theme create a directory for the theme in the server's root <literal>themes</literal>.
|
||||
The name of the directory should be the name of the theme. For example to create a theme called <literal>example-theme</literal>
|
||||
create the directory <literal>.../standalone/configuration/themes/example-theme</literal>. Inside the theme
|
||||
create the directory <literal>themes/example-theme</literal>. Inside the theme
|
||||
directory you then need to create a directory for each of the types your theme is going to provide. For example
|
||||
to add the login type to the <literal>example-theme</literal> theme create the directory
|
||||
<literal>.../standalone/configuration/themes/example-theme/login</literal>.
|
||||
<literal>themes/example-theme/login</literal>.
|
||||
</para>
|
||||
<para>
|
||||
For each type create a file <literal>theme.properties</literal> which allows setting some configuration for
|
||||
the theme, for example what theme it overrides and if it should import any themes. For the above example we
|
||||
want to override the base theme and import common resources from the Keycloak theme. To do this create the
|
||||
file <literal>.../standalone/configuration/themes/example-theme/login/theme.properties</literal> with the
|
||||
following contents:
|
||||
file <literal>themes/example-theme/login/theme.properties</literal> with following contents:
|
||||
<programlisting>[<![CDATA[
|
||||
parent=base
|
||||
import=common/keycloak
|
||||
|
@ -211,10 +211,9 @@ import=common/keycloak
|
|||
Keycloak uses <ulink url="http://freemarker.org">Freemarker Templates</ulink> in order to generate HTML.
|
||||
These templates are defined in <literal>.ftl</literal> files and can be overriden from the base theme.
|
||||
Check out the Freemarker website on how to form a template file. To override the login template for the
|
||||
<literal>example-theme</literal> copy <literal>../standalone/configuration/themes/base/login/login.ftl</literal>
|
||||
to <literal>../standalone/configuration/themes/example-theme/login</literal> and open it in an editor. After
|
||||
the first line (<#import ...>) add <literal><h1>HELLO WORLD!</h1></literal> then refresh
|
||||
the page.
|
||||
<literal>example-theme</literal> copy <literal>themes/base/login/login.ftl</literal> to
|
||||
<literal>themes/example-theme/login</literal> and open it in an editor. After the first line
|
||||
(<#import ...>) add <literal><h1>HELLO WORLD!</h1></literal> then refresh the page.
|
||||
</para>
|
||||
</section>
|
||||
</section>
|
||||
|
@ -222,7 +221,7 @@ import=common/keycloak
|
|||
<section>
|
||||
<title>Deploying themes</title>
|
||||
<para>
|
||||
Themes can be deployed to Keycloak by copying the theme directory to <literal>../standalone/configuration/themes</literal>
|
||||
Themes can be deployed to Keycloak by copying the theme directory to <literal>themes</literal>
|
||||
or it can be deployed as a module. For a single server or during development just copying the theme is fine, but
|
||||
in a cluster or domain it's recommended to deploy as a module.
|
||||
</para>
|
||||
|
@ -273,8 +272,7 @@ import=common/keycloak
|
|||
]]></programlisting>
|
||||
</para>
|
||||
<para>
|
||||
If a theme is deployed to <literal>../standalone/configuration/themes</literal> and as a module the first
|
||||
is used.
|
||||
If a theme is deployed to <literal>themes</literal> and as a module the first is used.
|
||||
</para>
|
||||
</section>
|
||||
|
||||
|
|
Loading…
Reference in a new issue