diff --git a/Dockerfile b/Dockerfile index 53f1a4a..ee8a26f 100644 --- a/Dockerfile +++ b/Dockerfile @@ -6,7 +6,7 @@ MAINTAINER "f " ARG MAX_MEMORY -RUN apk add --no-cache redis +RUN apk add --no-cache redis su-exec RUN sed -re "/^bind /d" -i /etc/redis.conf RUN sed -re "/^protected-mode /d" -i /etc/redis.conf diff --git a/redisd.sh b/redisd.sh index e3a9755..6157427 100755 --- a/redisd.sh +++ b/redisd.sh @@ -5,7 +5,7 @@ run=/run/redis case $1 in start) install -dm 750 -o redis -g redis $run - su redis -c "/usr/bin/redis-server /etc/redis.conf" + su-exec redis /usr/bin/redis-server /etc/redis.conf ;; stop) /usr/bin/redis-cli shutdown