[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Basic webapp packaging questions

hi jonathan,

On Wed, Jun 30, 2010 at 02:24:39PM -0500, Jonathan Nieder wrote:
> 1. What is the standard address for the webapps policy?  I looked in
> /usr/share/doc/debian-policy and found nothing, then
> http://webapps-common.alioth.debian.org/draft/html/ and found
> “Copyright © 2005-2006 The Debian Webapps Team” and “Revision:
> DRAFT-1.10”, which left me unconfident that I have the latest version.

i think that's the "authoritative" version, though there may be some
unpublished/uncommited changes in svn.

> Related question: is there a page for the Debian webapps team on
> wiki.debian.org?

i don't think so.  it's not so much a team as it's a group of people
who agreed on some general guidelines on a mailing list at some point :)

> 2. What packages should a webapp depend on?  For a simple CGI
> script, would
>   apache2 | httpd-cgi
> do?  Is there a way to configure a webapp by default for arbitrary
> servers providing httpd-cgi?

if it could possibly work with other cgi-serving applications (regardless
of whether you ship working configuration for the other variants), then yes
i think that makes sense.  as for location, official debian policy says
you could drop files in /usr/lib/cgi-bin, though myself i'm not a huge
fan of that as a general rule since the scripts are able to be run as
soon as the package is unpacked, even if it's not configured.  therefore
i suggest keeping things under /usr/{lib,share}/<package>/$subdir.

> gitweb installs a configuration file in /etc/apache2/conf.d/gitweb.
> Should it additionally Suggests: apache2?

if it's in the dependencies listed above i don't think it's necessary.

> 3. How to handle changes in the files that should be served
> statically?  I imagine that to avoid installing stray files, some
> existing web server configurations might include
>    Alias /gitweb.css /usr/share/gitweb/gitweb.css
>    Alias /gitweb.js /usr/share/gitweb/gitweb.js
>    Alias /git-favicon.png /usr/share/gitweb/git-favicon.png
>    Alias /git-logo.png /usr/share/gitweb/git-logo.png

i think it depends on what's the easiest thing to do with the
original code.  personally i'm a fan of compartmentalizing things
in different subdirectories underneath /usr/share/<pkg>, though if it's
only a small number of files the above would be reasonable too imho (as long
as the entire directory isn't being served by a single alias, which could
be problematic later on when you want to move stuff around.

> Must there be an entry in NEWS.Debian.gz whenever a new file is added
> or a file is moved?  One could avoid that in the future (as upstream
> does in current 1.7.2 release candidates) by changing the filesystem
> layout to allow
>   Alias /static /usr/share/gitweb/static

yeah that's something like what i was getting at above.  I don't think
NEWS.gz entries would strictly be necessary unless you had some suspicion
that things would be more likely to break in a typical installation.

> Unfortunately, removing the old files would break gitweb during
> upgrade.  Suggestions?

i don't think it's worth a great deal of blood/sweat/tears to try and
keep things working during an apt-get upgrade window, since no matter
what there will probably be some short span where things are broken
no matter what while the package(s) are being unpacked and configured.

> I also wanted to thank you for the webapps policy and especially for
> dbconfig-common.  The standard quality for webapp packages is getting
> a lot better.

\o/ :D


Attachment: signature.asc
Description: Digital signature

Reply to: