This is exactly the type of answer I was NOT looking for.
While I believe that your links may contain the answer I have already proven to myself beyond any doubt that I am too stupid to properly understand them...
Here is my app:
Started on it's own it actually works - it starts a web-server on port 5000 that delivers the proper result.#!/home/mh/perl514/bin/plackup -s FCGI --listen /tmp/fcgi.sock --daemo +nize --nproc 10 use strict; use warnings; return sub { return [ 200, ["Content-Type" => "text/plain"], ["hi"] ]; }
But how to make this work in Apache?
I have put this app as "app.psgi" in /usr/lib/cgi-bin and this is my apache-config:
Now what happens is that when I try point my browser to the plack-app apache I get an internal server error.ScriptAlias /cgi-bin/ /usr/lib/cgi-bin/ <Directory "/usr/lib/cgi-bin"> AllowOverride None Options +ExecCGI -MultiViews +SymLinksIfOwnerMatch Order allow,deny Allow from all AddHandler fcgid-script .psgi </Directory>
The plack-app actually is launched (there is a process visible), but it seems to me that the plack-app and apache cannot communicate as I can see in the error log that fcgid reports a read timeout and the really weird thing is that I have this line in the error log HTTP::Server::PSGI: Accepting connections at http://0:5000
So to me it seems as if Plack is not aware that it runs under apache for some reasons...
The beer is still for grabs...
In reply to Re^2: Plack beer challenge
by morgon
in thread Plack beer challenge
by morgon
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |