[Catalyst] Setting the COMPILE_DIR for TT templates in the configuration file

Alexander Hartmaier alexander.hartmaier at t-systems.at
Mon Jan 23 09:14:49 GMT 2012


Hi Robert,
what config format are you using?
If the file has the extension .conf Config::General is used and your
example should work.

Am 2012-01-22 21:16, schrieb Robert Rothenberg:
> On 22/01/12 19:58 Tomas Doran wrote:
>> On 22 Jan 2012, at 18:54, Robert Rothenberg wrote:
>>
>>> <View::TT>
>>> COMPILE_DIR /var/opt/myapp/template_cache
>>> </View::TT>
>>>
>>> where MyApp::View::TT is the name of the view module.
>>>
>>> None of them work. How do I do this?
>> This should work.
>>
>> http://localhost:3000/?dump_info=1
>>
>> will dump the config that the app has actually read in and merged (assuming
>> you've got debug mode on and you're using the standard RenderView plugin).
>>
>> Does the config dumped look like you expect? Can you show us?
> It doesn't quite look like what I expect. Excerpts:
>
> "Plugin::Session"                     =>  {
>                   storage =>  "/tmp/myapp/session",
>                   },
>
>   "View::TT"                        =>  {
>                   COMPILE_DIR =>  "/tmp/myapp/template_cache",
>                   },
>
> Those are the defaults that are set in the module. I want to override them
> in the conf file.
>
> But setting in the conf file:
>
> <Plugin::Session>
>    storage /var/opt/myapp/session
> </PLugin::Session>
>
> or similarly for<View::TT>  does not change those values. (I know setting
> other things such as the DSN in the conf works, so it's the right file).
>
> Rob
>
>
>
>> Are you customising your TT view in any way (i.e. adding extra code yourself
>> - specifically to the constructor). Do you have a make_immutable in there?
>> (Can you show us the whole file?)
>>
>> Cheers
>> t0m
>>
>>
>> _______________________________________________
>> List: Catalyst at lists.scsys.co.uk
>> Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst
>> Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/
>> Dev site: http://dev.catalyst.perl.org/
>
> _______________________________________________
> List: Catalyst at lists.scsys.co.uk
> Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst
> Searchable archive: http://www.mail-archive.com/catalyst@lists.scsys.co.uk/
> Dev site: http://dev.catalyst.perl.org/


*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*
T-Systems Austria GesmbH Rennweg 97-99, 1030 Wien
Handelsgericht Wien, FN 79340b
*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*
Notice: This e-mail contains information that is confidential and may be privileged.
If you are not the intended recipient, please notify the sender and then
delete this e-mail immediately.
*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*"*



More information about the Catalyst mailing list