https://github.com/ddev/ddev-redis-7
Redis 7 service for DDEV
https://github.com/ddev/ddev-redis-7
ddev-get
Last synced: about 1 year ago
JSON representation
Redis 7 service for DDEV
- Host: GitHub
- URL: https://github.com/ddev/ddev-redis-7
- Owner: ddev
- License: apache-2.0
- Created: 2023-01-06T12:52:58.000Z (over 3 years ago)
- Default Branch: main
- Last Pushed: 2025-04-10T19:30:30.000Z (about 1 year ago)
- Last Synced: 2025-04-10T20:42:15.094Z (about 1 year ago)
- Topics: ddev-get
- Language: Shell
- Homepage:
- Size: 1.52 MB
- Stars: 3
- Watchers: 7
- Forks: 4
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# ddev-redis-7 - Redis 7 container for DDEV
[](https://github.com/ddev/ddev-redis-7/releases)
[](https://github.com/ddev/ddev-redis-7/actions/workflows/cron_tests.yml)

This repository provides [Redis 7](https://redis.com) container for [DDEV](https://ddev.readthedocs.io/).
It is based on [redis:7.2-alpine](https://hub.docker.com/_/redis/tags?page=1&name=7) docker image and [DDEV custom compose files](https://ddev.readthedocs.io/en/stable/users/extend/custom-compose-files/)
## Comparison to **v6** ([`ddev/ddev-redis`](https://github.com/ddev/ddev-redis))
There are a lot of differences between v6 addon and this one
| Feature | ddev/ddev-redis | ddev/ddev-redis-7 |
| ----------------- | ---------------- | ----------------- |
| Maximum Memory | Unlimited | 512Mb |
| Persistence | Optional | **Yes** |
| Redis Version | 6.x.y | 7.2.x |
| Image Size | ~40Mb | ~11Mb |
| Anonymous Volumes | No | No |
| Optimized config | No | **Yes** |
### Anonymous volumes - Wait, what?
Official redis docker container mounts an anonymous volume on `/data` because... reasons. That volume is recreated on every restart. This one mounts the persistence directory on `/data` and names it according to the project name, and gives it a proper label. This way, each DDEV project has it's own data volume, and data can persist accordingly
### Persistence?
Yes, persistence. This container is configured to persist data on `/data` volume. This means that if you stop the container, and start it again, the data will be there. This is useful for long-term caching of data, and for keeping the cache primed between ddev restarts.
## Installation
For DDEV v1.23.5 or above run
```sh
ddev add-on get ddev/ddev-redis-7
```
For earlier versions of DDEV run
```sh
ddev get ddev/ddev-redis-7
```
Then restart your project
```sh
ddev restart
```
> [!IMPORTANT]
> Authentication is setup by default, and the password is `redis`.
> If needed, you can auth with a username and password.
> Username is `redis` as well.
## Configuration
Redis configuration files are split in the `.ddev/redis/conf` folder, you can modify them as you wish.
Otherwise, plugin just works out of the box.
## Commands
Addon exposes the following commands
| Command | Usage | Description |
| ----------------- | ------------------ | ---------------------------------- |
| `redis` | `ddev redis` | Launches the **redis-cli** |
| `redis *COMMAND*` | `ddev redis` | Run an arbitrary redis-cli command |
| `redis-flush` | `ddev redis-flush` | Clears all the Redis Databases |
___
**Based on the original [ddev-contrib recipe](https://github.com/ddev/ddev-contrib/tree/master/docker-compose-services/mongodb)**
**Developed and maintained by [Oblak Studio](https://github.com/oblakstudio)**