Hi, until now, I used fp-web to create cgi applications. Now I want to
try fastcgi, but I don't know how to start the fascgi app.

Let me explain what I did.

1) In Lazarus I went to Project -> New -> FastCGI application. This
created the skeleton for my app, very similar to a CGI app (with a
TFPWebModule), but using fcgi unit instead of cgi unit.

2) Implemented a default method to just answer "Hello!".

3) After that, I compiled the program and started configuring my Apache2
(I'm on Ubuntu 10.04):

  a) Edited /etc/apache2/mods-enabled/fastcgi.conf by adding with this:

    <Directory "/var/www/fcgi-bin">
      AllowOverride None
      Options None
      Order allow,deny
      Allow from all
    </Directory>
    AddHandler fastcgi-script .fcgi


    FastCgiExternalServer /var/www/cgi-bin/myfcgiprogram \
    -host 127.0.0.1:2014 \
    -idle-timeout 3

    This tells Apache2 that, when the browser points to
/cgi-bin/myfcgiprogram, it will connect to a fastcgi server running on
127.0.0.1 on port 2014.

    Note: I'm configuring this the same way ExtPascal FCGI programs
work, because I couln't find any help in the web nor sources of fcl-web
on how to configure it.

  b) Tried running my fastcgi app from command line, but it gave me this
error:

  exception at 0000000000466EEA:
  Failed to open input-handle passed from server. Socket Error: 88. 

Now I'm stuck, somebody can help me with this?.

-- 
Leonardo M. Ramé
http://leonardorame.blogspot.com

--
_______________________________________________
Lazarus mailing list
[email protected]
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus

Reply via email to