Spaces:
Sleeping
Sleeping
Update Dockerfile
Browse files- Dockerfile +4 -17
Dockerfile
CHANGED
@@ -1,32 +1,19 @@
|
|
1 |
# Dockerfile
|
2 |
|
3 |
-
# Use an official Python runtime as a parent image
|
4 |
FROM python:3.11-slim
|
5 |
-
|
6 |
-
# Set the working directory in the container
|
7 |
WORKDIR /code
|
8 |
|
9 |
-
# Prevent Python from writing pyc files to disc
|
10 |
ENV PYTHONDONTWRITEBYTECODE 1
|
11 |
-
# Ensure Python output is sent straight to terminal without buffering
|
12 |
ENV PYTHONUNBUFFERED 1
|
13 |
|
14 |
-
# --->
|
15 |
-
# Set a writable cache directory for Composio inside the
|
16 |
-
ENV COMPOSIO_CACHE_DIR=/
|
17 |
-
# ---> END OF
|
18 |
|
19 |
-
# Copy the requirements file into the container at /code
|
20 |
COPY requirements.txt .
|
21 |
-
|
22 |
-
# Install any needed packages specified in requirements.txt
|
23 |
RUN pip install --no-cache-dir --upgrade -r requirements.txt
|
24 |
-
|
25 |
-
# Copy the rest of the application code into the container at /code
|
26 |
COPY . /code
|
27 |
|
28 |
-
# Expose the port the app runs on
|
29 |
EXPOSE 7860
|
30 |
-
|
31 |
-
# Define the command to run the application
|
32 |
CMD ["uvicorn", "app:app", "--host", "0.0.0.0", "--port", "7860"]
|
|
|
1 |
# Dockerfile
|
2 |
|
|
|
3 |
FROM python:3.11-slim
|
|
|
|
|
4 |
WORKDIR /code
|
5 |
|
|
|
6 |
ENV PYTHONDONTWRITEBYTECODE 1
|
|
|
7 |
ENV PYTHONUNBUFFERED 1
|
8 |
|
9 |
+
# ---> MODIFIED LINE <---
|
10 |
+
# Set a writable cache directory for Composio inside the temporary directory
|
11 |
+
ENV COMPOSIO_CACHE_DIR=/tmp/.composio
|
12 |
+
# ---> END OF MODIFIED LINE <---
|
13 |
|
|
|
14 |
COPY requirements.txt .
|
|
|
|
|
15 |
RUN pip install --no-cache-dir --upgrade -r requirements.txt
|
|
|
|
|
16 |
COPY . /code
|
17 |
|
|
|
18 |
EXPOSE 7860
|
|
|
|
|
19 |
CMD ["uvicorn", "app:app", "--host", "0.0.0.0", "--port", "7860"]
|