The new error is similar to this https://groups.google.com/a/apereo.org/forum/#!topic/cas-user/dPf36An-qyU
Check that full thread, CAS is expecting theme.properties file. if you are editing heavily then this is obvious in CAS, and Yes CAS documentation needs a reincarnation! indeed :-). On Saturday, May 16, 2020 at 9:33:17 PM UTC+5:30, CanaryJudge wrote: > > This can’t be this difficult. I am actually very surprised that it has > taken this long to configure such an important project. If I ever get this > working I am going to have to put together some instructions for a newbie > as the current ones leave a lot to be desired in the form of examples :-) > > Anyway, my current configuration for /etc/cas/config/cas.properties > … > spring.thymeleaf.prefix[0]=file:/etc/cas/templates > cas.view.templatePrefixes[0]=file:/etc/cas/templates > ... > > Error in debug: > > 2020-05-16 15:58:29,329 DEBUG > [org.apereo.cas.services.web.RegisteredServiceThemeResolver] - <Can't find > bundle for base name foo, locale en_US> > java.util.MissingResourceException: Can't find bundle for base name epc, > locale en_US > at > java.util.ResourceBundle.throwMissingResourceException(ResourceBundle.java:2055) > > ~[?:?] > at > java.util.ResourceBundle.getBundleImpl(ResourceBundle.java:1689) ~[?:?] > at > java.util.ResourceBundle.getBundleImpl(ResourceBundle.java:1593) ~[?:?] > at java.util.ResourceBundle.getBundle(ResourceBundle.java:1284) > ~[?:?] > at > org.apereo.cas.services.web.RegisteredServiceThemeResolver$CasThemeResourceBundleMessageSource.doGetBundle(RegisteredServiceThemeResolver.java:190) > > ~[cas-server-support-themes-core-6.2.0-SNAPSHOT.jar:6.2.0-SNAPSHOT] > at > org.apereo.cas.services.web.RegisteredServiceThemeResolver.determineThemeNameToChoose(RegisteredServiceThemeResolver.java:145) > > ~[cas-server-support-themes-core-6.2.0-SNAPSHOT.jar:6.2.0-SNAPSHOT] > at > org.apereo.cas.services.web.RegisteredServiceThemeResolver.resolveThemeName(RegisteredServiceThemeResolver.java:103) > > ~[cas-server-support-themes-core-6.2.0-SNAPSHOT.jar:6.2.0-SNAPSHOT] > at > org.apereo.cas.services.web.ChainingThemeResolver.resolveThemeName(ChainingThemeResolver.java:42) > > ~[cas-server-support-themes-core-6.2.0-SNAPSHOT.jar:6.2.0-SNAPSHOT] > at > org.springframework.web.servlet.support.RequestContextUtils.getTheme(RequestContextUtils.java:217) > > ~[spring-webmvc-5.2.5.RELEASE.jar:5.2.5.RELEASE] > at > org.springframework.web.servlet.support.RequestContext.getTheme(RequestContext.java:398) > > ~[spring-webmvc-5.2.5.RELEASE.jar:5.2.5.RELEASE] > at > org.thymeleaf.spring5.context.webmvc.SpringWebMvcThymeleafRequestContext.getTheme(SpringWebMvcThymeleafRequestContext.java:211) > > ~[thymeleaf-spring5-3.0.11.RELEASE.jar:3.0.11.RELEASE] > > No better clues there :-/ > > > On May 16, 2020, at 11:06 AM, Root <[email protected] <javascript:>> > wrote: > > > Ok, at the end of the error it says "cannot be located" so might be > path/permission issue?, make sure > > /etc/cas/templates/ is accessible by tomcat, also instead of > "file:///etc/cas/templates" try "file:/etc/cas/templates" > > IF you are still getting errors, enable DEBUG mode in log4j2.xml, you may get > more info. > > > > > On Saturday, May 16, 2020 at 7:50:48 PM UTC+5:30, CanaryJudge wrote: >> >> Just changed the value to what you specified below and got the same error: >> >> 2020-05-16 14:04:15,369 WARN >> [org.apereo.cas.services.web.RegisteredServiceThemeResolver] - <Custom >> theme [foo] for service >> [AbstractRegisteredService(serviceId=^(http|https)://.*, name=HTTP and >> HTTPS, theme=epc, informationUrl=null, privacyUrl=null, responseType=null, >> id=0, description=This service definition authorizes all application urls >> that support HTTPS and IMAPS protocols., >> expirationPolicy=DefaultRegisteredServiceExpirationPolicy(deleteWhenExpired=false, >> >> notifyWhenDeleted=false, notifyWhenExpired=false, expirationDate=null), >> acceptableUsagePolicy=DefaultRegisteredServiceAcceptableUsagePolicy(enabled=true, >> >> messageCode=null, text=null), >> proxyPolicy=org.apereo.cas.services.RefuseRegisteredServiceProxyPolicy@1, >> proxyTicketExpirationPolicy=null, proxyGrantingTicketExpirationPolicy=null, >> serviceTicketExpirationPolicy=null, singleSignOnParticipationPolicy=null, >> evaluationOrder=10000, >> usernameAttributeProvider=org.apereo.cas.services.DefaultRegisteredServiceUsernameProvider@87297e2, >> >> logoutType=BACK_CHANNEL, environments=[], >> attributeReleasePolicy=ReturnAllowedAttributeReleasePolicy(super=AbstractRegisteredServiceAttributeReleasePolicy(attributeFilter=null, >> >> principalAttributesRepository=DefaultPrincipalAttributesRepository(), >> consentPolicy=DefaultRegisteredServiceConsentPolicy(enabled=true, >> excludedAttributes=null, includeOnlyAttributes=null, order=0), >> authorizedToReleaseCredentialPassword=false, >> authorizedToReleaseProxyGrantingTicket=false, >> excludeDefaultAttributes=false, >> authorizedToReleaseAuthenticationAttributes=true, >> principalIdAttribute=null, order=0), allowedAttributes=[]), >> multifactorPolicy=DefaultRegisteredServiceMultifactorPolicy(multifactorAuthenticationProviders=[], >> >> failureMode=UNDEFINED, principalAttributeNameTrigger=null, >> principalAttributeValueToMatch=null, bypassEnabled=false, >> forceExecution=false, bypassTrustedDeviceEnabled=false, >> bypassPrincipalAttributeName=null, bypassPrincipalAttributeValue=null, >> script=null), logo=null, logoutUrl=null, redirectUrl=null, >> accessStrategy=DefaultRegisteredServiceAccessStrategy(order=0, >> enabled=true, ssoEnabled=true, unauthorizedRedirectUrl=null, >> delegatedAuthenticationPolicy=DefaultRegisteredServiceDelegatedAuthenticationPolicy(allowedProviders=[], >> >> permitUndefined=true, exclusive=false), requireAllAttributes=true, >> requiredAttributes={}, rejectedAttributes={}, caseInsensitive=false), >> publicKey=null, >> authenticationPolicy=DefaultRegisteredServiceAuthenticationPolicy(requiredAuthenticationHandlers=[], >> >> criteria=null), properties={}, contacts=[])] cannot be located. Falling >> back to default theme...> >> >> It is almost it is ignoring the “cas.view.template-prefixes…” directive >> in the cas.properties file. >> >> On May 16, 2020, at 9:56 AM, Root <[email protected]> wrote: >> >> Can you try with this variable? >> >> cas.view.template-prefixes[0]=file:///etc/cas/templates >> >> >> >> On Monday, May 11, 2020 at 8:20:30 AM UTC+5:30, CanaryJudge wrote: >>> >>> CAS Version: 6.2.0-SNAPSHOT >>> >>> Following the directions at: >>> https://apereo.github.io/cas/6.1.x/ux/User-Interface-Customization-Themes.html >>> >>> File: /etc/cas/cas.properties >>> ... >>> spring.thymeleaf.encoding=UTF-8 >>> spring.thymeleaf.cache=false >>> spring.thymeleaf.prefix=file:///etc/cas/templates >>> cas.view.templatePrefixes=file:///etc/cas/templates >>> … >>> >>> Directory: /etc/cas/templates/foo/… >>> >>> File: /etc/cas/templates/foo.properties: >>> cas.standard.css.file=/theme/foo/css/cas.css >>> cas.javascript.file=/theme/foo/js/cas.js >>> cas.admin.css.file=/theme/foo/css/admin.css >>> >>> Error: >>> >>> 2020-05-11 00:03:46,453 ERROR [org.thymeleaf.TemplateEngine] - >>> <[THYMELEAF][https-openssl-nio-8443-exec-3] Exception processing template >>> "casLoginView": Error resolving template [casLoginView], template might not >>> exist or might not be accessible by any of the configured Template >>> Resolvers> >>> org.thymeleaf.exceptions.TemplateInputException: Error resolving >>> template [casLoginView], template might not exist or might not be >>> accessible by any of the configured Template Resolvers >>> at >>> org.thymeleaf.engine.TemplateManager.resolveTemplate(TemplateManager.java:869) >>> >>> ~[thymeleaf-3.0.11.RELEASE.jar:3.0.11.RELEASE] >>> at >>> org.thymeleaf.engine.TemplateManager.parseAndProcess(TemplateManager.java:607) >>> >>> ~[thymeleaf-3.0.11.RELEASE.jar:3.0.11.RELEASE] >>> at org.thymeleaf.TemplateEngine.process(TemplateEngine.java:1098) >>> ~[thymeleaf-3.0.11.RELEASE.jar:3.0.11.RELEASE] >>> at org.thymeleaf.TemplateEngine.process(TemplateEngine.java:1072) >>> ~[thymeleaf-3.0.11.RELEASE.jar:3.0.11.RELEASE] >>> >>> >>> If I change the value in cas.properties to: >>> ... >>> spring.thymeleaf.encoding=UTF-8 >>> spring.thymeleaf.cache=false >>> #spring.thymeleaf.prefix=file:///etc/cas/templates. # <<=== Yes, I >>> commented this out >>> cas.view.templatePrefixes=file:///etc/cas/templates >>> … >>> >>> I get the error: >>> >>> 2020-05-11 02:43:04,246 WARN >>> [org.apereo.cas.services.web.RegisteredServiceThemeResolver] - <Custom >>> theme [foo] for service >>> [AbstractRegisteredService(serviceId=^(http|https)://.*, name=HTTP and >>> HTTPS, theme=foo, informationUrl=null, privacyUrl=null, responseType=null, >>> id=10000001, description=This service definition authorizes all application >>> urls that support HTTPS and IMAPS protocols., >>> expirationPolicy=DefaultRegisteredServiceExpirationPolicy(deleteWhenExpired=false, >>> >>> notifyWhenDeleted=false, notifyWhenExpired=false, expirationDate=null), >>> acceptableUsagePolicy=DefaultRegisteredServiceAcceptableUsagePolicy(enabled=true, >>> >>> messageCode=null, text=null), >>> proxyPolicy=org.apereo.cas.services.RefuseRegisteredServiceProxyPolicy@1, >>> proxyTicketExpirationPolicy=null, proxyGrantingTicketExpirationPolicy=null, >>> serviceTicketExpirationPolicy=null, singleSignOnParticipationPolicy=null, >>> evaluationOrder=10000, >>> usernameAttributeProvider=org.apereo.cas.services.DefaultRegisteredServiceUsernameProvider@87297e2, >>> >>> logoutType=BACK_CHANNEL, environments=[], >>> attributeReleasePolicy=ReturnAllowedAttributeReleasePolicy(super=AbstractRegisteredServiceAttributeReleasePolicy(attributeFilter=null, >>> >>> principalAttributesRepository=DefaultPrincipalAttributesRepository(), >>> consentPolicy=DefaultRegisteredServiceConsentPolicy(enabled=true, >>> excludedAttributes=null, includeOnlyAttributes=null, order=0), >>> authorizedToReleaseCredentialPassword=false, >>> authorizedToReleaseProxyGrantingTicket=false, >>> excludeDefaultAttributes=false, >>> authorizedToReleaseAuthenticationAttributes=true, >>> principalIdAttribute=null, order=0), allowedAttributes=[]), >>> multifactorPolicy=DefaultRegisteredServiceMultifactorPolicy(multifactorAuthenticationProviders=[], >>> >>> failureMode=UNDEFINED, principalAttributeNameTrigger=null, >>> principalAttributeValueToMatch=null, bypassEnabled=false, >>> forceExecution=false, bypassTrustedDeviceEnabled=false, >>> bypassPrincipalAttributeName=null, bypassPrincipalAttributeValue=null, >>> script=null), logo=null, logoutUrl=null, redirectUrl=null, >>> accessStrategy=DefaultRegisteredServiceAccessStrategy(order=0, >>> enabled=true, ssoEnabled=true, unauthorizedRedirectUrl=null, >>> delegatedAuthenticationPolicy=DefaultRegisteredServiceDelegatedAuthenticationPolicy(allowedProviders=[], >>> >>> permitUndefined=true, exclusive=false), requireAllAttributes=true, >>> requiredAttributes={}, rejectedAttributes={}, caseInsensitive=false), >>> publicKey=null, >>> authenticationPolicy=DefaultRegisteredServiceAuthenticationPolicy(requiredAuthenticationHandlers=[], >>> >>> criteria=null), properties={}, contacts=[])] cannot be located. Falling >>> back to default theme...> >>> 2020-05-11 02:43:04,391 WARN >>> [org.apereo.cas.services.web.RegisteredServiceThemeResolver] - <Custom >>> theme [foo] for service >>> [AbstractRegisteredService(serviceId=^(http|https)://.*, name=HTTP and >>> HTTPS, theme=foo, informationUrl=null, privacyUrl=null, responseType=null, >>> id=10000001, description=This service definition authorizes all application >>> urls that support HTTPS and IMAPS protocols., >>> expirationPolicy=DefaultRegisteredServiceExpirationPolicy(deleteWhenExpired=false, >>> >>> notifyWhenDeleted=false, notifyWhenExpired=false, expirationDate=null), >>> acceptableUsagePolicy=DefaultRegisteredServiceAcceptableUsagePolicy(enabled=true, >>> >>> messageCode=null, text=null), >>> proxyPolicy=org.apereo.cas.services.RefuseRegisteredServiceProxyPolicy@1, >>> proxyTicketExpirationPolicy=null, proxyGrantingTicketExpirationPolicy=null, >>> serviceTicketExpirationPolicy=null, singleSignOnParticipationPolicy=null, >>> evaluationOrder=10000, >>> usernameAttributeProvider=org.apereo.cas.services.DefaultRegisteredServiceUsernameProvider@87297e2, >>> >>> logoutType=BACK_CHANNEL, environments=[], >>> attributeReleasePolicy=ReturnAllowedAttributeReleasePolicy(super=AbstractRegisteredServiceAttributeReleasePolicy(attributeFilter=null, >>> >>> principalAttributesRepository=DefaultPrincipalAttributesRepository(), >>> consentPolicy=DefaultRegisteredServiceConsentPolicy(enabled=true, >>> excludedAttributes=null, includeOnlyAttributes=null, order=0), >>> authorizedToReleaseCredentialPassword=false, >>> authorizedToReleaseProxyGrantingTicket=false, >>> excludeDefaultAttributes=false, >>> authorizedToReleaseAuthenticationAttributes=true, >>> principalIdAttribute=null, order=0), allowedAttributes=[]), >>> multifactorPolicy=DefaultRegisteredServiceMultifactorPolicy(multifactorAuthenticationProviders=[], >>> >>> failureMode=UNDEFINED, principalAttributeNameTrigger=null, >>> principalAttributeValueToMatch=null, bypassEnabled=false, >>> forceExecution=false, bypassTrustedDeviceEnabled=false, >>> bypassPrincipalAttributeName=null, bypassPrincipalAttributeValue=null, >>> script=null), logo=null, logoutUrl=null, redirectUrl=null, >>> accessStrategy=DefaultRegisteredServiceAccessStrategy(order=0, >>> enabled=true, ssoEnabled=true, unauthorizedRedirectUrl=null, >>> delegatedAuthenticationPolicy=DefaultRegisteredServiceDelegatedAuthenticationPolicy(allowedProviders=[], >>> >>> permitUndefined=true, exclusive=false), requireAllAttributes=true, >>> requiredAttributes={}, rejectedAttributes={}, caseInsensitive=false), >>> publicKey=null, >>> authenticationPolicy=DefaultRegisteredServiceAuthenticationPolicy(requiredAuthenticationHandlers=[], >>> >>> criteria=null), properties={}, contacts=[])] cannot be located. Falling >>> back to default theme...> >>> 2020-05-11 02:43:04,959 INFO >>> [org.apereo.inspektr.audit.support.Slf4jLoggingAuditTrailManager] - <Audit >>> trail record BEGIN >>> … >>> >>> I feel like I am very close but I cannot figure it out from the >>> documentation as the documentation reads: >>> >>> "Add a [theme_name].properties placed to the root of src/main/resources >>> folder. >>> Contents of this file should match the following:" >>> >>> But I seriously doubt I have to recompile the software EVERY time I try >>> to use a dynamic theme for a service. >>> >>> I am missing something but I cannot figure out what it is. >>> >> >> -- >> - Website: https://apereo.github.io/cas >> - Gitter Chatroom: https://gitter.im/apereo/cas >> - List Guidelines: https://goo.gl/1VRrw7 >> - Contributions: https://goo.gl/mh7qDG >> --- >> You received this message because you are subscribed to the Google Groups >> "CAS Community" group. >> To unsubscribe from this group and stop receiving emails from it, send an >> email to cas-...@apereo. <http://apereo.org/>org <http://apereo.org/>. >> To view this discussion on the web visit >> https://groups.google.com/a/apereo.org/d/msgid/cas-user/7f28549b-ee1f-4bc4-8668-9f4797537eac%40apereo.org >> >> <https://groups.google.com/a/apereo.org/d/msgid/cas-user/7f28549b-ee1f-4bc4-8668-9f4797537eac%40apereo.org?utm_medium=email&utm_source=footer> >> . >> >> >> > -- > - Website: https://apereo.github.io/cas > - Gitter Chatroom: https://gitter.im/apereo/cas > - List Guidelines: https://goo.gl/1VRrw7 > - Contributions: https://goo.gl/mh7qDG > --- > You received this message because you are subscribed to the Google Groups > "CAS Community" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to [email protected] <javascript:>. > To view this discussion on the web visit > https://groups.google.com/a/apereo.org/d/msgid/cas-user/959d6aea-f5b6-4678-a87e-f9f44b3cbb4c%40apereo.org > > <https://groups.google.com/a/apereo.org/d/msgid/cas-user/959d6aea-f5b6-4678-a87e-f9f44b3cbb4c%40apereo.org?utm_medium=email&utm_source=footer> > . > > > -- - Website: https://apereo.github.io/cas - Gitter Chatroom: https://gitter.im/apereo/cas - List Guidelines: https://goo.gl/1VRrw7 - Contributions: https://goo.gl/mh7qDG --- You received this message because you are subscribed to the Google Groups "CAS Community" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/a/apereo.org/d/msgid/cas-user/344828bc-1809-46e3-85c0-2e64635a20ae%40apereo.org.
