如何使用docker安装php和php扩展

时间:2020-06-20 17:02:06

标签: docker debian php-7.3

我在使用docker的Debian:9上进行apt-get安装时遇到问题

    FROM debian:9
    RUN apt-get update && \
    apt-get install -y nginx \
    php7.3 \
    php7.3-cli \
    php7.3-common \
    php7.3-curl \
    php7.3-fpm \
    php7.3-gd \
    php7.3-json \
    php7.3-mbstring \
    php7.3-mysql && \
    sed -i -e"s/^;cgi\.fix_pathinfo\=1/cgi.fix_pathinfo=0/" /etc/php/7.3/fpm/php.ini && \
    sed -i -e"s/^listen\ =\ \/run\/php\/php7.3-fpm.sock/listen = 127.0.0.1:9000/" /etc/php/7.3/fpm/pool.d/www.conf && \
    sed -i -e"s/keepalive_timeout\ 65\;/keepalive_timeout 2;/" /etc/nginx/nginx.conf
    WORKDIR /app

并返回E:

无法通过docker-compose up定位软件包php7.3

0 个答案:

没有答案