config start
This commit is contained in:
parent
92d48993e7
commit
6044cbb271
3 changed files with 11 additions and 2 deletions
7
.gitignore
vendored
7
.gitignore
vendored
|
@ -1,5 +1,5 @@
|
|||
|
||||
|
||||
.vscode/settings.json
|
||||
|
||||
__pycache__/
|
||||
|
||||
|
@ -10,6 +10,7 @@ state/
|
|||
build/build-exe-config.json
|
||||
|
||||
install/*.exe
|
||||
install/nssm
|
||||
|
||||
*.pyo
|
||||
|
||||
|
@ -20,3 +21,7 @@ build/build-exe-pyinstaller-command.bat
|
|||
build/build/BAPSicle/
|
||||
|
||||
build/output/
|
||||
|
||||
venv/
|
||||
|
||||
config.py
|
3
config.py.example
Normal file
3
config.py.example
Normal file
|
@ -0,0 +1,3 @@
|
|||
# Flask Details
|
||||
HOST: str = "localhost"
|
||||
PORT: int = 5000
|
|
@ -4,6 +4,7 @@ from flask import Flask, render_template, send_from_directory, request
|
|||
import json
|
||||
import sounddevice as sd
|
||||
import setproctitle
|
||||
import config
|
||||
|
||||
setproctitle.setproctitle("BAPSicle - Server")
|
||||
|
||||
|
@ -174,7 +175,7 @@ def startServer():
|
|||
channel_p[channel].start()
|
||||
|
||||
# Don't use reloader, it causes Nested Processes!
|
||||
app.run(host='0.0.0.0', port=5000, debug=True, use_reloader=False)
|
||||
app.run(host=config.HOST, port=config.PORT, debug=True, use_reloader=False)
|
||||
|
||||
|
||||
def stopServer():
|
||||
|
|
Loading…
Reference in a new issue