LLNG should not rely on virtual hosts so much
The current model of LLNG is heavily based around "Virtual Hosts" and the notion of having a common domain for portal, manager, 'reload' and apps, but three (at least) different hostnames.
But we have many users who do not use the handler at all, and instead only use the SAML/OIDC issuers. For them, having to dedicate an entire subdomain to LemonLDAP makes little sense.
We have users who would like to deploy LLNG components in a sub-path: the manager in /manager, for exemple. Or even, the portal in /portal, why not! And maybe apps in /test1 and /test2?
This would allow us to run an entire "demo instance" under a single URL, without even requiring apache or nginx, just plackup! No more DNS or /etc/hosts issues. Much easier for us devs, too, no more make start_web_server
.
Good news: because the LLNG router uses $req->path
, it wouldn't take a huge amount of work to achieve this. (but it will take a lot of testing). Mostly we would just have to write a new handler type that does not depend on the VHost name, but perhaps on a FastCGI environment variable set by the admin within a location
block. The regexp in this new handler type would only be matched against $req->path
instead of the entire URL. This handler could solve #2238 too.
Opening this low-priority ticket for discussion, and so I can have a reference to put in commits when I do little improvements towards this long-term goal.