mirror of
https://github.com/outbackdingo/patroni.git
synced 2026-08-25 14:53:37 +00:00
Configure listen address for restapi via a yaml file
This commit is contained in:
+2
-1
@@ -86,7 +86,8 @@ def main():
|
||||
governor = Governor(config)
|
||||
try:
|
||||
governor.initialize()
|
||||
RestApiServer(governor).start()
|
||||
host, port = config['restapi']['listen'].split(':')
|
||||
RestApiServer(governor, host, port).start()
|
||||
governor.run()
|
||||
finally:
|
||||
governor.touch_member(300) # schedule member removal
|
||||
|
||||
@@ -1,4 +1,6 @@
|
||||
loop_wait: 10
|
||||
restapi:
|
||||
listen: 127.0.0.1:8008
|
||||
etcd:
|
||||
scope: batman
|
||||
ttl: 30
|
||||
|
||||
@@ -1,4 +1,6 @@
|
||||
loop_wait: 10
|
||||
restapi:
|
||||
listen: 127.0.0.1:8009
|
||||
etcd:
|
||||
scope: batman
|
||||
ttl: 30
|
||||
|
||||
Reference in New Issue
Block a user