diff options
Diffstat (limited to 'src/com/p4square/grow/frontend/GrowFrontend.java')
-rw-r--r-- | src/com/p4square/grow/frontend/GrowFrontend.java | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/src/com/p4square/grow/frontend/GrowFrontend.java b/src/com/p4square/grow/frontend/GrowFrontend.java index 7283ea1..85b223b 100644 --- a/src/com/p4square/grow/frontend/GrowFrontend.java +++ b/src/com/p4square/grow/frontend/GrowFrontend.java @@ -24,6 +24,19 @@ import net.jesterpm.fmfacade.FreeMarkerPageResource; public class GrowFrontend extends FMFacade { private static Logger cLog = Logger.getLogger(GrowFrontend.class); + @Override + protected Router createRouter() { + Router router = new Router(getContext()); + + final LoginAuthenticator defaultGuard = + new LoginAuthenticator(getContext(), true, "login.html"); + defaultGuard.setNext(FreeMarkerPageResource.class); + router.attachDefault(defaultGuard); + router.attach("/login.html", LoginPageResource.class); + + return router; + } + /** * Stand-alone main for testing. */ |