mirror of
https://github.com/tahoe-lafs/tahoe-lafs.git
synced 2025-04-13 22:03:04 +00:00
clients now get the queen's pburl from a file named roster_pburl, not hardcoded in the .tac file
This commit is contained in:
parent
a3700cc582
commit
5be5230767
@ -23,6 +23,7 @@ class Client(node.Node, Referenceable):
|
||||
STOREDIR = 'storage'
|
||||
NODETYPE = "client"
|
||||
WEBPORTFILE = "webport"
|
||||
QUEEN_PBURL_FILE = "roster_pburl"
|
||||
|
||||
def __init__(self, basedir="."):
|
||||
node.Node.__init__(self, basedir)
|
||||
@ -40,6 +41,11 @@ class Client(node.Node, Referenceable):
|
||||
f.close()
|
||||
self.add_service(WebishServer(webport))
|
||||
self.queen_pburl = None
|
||||
QUEEN_PBURL_FILE = os.path.join(self.basedir, self.QUEEN_PBURL_FILE)
|
||||
if os.path.exists(QUEEN_PBURL_FILE):
|
||||
f = open(QUEEN_PBURL_FILE, "r")
|
||||
self.queen_pburl = f.read().strip()
|
||||
f.close()
|
||||
self.queen_connector = None
|
||||
|
||||
def tub_ready(self):
|
||||
|
@ -3,11 +3,7 @@
|
||||
from allmydata import client
|
||||
from twisted.application import service
|
||||
|
||||
queen_pburl = "pb://jekyv6ghn7zinppk7wcvfmk7o4gw76hb@192.168.1.101:42552/roster"
|
||||
yumyum_queen = "pb://cznyjh2pi4bybn3g7pi36bdfnwz356vk@192.168.1.98:56510/roster"
|
||||
c = client.Client()
|
||||
c.set_queen_pburl(yumyum_queen)
|
||||
#c.set_queen_pburl(queen_pburl)
|
||||
|
||||
application = service.Application("allmydata_client")
|
||||
c.setServiceParent(application)
|
||||
|
Loading…
x
Reference in New Issue
Block a user