Spaces:
Runtime error
Runtime error
Update Dockerfile
Browse files- Dockerfile +3 -4
Dockerfile
CHANGED
|
@@ -1,4 +1,4 @@
|
|
| 1 |
-
#
|
| 2 |
FROM node:20-bullseye-slim
|
| 3 |
|
| 4 |
# Install dependencies
|
|
@@ -7,13 +7,12 @@ RUN apt-get update && apt-get install -y curl && rm -rf /var/lib/apt/lists/*
|
|
| 7 |
# Install n8n globally
|
| 8 |
RUN npm install -g n8n@2.3.5
|
| 9 |
|
| 10 |
-
#
|
| 11 |
ENV N8N_PORT=7860
|
| 12 |
ENV N8N_HOST=0.0.0.0
|
| 13 |
ENV NODE_ENV=production
|
| 14 |
|
| 15 |
-
# Expose the port HF will use
|
| 16 |
EXPOSE 7860
|
| 17 |
|
| 18 |
-
#
|
| 19 |
CMD ["n8n", "start", "--tunnel", "--host=0.0.0.0", "--port=7860"]
|
|
|
|
| 1 |
+
# Node 20 base (n8n requires >=20.19)
|
| 2 |
FROM node:20-bullseye-slim
|
| 3 |
|
| 4 |
# Install dependencies
|
|
|
|
| 7 |
# Install n8n globally
|
| 8 |
RUN npm install -g n8n@2.3.5
|
| 9 |
|
| 10 |
+
# Environment variables (can be overridden by HF Secrets)
|
| 11 |
ENV N8N_PORT=7860
|
| 12 |
ENV N8N_HOST=0.0.0.0
|
| 13 |
ENV NODE_ENV=production
|
| 14 |
|
|
|
|
| 15 |
EXPOSE 7860
|
| 16 |
|
| 17 |
+
# Run n8n with tunneling
|
| 18 |
CMD ["n8n", "start", "--tunnel", "--host=0.0.0.0", "--port=7860"]
|