Browse Source

Set port on config

master
Alfred 1 year ago
parent
commit
b660510afa
2 changed files with 2 additions and 1 deletions
  1. 1
    0
      config.py
  2. 1
    1
      run.py

+ 1
- 0
config.py View File

@@ -17,3 +17,4 @@ SQLALCHEMY_DATABASE_URI = 'sqlite:///' + os.path.join(basedir, 'database.db')
17 17
 
18 18
 ENV = 'development'
19 19
 SQLALCHEMY_TRACK_MODIFICATIONS = False
20
+PORT = 5001

+ 1
- 1
run.py View File

@@ -5,4 +5,4 @@ from app import app, initialize_app
5 5
 
6 6
 if __name__ == '__main__':
7 7
     initialize_app()
8
-    app.run()
8
+    app.run(port=app.config.get('PORT', 5000))

Loading…
Cancel
Save