Spaces:
Running
Running
Upload folder using huggingface_hub
Browse files- Dockerfile +2 -2
- __pycache__/app.cpython-311.pyc +0 -0
- __pycache__/keepalive.cpython-311.pyc +0 -0
- keepalive.py +2 -2
Dockerfile
CHANGED
@@ -10,5 +10,5 @@ COPY --chown=user ./requirements.txt requirements.txt
|
|
10 |
RUN pip install --no-cache-dir --upgrade -r requirements.txt
|
11 |
|
12 |
COPY --chown=user . /app
|
13 |
-
CMD ["python", "app.py", "
|
14 |
-
CMD ["uvicorn", "app
|
|
|
10 |
RUN pip install --no-cache-dir --upgrade -r requirements.txt
|
11 |
|
12 |
COPY --chown=user . /app
|
13 |
+
CMD ["python", "app.py", "&"]
|
14 |
+
CMD ["uvicorn", "keepalive:app", "--host", "0.0.0.0", "--port", "7860"]
|
__pycache__/app.cpython-311.pyc
ADDED
Binary file (8.78 kB). View file
|
|
__pycache__/keepalive.cpython-311.pyc
ADDED
Binary file (473 Bytes). View file
|
|
keepalive.py
CHANGED
@@ -1,7 +1,7 @@
|
|
1 |
from fastapi import FastAPI
|
2 |
|
3 |
-
|
4 |
|
5 |
-
@
|
6 |
def root():
|
7 |
return {"Hello": "World"}
|
|
|
1 |
from fastapi import FastAPI
|
2 |
|
3 |
+
app = FastAPI()
|
4 |
|
5 |
+
@app.get("/")
|
6 |
def root():
|
7 |
return {"Hello": "World"}
|