Allow portal app to be chosen through LLTYPE (#2285)

This lets the admin be more explicit about routing.
Since 2.0 we have a single entry point for each component, we don't
really need to dynamically load psgi files.
This commit is contained in:
Maxime Besson 2020-08-19 23:48:26 +02:00
parent 9d569817bd
commit b0c53126ee
3 changed files with 12 additions and 1 deletions

View File

@ -39,8 +39,11 @@ The FastCGI server reads also ``LLTYPE`` parameter in FastCGI requests
(see portal-nginx.conf or manager-nginx.conf) to choose which module is
called:
- ``cgi`` for the portal (or any CGI: it works like PHP-FPM for Perl !)
- ``cgi`` to run .cgi scripts in FastCGI compatibility mode
- ``psgi`` ro run .psgi scripts under FastCGI
- ``manager`` for the manager
- ``handler`` for the handler
- ``portal`` for the portal
- ``status`` to see statistics (if enabled)
if ``LLTYPE`` is set to another value or not set, FastCGI server works

View File

@ -76,6 +76,10 @@ my %builder = (
require Lemonldap::NG::Manager;
return Lemonldap::NG::Manager->run( {} );
},
portal => sub {
require Lemonldap::NG::Portal;
return Lemonldap::NG::Portal->run( {} );
},
cgi => sub {
require CGI::Emulate::PSGI;
require CGI::Compile;

View File

@ -24,6 +24,10 @@ my %builder = (
require Lemonldap::NG::Manager;
return Lemonldap::NG::Manager->run( {} );
},
portal => sub {
require Lemonldap::NG::Portal;
return Lemonldap::NG::Portal->run( {} );
},
cgi => sub {
require CGI::Emulate::PSGI;
require CGI::Compile;