I have n8n running on Coolify but can’t get the worker mode to function correctly. I set up everything based on the Docker documentation but workflows keep running on the main container instead of being distributed to workers.
The main issues I’m seeing are:
- When I trigger a workflow the loading indicator gets stuck and only stops when I reload the page.
- Workers don’t seem to pick up any jobs from the queue.
- Redis container shows no activity in logs.
Here’s my docker compose setup:
services:
automation-server:
image: docker.n8n.io/n8nio/n8n
environment:
- SERVICE_FQDN_N8N_5678
- 'N8N_EDITOR_BASE_URL=${SERVICE_FQDN_N8N}'
- 'WEBHOOK_URL=${SERVICE_FQDN_N8N}'
- 'GENERIC_TIMEZONE=${GENERIC_TIMEZONE:-Europe/Berlin}'
- DB_TYPE=postgresdb
- 'DB_POSTGRESDB_DATABASE=${POSTGRES_DB:-automation}'
- DB_POSTGRESDB_HOST=database
- DB_POSTGRESDB_PORT=5432
- DB_POSTGRESDB_USER=$SERVICE_USER_POSTGRES
- DB_POSTGRESDB_PASSWORD=$SERVICE_PASSWORD_POSTGRES
- EXECUTIONS_MODE=queue
- QUEUE_BULL_REDIS_HOST=cache
- QUEUE_BULL_REDIS_PORT=6379
- QUEUE_MODE=redis
- N8N_RUNNERS_ENABLED=true
- QUEUE_HEALTH_CHECK_ACTIVE=true
- N8N_LOG_LEVEL=debug
volumes:
- 'app-data:/home/node/.n8n'
command: start
depends_on:
- database
- cache
worker-node:
image: docker.n8n.io/n8nio/n8n
environment:
- 'GENERIC_TIMEZONE=${GENERIC_TIMEZONE:-Europe/Berlin}'
- DB_TYPE=postgresdb
- 'DB_POSTGRESDB_DATABASE=${POSTGRES_DB:-automation}'
- DB_POSTGRESDB_HOST=database
- DB_POSTGRESDB_USER=$SERVICE_USER_POSTGRES
- DB_POSTGRESDB_PASSWORD=$SERVICE_PASSWORD_POSTGRES
- EXECUTIONS_MODE=queue
- QUEUE_BULL_REDIS_HOST=cache
- QUEUE_BULL_REDIS_PORT=6379
- QUEUE_MODE=redis
- N8N_WORKER=true
- N8N_LOG_LEVEL=debug
volumes:
- 'app-data:/home/node/.n8n'
command: worker
depends_on:
- database
- cache
database:
image: 'postgres:16-alpine'
volumes:
- 'db-data:/var/lib/postgresql/data'
environment:
- POSTGRES_USER=$SERVICE_USER_POSTGRES
- POSTGRES_PASSWORD=$SERVICE_PASSWORD_POSTGRES
- 'POSTGRES_DB=${POSTGRES_DB:-automation}'
cache:
image: redis:7
volumes:
- cache_storage:/data
The main container logs show queue mode is active but workers stay completely silent. Could this be related to Coolify’s networking setup or am I missing something in the configuration? Anyone got this working with Coolify before?