diff options
author | Guilhem Moulin <guilhem.moulin@fripost.org> | 2012-09-02 02:45:05 +0200 |
---|---|---|
committer | Guilhem Moulin <guilhem.moulin@fripost.org> | 2012-09-02 02:47:47 +0200 |
commit | 742c9938af740b9ba758f4b03909f30106b285a5 (patch) | |
tree | 58138e66695572c9a52164560b281c856d4a51b1 /server.pl | |
parent | ec2ed6c255ca97f39d4a58071f8558744bd9958d (diff) |
Use global configuration files.
Diffstat (limited to 'server.pl')
-rwxr-xr-x | server.pl | 25 |
1 files changed, 15 insertions, 10 deletions
@@ -4,20 +4,25 @@ use strict; use warnings; use utf8; -use CGI::Application::Server; +use MyServer; use lib 'lib'; use FPanel::Interface; -#use MyCGI::App::Account::Dispatch; -my $server = CGI::Application::Server->new(); -#my $panel = FPanel::Interface->new( -# PARAMS => { cfg_file => ['config.yml'] -# , format => 'YAML' -# } -#); +my $server = MyServer->new(); $server->entry_points({ - '/cgi-bin' => #$panel - 'FPanel::Interface' + '/cgi-bin' => 'FPanel::Interface' }); + +my @config = 'default.in'; +push @config, 'config.in' if -f 'config.in'; + +# TODO: This is only for testing purposes. Using a blessed target above +# prevents me from logging in. +$server->options({ + '/cgi-bin' => { + PARAMS => { cfg_file => [ @config ], format => 'equal' } + } +}); + $server->run(); |