Skip to content

Commit f6c2e94

Browse files
committed
deployment ready
1 parent 38b89c2 commit f6c2e94

File tree

4 files changed

+22
-4
lines changed

4 files changed

+22
-4
lines changed

src/app.py

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,4 @@ def index():
7272
optimized_time=optimized_time,
7373
num_clusters=len(lsra_optimized.clusters)
7474
)
75-
return render_template("index.html")
76-
77-
if __name__ == "__main__":
78-
app.run(debug=True)
75+
return render_template("index.html")

src/index.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
from wsgi import app

src/vercel.json

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
{
2+
"version":2,
3+
"builds": [
4+
{
5+
"src":"./index.py",
6+
"use": "@vercel/python",
7+
"config":{"runtime":"python3.8"}
8+
}
9+
],
10+
"routes": [
11+
{
12+
"src":"/(.*)",
13+
"dest":"/"
14+
}
15+
]
16+
}

src/wsgi.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
from app import app
2+
3+
if __name__ == '__main__':
4+
app.run(debug=True)

0 commit comments

Comments
 (0)