92 lines
2.3 KiB
Groff
92 lines
2.3 KiB
Groff
.\"t
|
|
.\" WARNING: Do not edit this file manually, it is generated from README.md automatically.
|
|
.\"
|
|
.\"t
|
|
.\" Automatically generated by Pandoc 1.16.0.2
|
|
.\"
|
|
.TH "REDIS\-32\-RHEL7" "1" "February 22, 2017" "Container Image Pages" ""
|
|
.hy
|
|
.SH Redis Docker image
|
|
.PP
|
|
This container image includes Dockerfile for Redis 3.2 Docker image.
|
|
Users can choose between RHEL and CentOS based images.
|
|
.PP
|
|
Dockerfile for CentOS is called Dockerfile, Dockerfile for RHEL is
|
|
called Dockerfile.rhel7.
|
|
.SS Environment variables and volumes
|
|
.PP
|
|
.TS
|
|
tab(@);
|
|
l l.
|
|
T{
|
|
Variable name
|
|
T}@T{
|
|
Description
|
|
T}
|
|
_
|
|
T{
|
|
\f[C]REDIS_PASSWORD\f[]
|
|
T}@T{
|
|
Password for the server access
|
|
T}
|
|
.TE
|
|
.PP
|
|
TBD
|
|
.PP
|
|
You can also set the following mount points by passing the
|
|
\f[C]\-v\ /host:/container:Z\f[] flag to Docker.
|
|
.PP
|
|
.TS
|
|
tab(@);
|
|
l l.
|
|
T{
|
|
Volume mount point
|
|
T}@T{
|
|
Description
|
|
T}
|
|
_
|
|
T{
|
|
\f[C]/var/lib/redis/data\f[]
|
|
T}@T{
|
|
Redis data directory
|
|
T}
|
|
.TE
|
|
.PP
|
|
\f[B]Notice: When mouting a directory from the host into the container,
|
|
ensure that the mounted directory has the appropriate permissions and
|
|
that the owner and group of the directory matches the user UID or name
|
|
which is running inside the container.\f[]
|
|
.SS Usage
|
|
.PP
|
|
For this, we will assume that you are using the
|
|
\f[C]rhscl/redis\-32\-rhel7\f[] image.
|
|
If you want to set only the mandatory environment variables and not
|
|
store the database in a host directory, execute the following command:
|
|
.IP
|
|
.nf
|
|
\f[C]
|
|
$\ docker\ run\ \-d\ \-\-name\ redis_database\ \-p\ 6379:6379\ rhscl/redis\-32\-rhel7
|
|
\f[]
|
|
.fi
|
|
.PP
|
|
This will create a container named \f[C]redis_database\f[].
|
|
Port 6379 will be exposed and mapped to the host.
|
|
.PP
|
|
If you want your database to be persistent across container executions,
|
|
also add a \f[C]\-v\ /host/db/path:/var/lib/redis/data:Z\f[] argument.
|
|
This will be the Redis data directory.
|
|
.PP
|
|
For protecting Redis data by a password, pass \f[C]REDIS_PASSWORD\f[]
|
|
environment variable to the container like this:
|
|
.IP
|
|
.nf
|
|
\f[C]
|
|
$\ docker\ run\ \-d\ \-\-name\ redis_database\ \-e\ REDIS_PASSWORD=strongpassword\ rhscl/redis\-32\-rhel7
|
|
\f[]
|
|
.fi
|
|
.PP
|
|
\f[B]Warning: since Redis is pretty fast an outside user can try up to
|
|
150k passwords per second against a good box. This means that you should
|
|
use a very strong password otherwise it will be very easy to break.\f[]
|
|
.SH AUTHORS
|
|
Red Hat.
|