提交 cf397bab authored 作者: chenhuan's avatar chenhuan

Merge branch 'master' of http://git.hudongtang.cn/chenhuan/docker

* 'master' of http://git.hudongtang.cn/chenhuan/docker: 更新 Dockerfile2 更新 Dockerfile2 增加新文件 更新 Dockerfile # Conflicts: # base-images/debian-php-74/Dockerfile
FROM dockette/debian:buster
FROM docker.io/bitnami/minideb:bullseye
# PHP
ENV PHP_MODS_DIR=/etc/php/7.4/mods-available
......
ARG PHP_VERSION=8.1
FROM php:${PHP_VERSION}-fpm-alpine
# PHP_CPPFLAGS are used by the docker-php-ext-* scripts
ARG PHP_CPPFLAGS="$PHP_CPPFLAGS"
SHELL ["/bin/ash", "-o", "pipefail", "-c"]
# Install Nginx & PHP packages and extensions
RUN apk add --no-cache --update \
# Install packages required by PHP/Laravel
git~=2 \
icu-dev~=69 \
nginx~=1 \
unzip~=6 \
# Install mail server
msmtp~=1 \
# Install gd for image functions
freetype-dev~=2 \
libwebp-dev~=1 \
libjpeg-turbo-dev~=2 \
libpng-dev~=1 \
# Install zip for csv functions
libzip-dev~=1 \
zip~=3 \
# Configure image library
&& docker-php-ext-configure gd \
--with-jpeg \
--with-webp \
--with-freetype \
# Configure PHP extensions for use in Docker
&& docker-php-ext-install \
pdo_mysql \
opcache \
zip \
gd \
redis \
mongodb \
# Setup Nginx directories, permissions, and one-off configurations
&& mkdir -p /var/run/nginx \
&& chown -R www-data:www-data /var/run/nginx /var/lib/nginx /var/log/nginx \
&& sed -i 's|user nginx;|#user www-data;|' /etc/nginx/nginx.conf \
&& sed -i 's|user =|;user =|' /usr/local/etc/php-fpm.d/www.conf \
&& sed -i 's|group =|;group =|' /usr/local/etc/php-fpm.d/www.conf \
# Install the latest version of Composer
&& curl -sS https://getcomposer.org/installer | php -- --install-dir=/usr/local/bin --filename=composer \
# Cleanup
&& rm -rf /var/cache/apk/* /tmp/*
# PHP
#ADD ./php/php-fpm.conf /etc/php/7.4/
# NGINX
ADD ./nginx/nginx.conf /etc/nginx/http.d/
# WWW
ADD ./www /srv/www/
WORKDIR /srv
EXPOSE 80 443
ADD ./start.sh /start.sh
RUN chmod +x /start.sh
CMD ["sh","/start.sh"]
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论