Dragonfly
Multi-threaded Redis-wire runtime — OKE_STORE_KV_PASSWORD, memlock ulimit, no maxmemory-policy flag.
Dragonfly is a multi-threaded, memory-efficient reimplementation of the Redis protocol —
same redis:// wire format, different engine. Slots behind the same redis driver with
zero Flow changes.
The one rule
Driver id stays redis. Dragonfly is an image choice — every KV call through fx.store behaves
identically to Redis or Valkey at the protocol layer.
Quick start
Pin the image
images: {
"store.kv": "docker.dragonflydb.io/dragonflydb/dragonfly",
},Password + memory
OKE_STORE_KV_PASSWORD=…
OKE_STORE_KV_MAXMEMORY=256mb # optional; recipe passes --maxmemory
REDIS_URL=redis://:…@127.0.0.1:6379Command: dragonfly --requirepass "$OKE_STORE_KV_PASSWORD" --maxmemory "…".
Unlike Redis/Valkey, this recipe does not pass --maxmemory-policy — Dragonfly's
own defaults apply.
memlock ulimit
The recipe sets ulimits.memlock: -1 — required for Dragonfly's shared-nothing design.
If the host forbids unlimited memlock, the container may fail to start.
Required env
| Variable | Required? | Meaning |
|---|---|---|
OKE_STORE_KV_PASSWORD | Yes | --requirepass |
REDIS_URL | Yes (app) | redis:// URL for the driver |
OKE_STORE_KV_MAXMEMORY | Optional | --maxmemory (default 0 in the command template) |
HEALTHCHECK_PORT | Set by recipe | 6379 — used by the image's healthcheck script |
Data and backup
The default store.kv recipe declares no named volume — ephemeral, same as Redis/Valkey.
Keys that must survive go on { durable: true } — a JSONB table on your SQL database.
Dragonfly snapshots are not involved. See Store · Durable KV.
Production note
BSL 1.1 — converts to Apache 2.0 on a published change date per release. Free for self-hosting; the BSL terms restrict offering Dragonfly itself as a commercial managed service to third parties — running it for your own app is unaffected.
Multi-threaded architecture makes better use of multi-core hosts than single-threaded Redis under heavy concurrent load. For a managed endpoint with TLS + passkey, see Dragonfly Cloud.
What the recipe configures
| Field | Value |
|---|---|
| Container port | 6379 |
ulimits | memlock: -1 |
| Healthcheck | /usr/local/bin/healthcheck.sh, every 5s, 10 retries |
| Connection URL | redis://:pass@host:6379 |
Troubleshooting
Host ulimit -l is too low. The recipe requests unlimited memlock. Raise the Docker
daemon / systemd limit, or run on a host that allows memlock: -1.
Same driver failure as Redis — export REDIS_URL or let oke dev write it. Wrong
password yields Redis-protocol NOAUTH / WRONGPASS from the server.
Learn more
- Store · KV — full Redis-protocol image license table
- Dragonfly Cloud — the managed equivalent
- Redis · Valkey — the other two peers