Build modified streamline images

The official image from streamline does not currently work for the arm64
platform. As a temporary measure, the source code and docker build scripts
have been lifted from the official images and are used to build locally.

Some additional modifications are made to reduce overall image size, these
are documented in docker/README.md
This commit is contained in:
2024-03-10 16:17:50 -07:00
parent 2ffc3c408a
commit a424394109
13506 changed files with 1860172 additions and 6 deletions
@@ -0,0 +1,26 @@
FROM php:8.2-fpm-alpine
ENV PHPGROUP=streamline
ENV PHPUSER=streamline
RUN set -eux; \
adduser -g ${PHPGROUP} -s /bin/sh -D ${PHPUSER}; \
sed -i "s/user = www-data/user = ${PHPUSER}/g" /usr/local/etc/php-fpm.d/www.conf; \
sed -i "s/group = www-data/group = ${PHPGROUP}/g" /usr/local/etc/php-fpm.d/www.conf; \
mkdir -p /var/www/html/public; \
docker-php-ext-install pdo pdo_mysql opcache
COPY .docker/php/opcache.ini /usr/local/etc/php/conf.d/opcache.ini
RUN curl -sS https://getcomposer.org/installer | php -- --install-dir=/usr/local/bin --filename=composer
COPY ./ /var/www/html
WORKDIR /var/www/html
RUN set -eux; \
composer install; \
chmod 777 -R /var/www/html/storage; \
chown -R www-data:www-data /var/www/html
CMD ["php-fpm", "-y", "/usr/local/etc/php-fpm.conf", "-R"]
@@ -0,0 +1,11 @@
[opcache]
opcache.enable=1
; 0 means it will check on every request
; 0 is irrelevant if opcache.validate_timestamps=0 which is desirable in production
opcache.revalidate_freq=0
opcache.validate_timestamps=1
opcache.max_accelerated_files=10000
opcache.memory_consumption=192
opcache.max_wasted_percentage=10
opcache.interned_strings_buffer=16
opcache.fast_shutdown=1