[dancer-users] Mig Dancer 1 to 2: set confdir does not work?
Stefan Hornburg (Racke)
racke at linuxia.de
Wed May 25 08:51:44 BST 2016
On 05/25/2016 09:49 AM, Jochen Schnuerle wrote:
> Stefan Hornburg (Racke) wrote:
>> On 05/24/2016 05:50 PM, Warren Young wrote:
>>> On May 24, 2016, at 7:50 AM, Jochen Schnuerle <js at betabox.de> wrote:
>>>> But I don't unterstand.
>>> I pointed you right at the code implementing the feature you’re trying to use. It’s quite straightforward Perl. If you don’t understand my prose description of what it does, you should certainly understand the Perl code.
>>>> I just want to move my config.yml in the sub dir /etc.
>>> The feature you’re trying to use doesn’t allow that. You will either have to structure your project directory differently, or change Dancer to behave the way you prefer.
>> I suggest to look at the environment variables, which Dancer 2 uses:
>> Especially DANCER_CONFDIR and DANCER_ENVDIR.
> That worked great!
> After configure the env vars:
> export DANCER_CONFDIR="/opt/fsi/portal/etc"
> export DANCER_ENVDIR="/opt/fsi/portal/etc"
> Dancer2 search for the "views" dir in
> So I add to the config.yml of my Dancer2 source:
> views: "/opt/fsi/portal/views"
> and remove the source lines in my fsi.pm:
> #set config_location => $dirs . '../etc';
> #set environments_location => $dirs . '../etc';
> #set 'environment' => 'development';
> and all works great, like I have it in my Dancer1 source/tree.
> Thank you very much!
You are welcome, we now better add that to the migration documentation.
Please visit our 3rd Perl Dancer Conference 2016 in Vienna: https://www.perl.dance/.
More information about the dancer-users