Skip to content

Commit 5fa52eb

Browse files
HugoDFalexmacarthur
authored andcommitted
add redis
1 parent 2d49110 commit 5fa52eb

File tree

2 files changed

+29
-0
lines changed

2 files changed

+29
-0
lines changed

redis/README.md

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
# Redis w/ Docker Compose
2+
3+
Password authentication is achieved through running a custom redis-server command to require the `"password"` password.
4+
5+
## Enter the Container w/ Bash
6+
7+
`docker-compose exec --user root db /bin/bash`
8+
9+
## Enter the Redis Shell
10+
11+
`docker-compose exec --user root db redis-cli`
12+
13+
## Super User Authentication
14+
15+
Password: `password`
16+
17+
While inside the shell, run the following:
18+
19+
```
20+
AUTH "password"
21+
```

redis/docker-compose.yml

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
version: '3'
2+
3+
services:
4+
db:
5+
image: redis:latest
6+
command: redis-server --requirepass password
7+
ports:
8+
- 6379:6379

0 commit comments

Comments
 (0)