git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [PATCH] gitweb: Use GITWEB_CONFIG_SYSTEM even if GITWEB_CONFIG does exist

From
Jonathan Nieder <jrnieder@gmail.com>
Date
May 14, 2011, 21:06 UTC
Message-ID
<20110514210603.GA11502@elie>
In-Reply-To
<201105142137.16541.jnareb@gmail.com>
Jakub Narebski wrote:
> If per-instance configuration file exists, then system-wide
> configuration was _not used at all_.  This is quite untypical and
> suprising behavior.

I agree. How to avoid breaking existing installations, though? (I'm especially worried because distro packages tend to ship their own /etc/gitweb.conf, so the admin might not even know about what's there.) For example, depending on the content of /etc/gitweb.conf, this has the potential to break "git instaweb".

It could be simpler to document that users should put
	do $GITWEB_CONFIG_SYSTEM;

at the start of gitweb_config.conf to reuse options from the system configuration file and override them. But that's not very satisfying, since I don't see a nice way to move to a better behavior after that without breaking some existing installations. (It would be possible to check for a new ./gitweb-config-in-addition-to-what-was-in-etc.conf file but that doesn't seem so nice.)

If this were a command-line tool, I would be happy as long as there is some way to prevent reading /etc/gitweb.conf through the environment. For a webapp I don't know how easy it is to set environment variables typically. So thoughts from people in that corner of the world would be interesting.

Previous: Jakub NarebskiNext: Jakub Narebski
Message 2 of 8 in “gitweb: Use GITWEB_CONFIG_SYSTEM even if GITWEB_CONFIG does exist”
  1. gitweb: Use GITWEB_CONFIG_SYSTEM even if GITWEB_CONFIG does existJakub Narebski, May 14, 2011
  2. Jonathan NiederMay 14, 2011
  3. Jakub NarebskiMay 15, 2011
  4. [PATCHv2] gitweb: Use GITWEB_CONFIG_SYSTEM even if GITWEB_CONFIG does existJakub Narebski, May 16, 2011
  5. Junio C HamanoMay 17, 2011
  6. Drew NorthupMay 17, 2011
  7. Junio C HamanoMay 17, 2011
  8. Drew NorthupMay 16, 2011

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.