From afe65b26182d6ac65bc74507b5796c21c02e235a Mon Sep 17 00:00:00 2001 From: Deon George Date: Wed, 9 Jun 2021 12:34:43 +1000 Subject: [PATCH] Fix ommissions in previous commit --- init | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/init b/init index 230c319..488f650 100755 --- a/init +++ b/init @@ -8,7 +8,8 @@ composer=${COMPOSER_DIR:-/var/www/.composer} NGINX_START=${NGINX_START:-TRUE} SSH_START=${SSH_START:-FALSE} -REDIS_START=${SSH_START:-FALSE} +REDIS_START=${REDIS_START:-FALSE} +MEMCACHED_START=${MEMCACHED_START:-FALSE} # To run a local queue, running jobs from the queue "hostname" LOCAL_QUEUE=${LOCAL_QUEUE:-FALSE} @@ -33,15 +34,18 @@ function nginx_start() { # General Setup if [ -x /usr/sbin/sshd -a "${SSH_START}" == "TRUE" ]; then + echo "* Starting SSH..." [ ! -d /var/run/sshd ] && mkdir /var/run/sshd start-stop-daemon --start --pidfile /var/run/sshd.pid --exec /usr/sbin/sshd -- -p 22 fi if [ -x /usr/bin/redis-server -a "${REDIS_START}" == "TRUE" ]; then + echo "* Starting REDIS..." start-stop-daemon --start --quiet --oknodo --umask 007 --pidfile /var/run/redis-server.pid --chuid redis:redis --exec /usr/bin/redis-server -- /etc/redis/redis.conf fi -if [ -x /usr/bin/memcached -a "${REDIS_START}" == "TRUE" ]; then +if [ -x /usr/bin/memcached -a "${MEMCACHED_START}" == "TRUE" ]; then + echo "* Starting MEMCACHED..." start-stop-daemon --start --quiet --exec "/usr/share/memcached/scripts/start-memcached" -- /etc/memcached.conf /var/run/memcached.pid fi