[keycloak-user] Running into an issue with login.ftl in a custom-made theme

David Gomes gomes at memsql.com
Thu Dec 29 15:01:54 EST 2016


Good day,

I am writing my own Keycloak theme and I am using the Sunrise
<https://github.com/keycloak/keycloak/tree/master/examples/themes/src/main/resources/theme/sunrise>
 example theme as a starting point.

It seems, however, that when I create a sunrise/login/login.ftl file, such
as the one in the base theme, this file doesn't actually get used for
rendering the login form.

I tried to edit the base theme instead and edit its login/login.ftl. It
seems that editing this file has no effect at all. I wrote this in the file
and the login page for the base theme remained exactly the same.

<#import "template.ftl" as layout>
<@layout.registrationLayout displayInfo=social.displayInfo; section>
</@layout.registrationLayout>

Editing CSS, template.tfl and other things works, but editing the
theme/login/login.ftl has no effect at all.

The relevant settings for my Realm are the following:

"registrationAllowed": true,
"registrationEmailAsUsername": true,
"rememberMe": true,
"requiredCredentials": [ "password" ]

In the Keycloak administration console, editing the current theme works
perfectly fine as well, but I'm not being able to edit the actual login
form in any of the example themes. I tried other files such as register.ftl and
editing this one works perfectly fine.
David Gomes
MemSQL


More information about the keycloak-user mailing list