Spaces:
Runtime error
Runtime error
Docker updated
Browse files- Dockerfile +33 -16
Dockerfile
CHANGED
@@ -1,30 +1,47 @@
|
|
1 |
-
FROM python:3.9-slim
|
2 |
|
3 |
-
# Install system dependencies
|
4 |
-
RUN apt-get update && \
|
5 |
-
|
6 |
|
7 |
-
# Create a non-root user
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
8 |
RUN useradd -m -u 1000 user
|
9 |
USER user
|
10 |
-
|
11 |
-
# Set environment variables
|
12 |
ENV HOME=/home/user \
|
13 |
PATH=/home/user/.local/bin:$PATH
|
14 |
-
|
15 |
-
# Set working directory
|
16 |
WORKDIR $HOME/app
|
17 |
-
|
18 |
-
# Copy requirements file and install dependencies
|
19 |
COPY --chown=user . $HOME/app
|
20 |
-
COPY ./requirements.txt
|
21 |
-
|
22 |
-
RUN pip install --user -r requirements.txt
|
23 |
-
|
24 |
-
# Copy application code
|
25 |
COPY . .
|
|
|
26 |
|
27 |
EXPOSE 7860
|
28 |
|
29 |
# Command to run the application
|
30 |
CMD ["chainlit", "run", "app.py", "--port", "7860"]
|
|
|
|
|
|
|
|
1 |
+
# FROM python:3.9-slim
|
2 |
|
3 |
+
# # Install system dependencies
|
4 |
+
# RUN apt-get update && \
|
5 |
+
# apt-get install -y build-essential gfortran
|
6 |
|
7 |
+
# # Create a non-root user
|
8 |
+
# RUN useradd -m -u 1000 user
|
9 |
+
# USER user
|
10 |
+
|
11 |
+
# # Set environment variables
|
12 |
+
# ENV HOME=/home/user \
|
13 |
+
# PATH=/home/user/.local/bin:$PATH
|
14 |
+
|
15 |
+
# # Set working directory
|
16 |
+
# WORKDIR $HOME/app
|
17 |
+
|
18 |
+
# # Copy requirements file and install dependencies
|
19 |
+
# COPY --chown=user . $HOME/app
|
20 |
+
# COPY ./requirements.txt $HOME/app/requirements.txt
|
21 |
+
|
22 |
+
# RUN pip install --user -r requirements.txt
|
23 |
+
|
24 |
+
# # Copy application code
|
25 |
+
# COPY . .
|
26 |
+
|
27 |
+
# # Command to run the application
|
28 |
+
# CMD ["chainlit", "run", "app.py", "--port", "7860"]
|
29 |
+
FROM python:3.11
|
30 |
RUN useradd -m -u 1000 user
|
31 |
USER user
|
|
|
|
|
32 |
ENV HOME=/home/user \
|
33 |
PATH=/home/user/.local/bin:$PATH
|
|
|
|
|
34 |
WORKDIR $HOME/app
|
|
|
|
|
35 |
COPY --chown=user . $HOME/app
|
36 |
+
COPY ./requirements.txt ~/app/requirements.txt
|
37 |
+
RUN pip install -r requirements.txt
|
|
|
|
|
|
|
38 |
COPY . .
|
39 |
+
<<<<<<< HEAD
|
40 |
|
41 |
EXPOSE 7860
|
42 |
|
43 |
# Command to run the application
|
44 |
CMD ["chainlit", "run", "app.py", "--port", "7860"]
|
45 |
+
=======
|
46 |
+
CMD ["chainlit", "run", "app.py", "--port", "7860"]
|
47 |
+
>>>>>>> dac2a52 (Docker updated)
|