Restore port config for 3.1

This commit is contained in:
Carl Allen
2017-09-27 15:15:19 -05:00
parent 547804be2b
commit 707a576e16
2 changed files with 8 additions and 2 deletions
+5 -1
View File
@@ -304,7 +304,11 @@ class CraftBeerPI(object):
self.sensor.init()
self.actor.init()
self.beep()
self._socketio.run(self._app, host='0.0.0.0', port=5000)
try:
port = int(cbpi.get_config_parameter('port', '5000'))
except ValueError:
port = 5000
self._socketio.run(self._app, host='0.0.0.0', port=port)
def beep(self):
self.buzzer.beep()