rack-devel archive mirror (unofficial) https://groups.google.com/group/rack-devel
 help / color / mirror / Atom feed
From: Joshua Ballanco <jballanc@gmail.com>
To: rack-devel@googlegroups.com
Subject: Re: Configuring rack based on lighttpd for ruby app.
Date: Sun, 4 Sep 2011 22:27:22 -0400	[thread overview]
Message-ID: <CACHATVtSJ+YfWZ5O+aE5EMPSyy0B0TYym9E_==JMkgLZjnOXHA@mail.gmail.com> (raw)
In-Reply-To: <555d0e41-06a2-4ed3-a69c-d6283eb4b468@j4g2000prh.googlegroups.com>

[-- Attachment #1: Type: text/plain, Size: 2405 bytes --]

You have your config.ru set as your binary to execute via FastCGI. Are you
sure that's what you want? Do you have a shebang in the config.ru? Have you
set the executable bit?

On Fri, Sep 2, 2011 at 4:35 AM, coolesting <coolesting@gmail.com> wrote:

> Hi, guys,
>
> My version is ruby 1.9.2, rack 1.2.3, and web server is lighttpd that
> is very strange to me how to configure.
>
> I according to this post { http://devcenter.heroku.com/articles/rack }
> to create a  pure ruby web application based on rack , and then use
> the command 'rackup' to start the web application that is success.
>
> Here is problem, i want to use the lighttpd to start this project.
> Now, how do i configure this rack application.
>
> My project directory like this :
> (root directory) -- /var/www/htdocs/ruby_app/
> config.ru
> Gemfile
> Gemfile.lock
> README
> public
> tmp
>
> The public and tmp is empty, other is file,
> the config.ru code as the following :
> run lambda { |env| [200, {'Content-Type'=>'text/plain'},
> StringIO.new("Hello Ruby APP!\n")] }
>
> this code is successful to run based on rakeup command in terminal,
>
> and the fastcgi configuration file as the following:
> $HTTP["host"] == "localhost" {
>        server.document-root  = server_root + "/ruby_app"
>        server.error-handler-404 = server_root + "/ruby_app/public/
> 404.html"
>        fastcgi.server = ( ".ru" =>
>                ((
>                "host" => "127.0.0.1",
>                "port" => 4000,
>                "bin-path" => server_root + "/ruby_app/config.ru",
>                "check-local" => "disable",
>                "max-procs" => 1
>                ))
>        )
> }
>
> So, i got this error message as the following:
> 2011-09-02 01:30:15: (log.c.166) server started
> 2011-09-02 01:30:15: (mod_fastcgi.c.1103) the fastcgi-backend /var/www/
> ruby_app/config.ru failed to start:
> 2011-09-02 01:30:15: (mod_fastcgi.c.1107) child exited with status 2 /
> var/www/ruby_app/config.ru
> 2011-09-02 01:30:15: (mod_fastcgi.c.1110) If you're trying to run your
> app as a FastCGI backend, make sure you're using the FastCGI-enabled
> version.
> If this is PHP on Gentoo, add 'fastcgi' to the USE flags.
> 2011-09-02 01:30:15: (mod_fastcgi.c.1397) [ERROR]: spawning fcgi
> failed.
> 2011-09-02 01:30:15: (server.c.945) Configuration of plugins failed.
> Going down.
>
>
> Thanks in advance, i very very need the helps.
>

[-- Attachment #2: Type: text/html, Size: 3491 bytes --]

      reply	other threads:[~2011-09-05  2:27 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-09-02  8:35 Configuring rack based on lighttpd for ruby app coolesting
2011-09-05  2:27 ` Joshua Ballanco [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-list from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://groups.google.com/group/rack-devel

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='CACHATVtSJ+YfWZ5O+aE5EMPSyy0B0TYym9E_==JMkgLZjnOXHA@mail.gmail.com' \
    --to=rack-devel@googlegroups.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).