[Xapian-discuss] debs missing query templates
james-xapian at tartarus.org
Tue Nov 23 19:45:20 GMT 2004
On Tue, Nov 23, 2004 at 07:08:34PM +0000, Olly Betts wrote:
> We ought to adhere to the FHS unless there's a good reason not to.
Grudgingly, I have to agree. (The main reason I don't like /var/www,
incidentally, is that I know of no one who wouldn't prefer to provide
virtual servers, meaning they'd have to create another directory
elsewhere. /var/www isn't helpful as a default, because you don't get
a helpful default in there - at least with Debian's apache, all the
useful bits are supplied by other modules and put in there using Alias
commands. So you end up with this pointless directory that some more
feeble packages and programs somehow think it's useful to dump stuff
in there and then expect to be able to access it from any website that
/usr/lib/cgi-bin is accessible from - which is, by default,
> /usr is the second major section of the filesystem. /usr is
> shareable, read-only data.
> Users will typically want to customise the omega templates or add their
> own - they aren't read-only data.
> Users should never need to modify files in /var/lib to configure a
> package's operation.
> Although if you want to nitpick, you could argue that you never *need*
> to edit the templates.
Users should never have to look inside /var/lib. Looking on ixion, it
contains saved state (although usually regeneratable), and things like
Firefox components, emacs lock files, and so on. (Why lockfiles aren't
in /var/lock I don't know.)
You could make an argument that templates are like Firefox components,
but not a terribly good one.
> /etc is the FHS place for configuration files, though these templates
> aren't exactly configuration - they're much more akin to PHP or SSI web
> pages than apache's httpd.conf.
/etc/xapian-omega.conf makes sense. I'm really not sure that other
things do - it strikes me as being too like the old way of bunging
everything in /etc. I think Slackware used to do this, and it confused
the hell out of me.
> FHS 2.3 suggests "/srv" for "site-specific data which is served by this
> system", such as web pages, CVS, etc. Not sure I really agree with them
> inventing practice rather than documenting it, but that's not in FHS 2.1
I actually approve of the idea (just not the name, which is mindlessly
> So I don't know, really. I tend to think they belong in a comparable
> place to where web pages live. That's typically /var/www for Linux
> distributions, so /var/lib/xapian-omega is probably the answer for
Sigh. For linux distributions, perhaps. It makes documenting Omega
harder though, because there's no way we want to put them there on,
for instance, Solaris. That can be resolved with care.
I note that htdig puts:
* databases in /var/lib/htdig (which I agree with)
* core config in /etc/htdig/htdig.conf
* aux dbs (synonyms etc.) in /usr/lib/htdig (apparently they get
built once on install/upgrade)
* images in /var/www/htdig (which is different to the way that many
other packages do it)
* htsearch itself in /usr/lib/cgi-bin
* puts some .html files (which are effectively templates for search
results) in /etc/htdig ... then I get a little confused, because it
uses them from $common_dir, which /seems/ to be set to /etc/htdig -
but it also uses the synonym db from there and not from
/usr/lib/htdig as it claims it will build them to
So if we follow htdig, we may want to put them in
/etc/xapian-omega. But I'm not 100% sure I don't believe that the
packaging of htdig isn't ... odd.
> > We don't want to install godmode by default, for instance.
> There's not actually any harm in installing the godmode template - it
> doesn't reveal secret information or allow you to write to the database
> or anything. It just allows you to inspect a raw view of a document,
> which can be a handy debugging tool (or would be if I finished writing
> it!) so it's arguably useful to have it available by default.
True, perhaps. I'd say we don't want to install it unless it's
pretty useful. I could never get it to do anything helpful to me, but
perhaps that was just me.
James Aylett xapian.org
james at tartarus.org uncertaintydivision.org
More information about the Xapian-discuss