Spaces:
Sleeping
Sleeping
Upload 2 files
Browse files- Dockerfile +8 -4
Dockerfile
CHANGED
|
@@ -48,13 +48,17 @@ COPY startup.sh .
|
|
| 48 |
# Make startup script executable
|
| 49 |
RUN chmod +x startup.sh
|
| 50 |
|
|
|
|
|
|
|
|
|
|
| 51 |
# Create nginx directories with proper permissions
|
| 52 |
-
RUN mkdir -p /var/lib/nginx/tmp/client_body && \
|
| 53 |
chmod -R 755 /var/lib/nginx && \
|
| 54 |
-
chown -R nginx:nginx /var/lib/nginx
|
|
|
|
| 55 |
|
| 56 |
-
# Expose
|
| 57 |
-
EXPOSE
|
| 58 |
|
| 59 |
# Start both nginx and node server
|
| 60 |
CMD ["./startup.sh"]
|
|
|
|
| 48 |
# Make startup script executable
|
| 49 |
RUN chmod +x startup.sh
|
| 50 |
|
| 51 |
+
# Set environment variable for Hugging Face Spaces
|
| 52 |
+
ENV HF_SPACES=true
|
| 53 |
+
|
| 54 |
# Create nginx directories with proper permissions
|
| 55 |
+
RUN mkdir -p /var/lib/nginx/tmp/client_body /var/lib/nginx/tmp/proxy /var/lib/nginx/tmp/fastcgi /var/lib/nginx/tmp/uwsgi /var/lib/nginx/tmp/scgi && \
|
| 56 |
chmod -R 755 /var/lib/nginx && \
|
| 57 |
+
chown -R nginx:nginx /var/lib/nginx && \
|
| 58 |
+
mkdir -p /run/nginx
|
| 59 |
|
| 60 |
+
# Expose port 8501 for Hugging Face Spaces
|
| 61 |
+
EXPOSE 8501
|
| 62 |
|
| 63 |
# Start both nginx and node server
|
| 64 |
CMD ["./startup.sh"]
|