Requirements
| Environment | Redis | Notes |
|---|---|---|
| Development | Recommended | Enables full feature testing |
| Production | Required | Essential for multi-instance deployments |
Development Setup
Option 1: Docker Compose (Recommended)
Projects created withfrontmcp create --target node include Docker files in the ci/ folder:
Option 2: Local Installation
Configuration
Production Setup
Managed Redis Services (Recommended)
| Provider | Service |
|---|---|
| AWS | ElastiCache for Redis |
| GCP | Memorystore for Redis |
| Azure | Azure Cache for Redis |
| Upstash | Serverless Redis |
| Redis Cloud | Redis Enterprise |
Self-Hosted Production
For self-hosted Redis in production:Security Best Practices
- Authentication: Always set
REDIS_PASSWORDin production - Network: Run Redis in private network, not exposed to internet
- TLS: Enable TLS for encrypted connections
- Persistence: Use AOF for durability (
appendonly yes)
Configuration Example
redis block to { provider: 'vercel-kv' } when deploying on Vercel KV—the Cache Plugin will keep reusing the same store without code changes.
Environment Variables
Redis Configuration
| Variable | Required | Default | Description |
|---|---|---|---|
REDIS_HOST | Yes | localhost | Redis server hostname |
REDIS_PORT | No | 6379 | Redis server port |
REDIS_PASSWORD | Prod only | - | Redis authentication password |
REDIS_DB | No | 0 | Redis database number |
REDIS_TLS | No | false | Enable TLS encryption |
REDIS_KEY_PREFIX | No | mcp: | Key prefix for cache namespacing (CachePlugin uses content hashing by default) |
Plugin Secrets
| Variable | Required | Default | Description |
|---|---|---|---|
REMEMBER_SECRET | Prod only | Auto-generated | Encryption secret for RememberPlugin (32+ byte base64-encoded string) |
In development,
REMEMBER_SECRET is auto-generated and stored in .frontmcp/remember-secret.json. Add this file to .gitignore. In production, always set REMEMBER_SECRET explicitly to ensure consistent encryption across instances.Health Checks
Troubleshooting
Connection Refused
- Verify Redis is running:
redis-cli ping - Check firewall rules
- Verify host/port configuration
Authentication Failed
- Ensure
REDIS_PASSWORDmatches server config - Check for special characters in password (may need URL encoding)
Memory Issues
- Set
maxmemoryandmaxmemory-policyin Redis config - Monitor with
redis-cli INFO memory
Docker Network Issues
When using Docker Compose, the app container should useredis as the hostname (the service name), not localhost: