mirror of
https://github.com/gsi-upm/senpy
synced 2024-11-24 00:52:28 +00:00
Fix for heroku
This commit is contained in:
parent
03eb38c12d
commit
39761e0922
2
Procfile
2
Procfile
@ -1 +1 @@
|
|||||||
web: gunicorn app:app --log-file=-
|
web: python -m senpy --host 0.0.0.0 --port $PORT --default-plugins
|
||||||
|
@ -32,6 +32,8 @@ import senpy
|
|||||||
|
|
||||||
patch_all(thread=False)
|
patch_all(thread=False)
|
||||||
|
|
||||||
|
SERVER_PORT = os.environ.get("PORT", 5000)
|
||||||
|
|
||||||
def main():
|
def main():
|
||||||
parser = argparse.ArgumentParser(description='Run a Senpy server')
|
parser = argparse.ArgumentParser(description='Run a Senpy server')
|
||||||
parser.add_argument('--level',
|
parser.add_argument('--level',
|
||||||
@ -56,7 +58,7 @@ def main():
|
|||||||
parser.add_argument('--port',
|
parser.add_argument('--port',
|
||||||
'-p',
|
'-p',
|
||||||
type=int,
|
type=int,
|
||||||
default=5000,
|
default=SERVER_PORT,
|
||||||
help='Port to listen on.')
|
help='Port to listen on.')
|
||||||
parser.add_argument('--plugins-folder',
|
parser.add_argument('--plugins-folder',
|
||||||
'-f',
|
'-f',
|
||||||
|
Loading…
Reference in New Issue
Block a user