mirror of
https://github.com/FAUSheppy/skillbird
synced 2025-12-06 06:51:34 +01:00
make http api port configurable
This commit is contained in:
@@ -29,6 +29,8 @@ parser.add_argument('--cache-file', dest='cacheFile',\
|
||||
help="A cache file which makes restarting the system fast")
|
||||
parser.add_argument('--ffa', action='store_const', default=False, const=True, \
|
||||
help="Use the free-for-all parser")
|
||||
parser.add_argument('--http-api-port', default=5000, \
|
||||
help="Port to use for http-api port")
|
||||
|
||||
if __name__ == "__main__":
|
||||
args = parser.parse_args()
|
||||
@@ -49,7 +51,7 @@ if __name__ == "__main__":
|
||||
|
||||
if not args.parse_only:
|
||||
print("Starting network-listener(s)")
|
||||
Thread(target=httpAPI.app.run).start()
|
||||
Thread(target=httpAPI.app.run,kwargs={'port':args.http_api_port}).start()
|
||||
NetworkListener.listen()
|
||||
else:
|
||||
sys.exit(0)
|
||||
|
||||
Reference in New Issue
Block a user