Spaces:
Sleeping
Sleeping
Upload Dockerfile with huggingface_hub
Browse files- Dockerfile +12 -5
Dockerfile
CHANGED
|
@@ -1,8 +1,15 @@
|
|
| 1 |
-
# Use Alpine as a clean base
|
| 2 |
FROM alpine:3.19
|
| 3 |
|
| 4 |
-
# Install Node.js, npm, and essential tools
|
| 5 |
-
RUN apk add --no-cache
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 6 |
|
| 7 |
# Install n8n globally
|
| 8 |
RUN npm install -g n8n
|
|
@@ -12,7 +19,7 @@ ENV N8N_PORT=7860
|
|
| 12 |
ENV N8N_PROTOCOL=https
|
| 13 |
ENV N8N_USER_FOLDER=/data/.n8n
|
| 14 |
|
| 15 |
-
# Create the data directory and force ownership
|
| 16 |
USER root
|
| 17 |
RUN mkdir -p /data/.n8n && chown -R 1000:1000 /data/.n8n
|
| 18 |
USER 1000
|
|
@@ -20,5 +27,5 @@ USER 1000
|
|
| 20 |
# Expose port
|
| 21 |
EXPOSE 7860
|
| 22 |
|
| 23 |
-
# Launch n8n
|
| 24 |
CMD ["n8n", "start"]
|
|
|
|
| 1 |
+
# Use Alpine as a clean base
|
| 2 |
FROM alpine:3.19
|
| 3 |
|
| 4 |
+
# Install Node.js, npm, and essential build tools (Python, Make, G++)
|
| 5 |
+
RUN apk add --no-cache \
|
| 6 |
+
nodejs \
|
| 7 |
+
npm \
|
| 8 |
+
python3 \
|
| 9 |
+
make \
|
| 10 |
+
g++ \
|
| 11 |
+
curl \
|
| 12 |
+
bash
|
| 13 |
|
| 14 |
# Install n8n globally
|
| 15 |
RUN npm install -g n8n
|
|
|
|
| 19 |
ENV N8N_PROTOCOL=https
|
| 20 |
ENV N8N_USER_FOLDER=/data/.n8n
|
| 21 |
|
| 22 |
+
# Create the data directory and force ownership
|
| 23 |
USER root
|
| 24 |
RUN mkdir -p /data/.n8n && chown -R 1000:1000 /data/.n8n
|
| 25 |
USER 1000
|
|
|
|
| 27 |
# Expose port
|
| 28 |
EXPOSE 7860
|
| 29 |
|
| 30 |
+
# Launch n8n
|
| 31 |
CMD ["n8n", "start"]
|