Skip to content

Instantly share code, notes, and snippets.

@Su-Shee
Created October 7, 2016 13:46
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Su-Shee/6a71f9272feb8597d488eeec93932f4b to your computer and use it in GitHub Desktop.
Save Su-Shee/6a71f9272feb8597d488eeec93932f4b to your computer and use it in GitHub Desktop.
#!/usr/bin/env perl
use Mojolicious::Lite;
use Cwd;
@ARGV = qw(daemon --listen http://*:5000);
app->static->paths->[0] = getcwd;
# needed to setup the usual index.html landing
any '/' => sub {
shift->render_static('index.html');
};
app->start;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment