Spaces:
Build error
Build error
Update Dockerfile
Browse files- Dockerfile +8 -8
Dockerfile
CHANGED
|
@@ -1,18 +1,18 @@
|
|
| 1 |
# Use the official Qdrant image
|
| 2 |
FROM qdrant/qdrant:v1.6.1
|
| 3 |
|
| 4 |
-
# Switch to root user
|
| 5 |
USER root
|
| 6 |
|
| 7 |
# Install Nginx
|
| 8 |
RUN apt-get update && apt-get install -y nginx && rm -rf /var/lib/apt/lists/*
|
| 9 |
|
| 10 |
-
#
|
| 11 |
-
RUN
|
|
|
|
| 12 |
|
| 13 |
-
#
|
| 14 |
-
RUN
|
| 15 |
-
RUN chmod -R 777 /var/lib/nginx /var/log/nginx
|
| 16 |
|
| 17 |
# Copy custom Nginx configuration
|
| 18 |
COPY nginx.conf /etc/nginx/nginx.conf
|
|
@@ -20,5 +20,5 @@ COPY nginx.conf /etc/nginx/nginx.conf
|
|
| 20 |
# Expose Hugging Face's required port
|
| 21 |
EXPOSE 7860
|
| 22 |
|
| 23 |
-
# Start Qdrant
|
| 24 |
-
CMD ["/bin/sh", "-c", "
|
|
|
|
| 1 |
# Use the official Qdrant image
|
| 2 |
FROM qdrant/qdrant:v1.6.1
|
| 3 |
|
| 4 |
+
# Switch to root user
|
| 5 |
USER root
|
| 6 |
|
| 7 |
# Install Nginx
|
| 8 |
RUN apt-get update && apt-get install -y nginx && rm -rf /var/lib/apt/lists/*
|
| 9 |
|
| 10 |
+
# permissions for Nginx logs and directories
|
| 11 |
+
RUN mkdir -p /var/lib/nginx/body /var/lib/nginx/proxy /var/log/nginx /run
|
| 12 |
+
RUN chmod -R 777 /var/lib/nginx /var/log/nginx /run
|
| 13 |
|
| 14 |
+
# Ensure Nginx can write to the PID file
|
| 15 |
+
RUN touch /run/nginx.pid && chmod 777 /run/nginx.pid
|
|
|
|
| 16 |
|
| 17 |
# Copy custom Nginx configuration
|
| 18 |
COPY nginx.conf /etc/nginx/nginx.conf
|
|
|
|
| 20 |
# Expose Hugging Face's required port
|
| 21 |
EXPOSE 7860
|
| 22 |
|
| 23 |
+
# Start Qdrant and then Nginx
|
| 24 |
+
CMD ["/bin/sh", "-c", "/qdrant & nginx -g 'pid /dev/null; daemon off;'"]
|