#518 closed enhancement (fixed)

'tahoe.cfg': replace (multiple) configuration files with a single file

Reported by: warner Owned by:
Priority: major Milestone: 1.3.0
Component: code-nodeadmin Version: 1.2.0
Keywords: configuration Cc:
Launchpad Bug:

Description

I seem to remember somebody complaining that Tahoe's configuration knobs were too confusing because they were spread out into multiple files. I did it that way because 1) I'm kind of a fan of the qmail approach: simple-to-parse files that only have one purpose, and 2) it makes the allmydata.com client-side configuration a bit easier (drop a file into place rather than edit some file to include some line).

But it might make sense to condense most of the existing config files into a single one. This would be a ConfigParser -style file (aka .ini file), something kind of like:

[tahoe]
introducer.furl = pb://....
nickname = John Doe's Computer
client.port = 12345
webport = localhost:8123
advertised_ip_addresses = ...

[client]
helper.furl = pb://...
encoding.k = 3
encoding.N = 10

[storage]
no_storage = false
sizelimit = 5GB

[services]
client = true
helper = false
introducer = false
key-generator = false

The rule would be that the node will never ever write to tahoe.cfg . There are a handful of config knobs that are read-write (like client.port), but for most of them I think we can say that the value in tahoe.cfg takes precedence, and the node will write the value to a separate BASEDIR/client.port just to handle the (common) case where tahoe.cfg doesn't specify a portnum. 'secret' and 'convergence_secret' fall into this same category.

Some other config knobs have larger values (like authorized_keys.SSHPORT); I think those can be left as separate files.

If implemented, we'd be careful to retain backwards-compatibility with the values currently stored in distinct files. If the value isn't specified in tahoe.cfg, it will be looked up in the appropriate BASEDIR/file.

Change History (1)

comment:1 Changed at 2008-09-30T23:40:47Z by warner

  • Milestone changed from undecided to 1.3.0
  • Resolution set to fixed
  • Status changed from new to closed

Done, in cd26f583057dabe8. See source:docs/configuration.txt for the list of keys. Any old-style separate files will take precedence over the values in the new 'tahoe.cfg', except for the client.port/introducer.port (for which the tahoe.cfg [node]tub.port value takes precedence).

Note: See TracTickets for help on using tickets.