in reply to Re^3: Plack beer challenge (#! args)
in thread Plack beer challenge

Fair enough.

I was only trying what I had gathered from a previous posting.

The main question remains: How is it done properly?

Replies are listed 'Best First'.
Re^5: Plack beer challenge (#! args)
by Anonymous Monk on Sep 30, 2011 at 08:53 UTC

    If what tye is saying has merit, since plackup is all of 9 lines, you could use

    #!/home/mh/perl514/bin/perl -- use strict; use warnings; use Plack::Runner; my $app = sub { return [ 200, [ "Content-Type" => "text/plain" ], ["hi"] ]; }; my $runner = Plack::Runner->new; $runner->parse_options( qw{ -s FCGI --listen / tmp /fcgi.sock --daemonize --nproc 10 }); $runner->run($app); __END__
      Thanks for your post.

      I have tried your script, as before it works stand-alone, however when run from apache I get an internal server error.

      The error-log says "Connection reset by peer: mod_fcgid: error reading data from FastCGI server" and "Premature end of script headers: app.psgi".

      Anyone with more ideas?

        I have tried your script, as before it works stand-alone, however when run from apache I get an internal server error.

        I would contact the respective mailing list :)