Skip to content

Commit 73cd3b2

Browse files
committed
fix : Vercel 환경구성 변경
1 parent 5e6f9ca commit 73cd3b2

File tree

4 files changed

+4
-7
lines changed

4 files changed

+4
-7
lines changed

api/index.py renamed to api/server.py

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,3 @@ def handler(event, context):
2121
request = Request(event)
2222
response = Response.from_app(dispatcher, request.environ)
2323
return response(environ=None, start_response=lambda *args: None)
24-
25-
26-
if __name__ == "__main__":
27-
app.run(debug=True, port=5000)

index.py

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

run.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
from api.index import app
1+
from api.server import app
22

33
if __name__ == "__main__":
44
app.run(debug=True, port=5000)

vercel.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
"version": 2,
33
"builds": [
44
{
5-
"src": "api/index.py",
5+
"src": "./index.py",
66
"use": "@vercel/python",
77
"config": {
88
"runtime": "python3.12"
@@ -12,7 +12,7 @@
1212
"routes": [
1313
{
1414
"src": "/(.*)",
15-
"dest": "api/index.py"
15+
"dest": "/"
1616
}
1717
]
1818
}

0 commit comments

Comments
 (0)