| 1 |
#!/usr/bin/env perl |
| 2 |
|
| 3 |
use strict; |
| 4 |
use warnings; |
| 5 |
use FindBin; |
| 6 |
use lib "$FindBin::Bin/../lib"; |
| 7 |
|
| 8 |
|
| 9 |
# use this block if you don't need middleware, and only have a single target Dancer app to run here |
| 10 |
use [d2% appname %2d]; |
| 11 |
|
| 12 |
[d2% appname %2d]->to_app; |
| 13 |
|
| 14 |
=begin comment |
| 15 |
# use this block if you want to include middleware such as Plack::Middleware::Deflater |
| 16 |
|
| 17 |
use [d2% appname %2d]; |
| 18 |
use Plack::Builder; |
| 19 |
|
| 20 |
builder { |
| 21 |
enable 'Deflater'; |
| 22 |
[d2% appname %2d]->to_app; |
| 23 |
} |
| 24 |
|
| 25 |
=end comment |
| 26 |
|
| 27 |
=cut |
| 28 |
|
| 29 |
=begin comment |
| 30 |
# use this block if you want to mount several applications on different path |
| 31 |
|
| 32 |
use [d2% appname %2d]; |
| 33 |
use [d2% appname %2d]_admin; |
| 34 |
|
| 35 |
use Plack::Builder; |
| 36 |
|
| 37 |
builder { |
| 38 |
mount '/' => [d2% appname %2d]->to_app; |
| 39 |
mount '/admin' => [d2% appname %2d]_admin->to_app; |
| 40 |
} |
| 41 |
|
| 42 |
=end comment |
| 43 |
|
| 44 |
=cut |
| 45 |
|