summaryrefslogtreecommitdiff
path: root/bin/build.psgi
diff options
context:
space:
mode:
authorJonas Smedegaard <dr@jones.dk>2018-05-16 18:19:15 +0200
committerJonas Smedegaard <dr@jones.dk>2018-05-16 18:19:15 +0200
commitf28bd89951bf9fd67b6dc97889878592780b3b72 (patch)
tree0a6900eb047f01b54003c6ec1f1946211e15af2c /bin/build.psgi
parent41a540aa970667873051422e40492696ee19bd0b (diff)
Add targets build-compact serve-quick serve-compact.
Diffstat (limited to 'bin/build.psgi')
-rwxr-xr-xbin/build.psgi21
1 files changed, 21 insertions, 0 deletions
diff --git a/bin/build.psgi b/bin/build.psgi
new file mode 100755
index 0000000..cdc51ef
--- /dev/null
+++ b/bin/build.psgi
@@ -0,0 +1,21 @@
+#!/usr/bin/env plackup
+
+use strict;
+use warnings;
+
+use FindBin qw($Bin);
+
+use Plack::Builder;
+
+#use Plack::App::File;
+use Plack::App::Directory;
+
+builder {
+ eval { enable 'DirIndex' };
+ eval { enable 'Deflater' };
+
+# enable 'Debug', panels => [ qw(DBITrace Memory Timer) ];
+# mount '/usr/share/javascript' => Plack::App::File->new( root => '/usr/share/javascript' )->to_app;
+ mount '/' =>
+ Plack::App::Directory->new( root => "$Bin/../build" )->to_app;
+};