N8N / Dockerfile
Rsnarsna's picture
Update Dockerfile
228a47a verified
raw
history blame contribute delete
949 Bytes
# Set the n8n version
ARG N8N_VERSION=stable
FROM docker.n8n.io/n8nio/n8n:$N8N_VERSION
# Environment configuration
ENV N8N_ENFORCE_SETTINGS_FILE_PERMISSIONS=true \
N8N_RUNNERS_ENABLED=true \
N8N_PROXY_HOPS=1 \
N8N_PORT=7860 \
N8N_HOST=0.0.0.0 \
WEBHOOK_URL="https://rsnarsna-n8n.hf.space/" \
N8N_EDITOR_BASE_URL="https://rsnarsna-n8n.hf.space/" \
N8N_ENCRYPTION_KEY=e4b8c8b7fc74c03a60c90b27da19a3b9b7091b99d1fcd674c0ad82d963cbf429 \
N8N_AUTH_MODE=basic \
N8N_BASIC_AUTH_ACTIVE=true \
N8N_BASIC_AUTH_USER=admin \
N8N_BASIC_AUTH_PASSWORD=StrongPasswordHere123! \
GENERIC_TIMEZONE=Asia/Kolkata
# Optional: Remove any persisted data from previous runs (clean start)
# Uncomment this if you want to reset the environment every time
# RUN rm -rf /home/node/.n8n
# Run as non-root user
USER node
# Persistent volume for local SQLite and data
VOLUME ["/home/node/.n8n"]
# Expose the n8n port
EXPOSE 7860