Beefy Boxes and Bandwidth Generously Provided by pair Networks
We don't bite newbies here... much
 
PerlMonks  

Re: Simple http server one-liner for some static files?

by Your Mother (Chancellor)
on Mar 21, 2016 at 12:31 UTC ( #1158433=note: print w/replies, xml ) Need Help??


in reply to Simple http server one-liner for some static files?

And since this dead horse is apparently still being flogged. :P This is the one-liner I tend to use (because there are other middlewares and such that are easy to add and play with).

plackup -p 5000 -MPlack::App::Directory -e 'Plack::App::Directory->new +({root => q{.}})->to_app'

I understand that using the tools to get a local Perl install and such are not super easy. They are not too difficult once you get the hang of them. What I would recommend if you decide it's worth the effort: local::lib, cpanm, and perlbrew (and tangentially: Plack for wsgi like Perl -> psgi).

Update: missing preposition.

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1158433]
help
Chatterbox?
and all is quiet...

How do I use this? | Other CB clients
Other Users?
Others imbibing at the Monastery: (5)
As of 2018-01-19 02:46 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    How did you see in the new year?










    Results (215 votes). Check out past polls.

    Notices?