Brozy123 commited on
Commit
2078b09
·
verified ·
1 Parent(s): 2f95855

Create app.py

Browse files
Files changed (1) hide show
  1. app.py +19 -0
app.py ADDED
@@ -0,0 +1,19 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ from flask import Flask, send_from_directory
2
+
3
+ app = Flask(__name__, static_folder='.', static_url_path='/')
4
+
5
+ @app.route('/')
6
+ def index():
7
+ return send_from_directory('.', 'dashboard.html')
8
+
9
+ @app.route('/league')
10
+ def league():
11
+ return send_from_directory('.', 'league.html')
12
+
13
+ @app.route('/<path:path>')
14
+ def static_proxy(path):
15
+ # Serve static files (images, js, css) if referenced
16
+ return send_from_directory('.', path)
17
+
18
+ if __name__ == '__main__':
19
+ app.run(host='0.0.0.0', port=7860)