Docker Images
FalkorDB provides two main Docker images:1. falkordb/falkordb
- Includes: FalkorDB server + FalkorDB Browser
- Use case: Development, quick start, interactive exploration
- Ports:
6379- Redis/FalkorDB server3000- FalkorDB Browser UI
2. falkordb/falkordb-server
- Includes: FalkorDB server only
- Use case: Production deployments, lighter footprint
- Ports:
6379- Redis/FalkorDB server
3. falkordb/falkordb-browser
- Includes: FalkorDB Browser UI only
- Use case: Running browser separately from the server, custom deployments
- Ports:
3000- FalkorDB Browser UI
- Configuration: Requires
FALKORDB_URLenvironment variable to connect to a FalkorDB server
Quick Start with Docker
Running with Browser (Development)
Running Server Only (Production)
Running with Authentication
Running with Custom Configuration
Using Docker Compose
Docker Compose provides a more flexible and maintainable way to run FalkorDB, especially when you need to configure multiple services or manage complex setups.Quick Start: You can download a ready-to-use docker-compose.yml file from the FalkorDB repository.
Basic Docker Compose Setup
Create adocker-compose.yml file:
Production Setup with Persistence
For production environments, use the server-only image with data persistence:Separate Server and Browser Setup
Run FalkorDB server and browser as separate containers:Complete Production Setup
A comprehensive production-ready setup with all recommended configurations:Docker Compose Commands
Common Docker Compose commands for managing FalkorDB:Environment Variables
REDIS_ARGS
Pass arguments directly to the Redis server:--requirepass <password>- Set authentication password--appendonly yes- Enable AOF persistence--appendfsync everysec- AOF sync frequency--maxmemory <bytes>- Maximum memory limit--maxmemory-policy <policy>- Eviction policy (e.g.,allkeys-lru)
FALKORDB_ARGS
Pass configuration to FalkorDB module:Data Persistence
Using Named Volumes
Named volumes are the recommended approach for data persistence:Using Bind Mounts
For specific host directory mapping:Health Checks
Add health checks to ensure FalkorDB is running properly:Networking
Custom Networks
Create isolated networks for better security:Expose vs Ports
Useexpose for internal communication and ports for external access:
Best Practices
-
Use Environment Variables: Store sensitive information like passwords in
.envfiles or environment variables: Create a.envfile:Reference indocker-compose.yml: -
Enable Persistence: Always use volumes for production data:
-
Set Resource Limits: Prevent resource exhaustion:
-
Use Health Checks: Ensure automatic recovery:
-
Configure Logging: Manage log file sizes:
-
Separate Concerns: Use different images for different purposes:
- Development:
falkordb/falkordb(with browser) - Production:
falkordb/falkordb-server(server only)
- Development:
-
Use Specific Tags: Pin to specific versions for stability:
Troubleshooting
Check Container Logs
Check Container Status
Test Connection
Access Redis CLI
View Running Processes
Inspect Configuration
Next Steps
- Learn about Persistence for data durability
- Set up Replication for high availability
- Configure a Cluster for scalability
- Review Configuration options
- Deploy to Kubernetes for orchestration
Frequently Asked Questions
What is the difference between falkordb/falkordb and falkordb/falkordb-server images?
What is the difference between falkordb/falkordb and falkordb/falkordb-server images?
The
falkordb/falkordb image includes both the FalkorDB server and the Browser UI (ports 6379 and 3000). The falkordb/falkordb-server image includes only the server (port 6379), making it lighter for production use.How do I set a password for FalkorDB in Docker?
How do I set a password for FalkorDB in Docker?
Pass
--requirepass <password> via the REDIS_ARGS environment variable: -e REDIS_ARGS='--requirepass mypassword'. For Docker Compose, add it to the environment section.How do I configure FalkorDB module parameters like thread count?
How do I configure FalkorDB module parameters like thread count?
Use the
FALKORDB_ARGS environment variable: -e FALKORDB_ARGS='THREAD_COUNT 8 CACHE_SIZE 50 TIMEOUT_MAX 60000'. See the Configuration page for all available parameters.Why is my data lost when I restart the container?
Why is my data lost when I restart the container?
You need to mount a persistent volume. Use
-v falkordb_data:/var/lib/falkordb/data to attach a Docker volume to the default data directory, and enable AOF for durability.How do I check if FalkorDB is healthy in Docker Compose?
How do I check if FalkorDB is healthy in Docker Compose?
Add a healthcheck using
redis-cli ping: test: ['CMD', 'redis-cli', 'ping']. With authentication, include -a yourpassword in the test command.