public inbox for git@vger.kernel.org 
 help / color / mirror / Atom feed
From: Eric Wong <normalperson@yhbt•net>
To: Jakub Narebski <jnareb@gmail•com>
Cc: git@vger•kernel.org, Christian Couder <chriscool@tuxfamily•org>
Subject: Re: Adding support for "plackup" and similar web server tools to git-instaweb
Date: Mon, 3 May 2010 13:56:24 -0700	[thread overview]
Message-ID: <20100503205624.GA3791@dcvr.yhbt.net> (raw)
In-Reply-To: <201005020317.42112.jnareb@gmail.com>

Jakub Narebski <jnareb@gmail•com> wrote:
> The problem is that contrary to other web servers that can be used by
> git-instaweb, (namely apache2, lighttpd, mongoose and webrick), the
> 'plackup' utility is configured using command line options, and not
> via configuration file (well, one can use configuration file, but it
> depends on the web server run from plackup).
> 
> How should one go with adding support for such httpd?  My first attempt
> was putting full command line into 'httpd' in resolve_full_httpd():
> 
> +       *plackup*)
> +               # plackup is configured via command-line options
> +               bind=
> +               test x"$local" = xtrue && bind="--host=127.0.0.1"
> +               httpd="$httpd --port=$port $bind --app=$fqgitdir/gitweb/app.psgi"
> +               ;;
> 
> The default standalone web server used by plackup (HTTP::Server::PSGI)
> does not have daemon mode, so we would have to do the same as for moongose
> web server: set to background and save pid in pidfile in git-instaweb.
> 
> OTOH plackup prints information / logs to STDERR, so it would have to be
> silenced or redirected to error_log.  Also plackup does not need to have
> "$fqgitdir/gitweb/httpd.conf" passed as last argument, but it needs to
> be passed PSGI wrapper for CGI (I'd rather not use httpd.conf, but rather
> app.psgi or gitweb.psgi for that).
> 
> 
> So how should one go with adding support for new web server to git-instaweb,
> that is configured via command line options (--port, --host) and not via
> config file?

Hi Jakub,

How about generating a small shell script that wraps plackup with the
appropriate command-line options?

-- 
Eric Wong

  reply	other threads:[~2010-05-03 20:56 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-05-02  1:17 Adding support for "plackup" and similar web server tools to git-instaweb Jakub Narebski
2010-05-03 20:56 ` Eric Wong [this message]
2010-05-03 22:25   ` Jakub Narebski

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-all from there: mbox

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

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

  git send-email \
    --in-reply-to=20100503205624.GA3791@dcvr.yhbt.net \
    --to=normalperson@yhbt$(echo .)net \
    --cc=chriscool@tuxfamily$(echo .)org \
    --cc=git@vger$(echo .)kernel.org \
    --cc=jnareb@gmail$(echo .)com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html
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