Fix memcached pid dir and ownership

This commit is contained in:
Deon George 2024-01-09 20:18:50 +11:00
parent 98210c41a9
commit 232037d3ad
2 changed files with 3 additions and 1 deletions

View File

@ -20,12 +20,14 @@ RUN curl -SLo /usr/local/bin/wait-for-it https://github.com/vishnubob/wait-for-i
# Memcache
RUN apk add --no-cache memcached libmemcached pkgconfig zlib-dev memcached-dev libmemcached-dev && \
pecl_install igbinary msgpack memcached && \
mkdir /run/memcached && chown memcached:memcached /run/memcached && \
apk del --no-cache pkgconfig zlib-dev memcached-dev libmemcached-dev
# Enable ZIP BZIP2
RUN apk add --no-cache libzip libzip-dev zlib-dev && \
docker-php-ext-install -j$(nproc) zip bz2 && \
apk del --no-cache libzip-dev zlib-dev
# Add zstd
RUN pecl_install zstd

View File

@ -37,7 +37,7 @@ function nginx_start() {
# General Setup
if [ -x /usr/bin/memcached -a "${MEMCACHED_START}" == "TRUE" ]; then
echo "* Starting MEMCACHED..."
/usr/bin/memcached -d -P /var/run/memcached.pid -u memcached
/usr/bin/memcached -d -P /run/memcached/memcached.pid -u memcached
fi
# Laravel Specific