mirror of
https://github.com/tahoe-lafs/tahoe-lafs.git
synced 2025-01-18 10:46:24 +00:00
add a --helper command-line option to 'tahoe create-node'
This commit is contained in:
parent
ba5f44354b
commit
eb0a582d1c
@ -207,6 +207,7 @@ def _create_node(reactor, request, temp_dir, introducer_furl, flog_gatherer, nam
|
||||
'--shares-needed', unicode(needed),
|
||||
'--shares-happy', unicode(happy),
|
||||
'--shares-total', unicode(total),
|
||||
'--helper',
|
||||
]
|
||||
if not storage:
|
||||
args.append('--no-storage')
|
||||
|
@ -180,6 +180,7 @@ class CreateNodeOptions(CreateClientOptions):
|
||||
optFlags = [
|
||||
("no-storage", None, "Do not offer storage service to other nodes."),
|
||||
("storage-dir", None, "Path where the storage will be placed."),
|
||||
("helper", None, "Enable helper"),
|
||||
] + TOR_FLAGS + I2P_FLAGS
|
||||
|
||||
synopsis = "[options] [NODEDIR]"
|
||||
@ -334,7 +335,10 @@ def write_client_config(c, config):
|
||||
|
||||
c.write("[helper]\n")
|
||||
c.write("# Shall this node run a helper service that clients can use?\n")
|
||||
c.write("enabled = false\n")
|
||||
if config.get("helper"):
|
||||
c.write("enabled = true\n")
|
||||
else:
|
||||
c.write("enabled = false\n")
|
||||
c.write("\n")
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user