add redis

This commit is contained in:
Hugo Di Francesco
2019-10-07 20:02:57 +01:00
committed by Alex MacArthur
parent 2d49110304
commit 5fa52ebed8
2 changed files with 29 additions and 0 deletions

21
redis/README.md Normal file
View File

@@ -0,0 +1,21 @@
# Redis w/ Docker Compose
Password authentication is achieved through running a custom redis-server command to require the `"password"` password.
## Enter the Container w/ Bash
`docker-compose exec --user root db /bin/bash`
## Enter the Redis Shell
`docker-compose exec --user root db redis-cli`
## Super User Authentication
Password: `password`
While inside the shell, run the following:
```
AUTH "password"
```

8
redis/docker-compose.yml Normal file
View File

@@ -0,0 +1,8 @@
version: '3'
services:
db:
image: redis:latest
command: redis-server --requirepass password
ports:
- 6379:6379