Dezi::MultiTenant - multiple Dezi::Server applications in a single instance
% dezi --server-class Dezi::MultiTenant --dezi-config myconfig.pl # or in your own Plack app use Plack::Runner; use Dezi::MultiTenant; my $multitenant_config = { 'foo' => Dezi::Config->new(\%foo_opts), 'bar' => Dezi::Config->new(\%bar_opts), }; my $runner = Plack::Runner->new(); my $app = Dezi::MultiTenant->app( $multitenant_config ); $runner->run($app); # /foo mounts a Dezi::Server # /bar mounts a Dezi::Server
Dezi::MultiTenant provides a simple way to mount multiple Dezi::Server applications in a single Plack app using a single configuration structure.
Dezi::Server allows you to serve multiple indexes, but all the indexes must have identical schemas.
Dezi::MultiTenant allows you to server multiple indexes per server, and each server can have a different schema, as well as individual administration, logging, unique configuration, etc.
Returns Plack $app instance via Plack::Builder.
config should either be a hashref with keys representing each Dezi::Server's mount point, or a Dezi::MultiTenant::Config object. By default the root '/' mount point is reserved for the Dezi::MultiTenant->about() method response. Hash keys should have the '/' prefix (same syntax as Plack::App::URLMap).
Returns Plack::Response-like array ref describing the multi-tenant application.
Peter Karman, <karman at cpan.org>
<karman at cpan.org>
Please report any bugs or feature requests to bug-dezi-multitenant at rt.cpan.org, or through the web interface at http://rt.cpan.org/NoAuth/ReportBug.html?Queue=Dezi-MultiTenant. I will be notified, and then you'll automatically be notified of progress on your bug as I make changes.
bug-dezi-multitenant at rt.cpan.org
You can find documentation for this module with the perldoc command.
perldoc Dezi::MultiTenant
You can also look for information at:
RT: CPAN's request tracker
http://rt.cpan.org/NoAuth/Bugs.html?Dist=Dezi-MultiTenant
AnnoCPAN: Annotated CPAN documentation
http://annocpan.org/dist/Dezi-MultiTenant
CPAN Ratings
http://cpanratings.perl.org/d/Dezi-MultiTenant
Search CPAN
http://search.cpan.org/dist/Dezi-MultiTenant/
Copyright 2013 Peter Karman.
This program is free software; you can redistribute it and/or modify it under the terms of either: the GNU General Public License as published by the Free Software Foundation; or the Artistic License.
See http://dev.perl.org/licenses/ for more information.
To install Dezi::MultiTenant, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Dezi::MultiTenant
CPAN shell
perl -MCPAN -e shell install Dezi::MultiTenant
For more information on module installation, please visit the detailed CPAN module installation guide.