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

Bug#664761: apache2/conf.d migration: what should webapp packagers do?



-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Hello Jonathan,

it's me again. We've written the promised mail to
debian-devel-announce including pointers to the wiki with hands-on
tutorials how to reverse packagers should interact with us. Is this
somewhat what you expected to read?

For your question in particular:

On 20.03.2012 18:18, Jonathan Nieder wrote:
> /etc/apache2/conf.d/gitweb:
> 
> Alias /gitweb /usr/share/gitweb
> 
> <Directory /usr/share/gitweb> Options FollowSymLinks +ExecCGI 
> AddHandler cgi-script .cgi DirectoryIndex gitweb.cgi RewriteEngine
> On RewriteCond %{REQUEST_FILENAME} !-fuld RewriteCond
> %{REQUEST_FILENAME} !-d RewriteRule ^.* /gitweb/gitweb.cgi/$0
> [L,PT] </Directory>
> 

I do not think having a global "/packagename" is a problem either. If
the user does not like it, he can always change it. That's what
configuration files are for.

However, reading your snippet I realized, you use module directives
which aren't available until one enables the rewrite module in your
case. We might think how to allow packagers of web applications to
"tell" us, your configuration needs a special module. As we wrote in
the announcement mail, we're open to suggestions from packagers of web
applications.

I guess we may provide another helper function you can call or we
stick to "apache2_invoke enmod mod1 [mod2 ...]".


>> From the PACKAGING file I get the impression that I should rename
>> the
> gitweb configuration (with the usual conffile renaming dance) to 
> /etc/apache2/conf-available/gitweb.conf, depend on an updated
> apache2, run
> 
> [ -e /usr/share/apache2/apache2-maintscript-helper ] || exit 0 .
> /usr/share/apache2/apache2-maintscript-helper apache2_invoke enconf
> gitweb
> 
> in postinst configure, and ask for a Breaks from the apache2 
> maintainers.  Is that right?

That's (somewhat) right. We encourage you not to declare unconditional
package relations to "apache2". Instead, you should declare relations
in the form

Recommends: apache2 | http

That's why you need to protect the calls to
/usr/share/apache2/apache2-maintscript-helper. Whether to use depends
or recommends is subject to discussion, and we'd like to hear web
application packagers' opinion on that.

Alternatively you can use dh_apache2 (presuming your configuration is
in debian/gitweb.conf):

debian/gitweb.apache2:

conf	debian/gitweb.conf

debian/control:

Build-Depends: dh-apache2, debhelper
...
Recommends: ${misc:Recommends}



> This bug report is a request for advice in NEWS.Debian.gz about
> this, for example by including a pointer to PACKAGERS in the text
> and mentioning whether packages supporting old and new apache at
> the same time are possible.

I am not sure whether the NEWS file is an appropriate place for
packaging hints but I will think about.

Similarly, I will think whether we will give hints to support both
configuration styles at the same time. In the end, we do not intend to
ship apache2 2.2 in Wheezy.

- -- 
with kind regards,
Arno Töll
IRC: daemonkeeper on Freenode/OFTC
GnuPG Key-ID: 0x9D80F36D
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.11 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iQIcBAEBAgAGBQJPaxmlAAoJEMcrUe6dgPNtCZQP+QFl2PhCZ1bKXfz50crAGn5S
nLS4rDTY1xJDV0d+OL7o+ecYyK3l6FSD1QW7L1XSZ03K1MtG1AJx9zxNK2BCV6cQ
V+tyFFArgLK8iXKuXJDbma9XIxkTFXmIwYgE6I1+rsrfKb4pjqXn7JJOh7ZrfNU3
stjJzN+bSgUKUwQEXUogoDYHGs4ED6gUmK9NoU2zaN5Y8WuB1T/it5U8f+4rNEhb
XCuZLYnTeQzt6OuQsMHJaSFz/pO3zobhu9sSQJLPmzbNtEuGOYOO5HP22WeDbQHS
SEK3YtTQXCsjJHOAo4XPBJ27i9LGBdQ4xai3Xclfbiiz+ggNboCSdY3maYA4OqSW
ApWuWd/S6jFN6A24fSWPUoRmLYCHBpM8thZNiKLqL+V6dCHrqagGq1xZWpmKxksI
0407HidM4JAhY2sN4w3/6jysoWCDtdeonjX7ZdRWdOryonWFCzjYTm/YPZnUSfP+
l4/fAnQHLI0LSk5b0uBpwY1/sqRKGUbnyg3ndSLNnseBrHbkmiyzEjBnqIvGPD08
Br235WVgZ3Ye2mqtqZGJHyocn9mXPmwxxGjFqR5hk0R4jTBbBASogOHEQcAxJPnm
HnDXaS18MSiCZdmeGOq2zdDmYaoon9/WfkOWwS53x+/kHUvQIXYwr0zdwd9nyWGi
q2ljL6386hTnsW1ib+K1
=Rwvk
-----END PGP SIGNATURE-----



Reply to: