2023-04-10 18:35:19 +08:00
|
|
|
ARG PHP_IMAGE
|
|
|
|
FROM ${PHP_IMAGE}
|
2023-04-09 10:55:06 +08:00
|
|
|
|
|
|
|
ARG TZ
|
|
|
|
ARG PHP_EXTENSIONS
|
|
|
|
ARG CONTAINER_PACKAGE_URL
|
|
|
|
|
|
|
|
COPY ./extensions /tmp/extensions
|
|
|
|
WORKDIR /tmp/extensions
|
|
|
|
RUN chmod +x install.sh \
|
2023-06-05 15:04:27 +08:00
|
|
|
&& sh install.sh \
|
|
|
|
&& rm -rf /tmp/extensions
|
2023-04-09 10:55:06 +08:00
|
|
|
|
|
|
|
|
|
|
|
# Install composer and change it's cache home
|
2023-06-05 15:04:27 +08:00
|
|
|
RUN curl -o /usr/bin/composer https://mirrors.aliyun.com/composer/composer.phar \
|
|
|
|
&& chmod +x /usr/bin/composer
|
2023-04-09 10:55:06 +08:00
|
|
|
ENV COMPOSER_HOME=/tmp/composer
|
|
|
|
|
2023-09-11 17:54:21 +08:00
|
|
|
|
2023-04-09 10:55:06 +08:00
|
|
|
# php image's www-data user uid & gid are 82, change them to 1000 (primary user)
|
2023-09-11 17:54:21 +08:00
|
|
|
RUN usermod -u 1000 www-data && groupmod -g 1000 www-data
|
2023-04-09 10:55:06 +08:00
|
|
|
|
|
|
|
|
2023-09-11 17:54:21 +08:00
|
|
|
WORKDIR /www
|