From 6c1a3397fc8a2d1210a9b829a88049b8ed45b01e Mon Sep 17 00:00:00 2001 From: yangyu Date: Wed, 2 Jan 2019 10:23:26 +0800 Subject: [PATCH] =?UTF-8?q?redis=20=E5=A2=9E=E5=8A=A0ruby=E7=8E=AF?= =?UTF-8?q?=E5=A2=83?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- redis/standalone/4.0.10/Dockerfile | 5 +++-- redis/standalone/README.md | 1 + 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/redis/standalone/4.0.10/Dockerfile b/redis/standalone/4.0.10/Dockerfile index 2fcc797..a88addf 100644 --- a/redis/standalone/4.0.10/Dockerfile +++ b/redis/standalone/4.0.10/Dockerfile @@ -34,10 +34,11 @@ RUN cd / && wget http://download.redis.io/releases/redis-$REDIS_VERSION.tar.gz \ && cp /redis-$REDIS_VERSION/redis.conf /usr/local/bin/ \ && cd / -RUN mkdir /redis /redis/conf /redis/logs +RUN mkdir /redis /redis/conf /redis/logs /redis/data RUN sed -i 's/logfile ""/logfile "\/redis\/logs\/redis.log"/' /usr/local/bin/redis.conf && \ - sed -i 's/bind 127.0.0.1/#bind 127.0.0.1/' /usr/local/bin/redis.conf + sed -i 's/bind 127.0.0.1/#bind 127.0.0.1/' /usr/local/bin/redis.conf && \ + sed -i 's/dir .\//dir \/redis\/data\//' /usr/local/bin/redis.conf RUN echo "ZONE=Asia/Shanghai" > /etc/sysconfig/clock && \ rm -rf /etc/localtime && \ diff --git a/redis/standalone/README.md b/redis/standalone/README.md index 3f3d1a9..3e7f6e6 100644 --- a/redis/standalone/README.md +++ b/redis/standalone/README.md @@ -21,6 +21,7 @@ docker run -d \ -p 6379:6379 \ -v /data/redis/conf:/redis/conf \ -v /data/redis/logs:/redis/logs \ + -v /data/redis/data:/redis/data \ -e PASSWORD=123456 \ --name redis-4.0.10 \ ccr.ccs.tencentyun.com/yy-dk/redis:4.0.10