-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathmain.py
42 lines (32 loc) · 807 Bytes
/
main.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
# std
import os
import logging
# third party
from dash import html, dcc
# project
from app import app
from layout.dashboard import dashboard_layout, sidebar
logging.info("Setting main layout")
# main layout of the index page
app.index_string = """
<!DOCTYPE html>
<html>
<head>
{%metas%}
<title>PODS Dashboard</title>
{%favicon%}
{%css%}
</head>
<body>
{%app_entry%}
<footer>
{%config%}
{%scripts%}
{%renderer%}
</footer>
</body>
</html>
"""
app.layout = html.Div([dcc.Location(id="url"), dashboard_layout], style = {'margin':'25px'})
if __name__ == "__main__":
app.run_server(host="0.0.0.0", debug=False, port=os.environ.get("PORT", 8080))