Spaces:
Sleeping
Sleeping
Update Dockerfile
Browse files- Dockerfile +7 -2
Dockerfile
CHANGED
|
@@ -1,12 +1,16 @@
|
|
| 1 |
# Use your base Docker image from Docker Hub
|
| 2 |
FROM circulartextapp/circulartextai
|
| 3 |
|
| 4 |
-
|
| 5 |
-
|
|
|
|
| 6 |
|
| 7 |
# Set the working directory
|
| 8 |
WORKDIR /code
|
| 9 |
|
|
|
|
|
|
|
|
|
|
| 10 |
# Copy the requirements file and install dependencies
|
| 11 |
COPY ./requirements.txt /code/requirements.txt
|
| 12 |
RUN pip install --no-cache-dir --upgrade -r /code/requirements.txt
|
|
@@ -25,3 +29,4 @@ RUN chmod +x /entrypoint.sh
|
|
| 25 |
|
| 26 |
# Specify the entrypoint
|
| 27 |
ENTRYPOINT ["/entrypoint.sh"]
|
|
|
|
|
|
| 1 |
# Use your base Docker image from Docker Hub
|
| 2 |
FROM circulartextapp/circulartextai
|
| 3 |
|
| 4 |
+
|
| 5 |
+
# Create a non-root user
|
| 6 |
+
RUN adduser --disabled-password --gecos '' appuser
|
| 7 |
|
| 8 |
# Set the working directory
|
| 9 |
WORKDIR /code
|
| 10 |
|
| 11 |
+
# Switch to the appuser
|
| 12 |
+
USER appuser
|
| 13 |
+
|
| 14 |
# Copy the requirements file and install dependencies
|
| 15 |
COPY ./requirements.txt /code/requirements.txt
|
| 16 |
RUN pip install --no-cache-dir --upgrade -r /code/requirements.txt
|
|
|
|
| 29 |
|
| 30 |
# Specify the entrypoint
|
| 31 |
ENTRYPOINT ["/entrypoint.sh"]
|
| 32 |
+
|