Spaces:
Runtime error
Runtime error
Update Dockerfile
Browse files- Dockerfile +8 -2
Dockerfile
CHANGED
|
@@ -8,8 +8,14 @@ RUN pip install --no-cache-dir --upgrade -r /code/requirements.txt
|
|
| 8 |
|
| 9 |
RUN apt-get update && apt-get install ffmpeg libsm6 libxext6 -y
|
| 10 |
|
| 11 |
-
|
| 12 |
-
RUN
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 13 |
|
| 14 |
COPY . .
|
| 15 |
|
|
|
|
| 8 |
|
| 9 |
RUN apt-get update && apt-get install ffmpeg libsm6 libxext6 -y
|
| 10 |
|
| 11 |
+
# Create a user and group with specific UID and GID
|
| 12 |
+
RUN groupadd -r appuser && useradd -r -g appuser appuser
|
| 13 |
+
|
| 14 |
+
# Change ownership of the /code directory to the new user
|
| 15 |
+
RUN chown -R appuser:appuser /code
|
| 16 |
+
|
| 17 |
+
# Switch to the new user
|
| 18 |
+
USER appuser
|
| 19 |
|
| 20 |
COPY . .
|
| 21 |
|