Closed T81 closed 7 years ago
Are you passing the host
keyword argument into socketio.run()
as well?
socketio.run(app, host='192.168.1.5')
did the trick!
app = create_app(debug=True)
in chat.py
remains as is, it does not need the host
argument passed
Thank you Miguel!
P.S Why app = create_app(debug=True)
in chat.py
enables the debugger but app = create_app(host='192.168.1.5', debug=True)
does not change the host?
The create_app
function passes the debug
setting through to the flask app it creates. It does not do the same with host
, but you can easily add that functionality if you need it.
Hi Miguel, I'm trying to change the default host (127.0.0.1) to e.g 192.168.1.5 Following the next steps I still get wsgi starting up on http://_127.0.0.1_:5000 when I run the app
Edit: /app/init.py Change:
def create_app(debug=False):
todef create_app(host=None, debug=False):
Add:app.host = host
to the above function (above app.debug)Edit: /chat.py Change:
app = create_app(debug=True)
toapp = create_app(host='192.168.1.5', debug=True)
What am I missing?