Spaces:
Sleeping
Sleeping
Commit ·
c5adc31
1
Parent(s): acd0013
refactor: move to server.app entrypoint
Browse files- Dockerfile +1 -1
- openenv.yaml +1 -1
- pyproject.toml +7 -11
- server7860.py → server/app.py +1 -1
Dockerfile
CHANGED
|
@@ -10,4 +10,4 @@ COPY . .
|
|
| 10 |
|
| 11 |
RUN pip install --no-cache-dir -r requirements.txt
|
| 12 |
|
| 13 |
-
CMD ["uvicorn", "
|
|
|
|
| 10 |
|
| 11 |
RUN pip install --no-cache-dir -r requirements.txt
|
| 12 |
|
| 13 |
+
CMD ["uvicorn", "server.app:app", "--host", "0.0.0.0", "--port", "7860"]
|
openenv.yaml
CHANGED
|
@@ -8,7 +8,7 @@ version: 1.0
|
|
| 8 |
# =========================
|
| 9 |
# ENTRYPOINT
|
| 10 |
# =========================
|
| 11 |
-
entry_point:
|
| 12 |
|
| 13 |
# =========================
|
| 14 |
# INTERFACE
|
|
|
|
| 8 |
# =========================
|
| 9 |
# ENTRYPOINT
|
| 10 |
# =========================
|
| 11 |
+
entry_point: server.app:app
|
| 12 |
|
| 13 |
# =========================
|
| 14 |
# INTERFACE
|
pyproject.toml
CHANGED
|
@@ -1,20 +1,16 @@
|
|
| 1 |
[project]
|
| 2 |
-
name = "openenv-customer-support
|
| 3 |
version = "0.1.0"
|
| 4 |
-
description = "Customer Support Agent OpenEnv Environment"
|
| 5 |
-
authors = [
|
| 6 |
-
{ name = "P Matlani" }
|
| 7 |
-
]
|
| 8 |
dependencies = [
|
| 9 |
"fastapi",
|
| 10 |
"uvicorn",
|
| 11 |
-
"pydantic"
|
|
|
|
| 12 |
]
|
| 13 |
|
|
|
|
|
|
|
|
|
|
| 14 |
[build-system]
|
| 15 |
requires = ["setuptools", "wheel"]
|
| 16 |
-
build-backend = "setuptools.build_meta"
|
| 17 |
-
|
| 18 |
-
[tool.setuptools.packages.find]
|
| 19 |
-
where = ["."]
|
| 20 |
-
|
|
|
|
| 1 |
[project]
|
| 2 |
+
name = "openenv-customer-support"
|
| 3 |
version = "0.1.0"
|
|
|
|
|
|
|
|
|
|
|
|
|
| 4 |
dependencies = [
|
| 5 |
"fastapi",
|
| 6 |
"uvicorn",
|
| 7 |
+
"pydantic",
|
| 8 |
+
"openenv-core>=0.2.0"
|
| 9 |
]
|
| 10 |
|
| 11 |
+
[project.scripts]
|
| 12 |
+
server = "server.app:app"
|
| 13 |
+
|
| 14 |
[build-system]
|
| 15 |
requires = ["setuptools", "wheel"]
|
| 16 |
+
build-backend = "setuptools.build_meta"
|
|
|
|
|
|
|
|
|
|
|
|
server7860.py → server/app.py
RENAMED
|
@@ -1,5 +1,5 @@
|
|
| 1 |
|
| 2 |
-
#
|
| 3 |
|
| 4 |
from fastapi import FastAPI
|
| 5 |
from pydantic import BaseModel
|
|
|
|
| 1 |
|
| 2 |
+
# server.py
|
| 3 |
|
| 4 |
from fastapi import FastAPI
|
| 5 |
from pydantic import BaseModel
|