[Docker][Amazon Linux 2]PHP8.1 install


  • Dockerfile
FROM amazonlinux:2

~省略~

# Install amazon-linux-extras 
RUN amazon-linux-extras install -y epel

# Install remi
RUN yum -y install \
http://rpms.remirepo.net/enterprise/remi-release-7.rpm

RUN yum -y install \
    pcre-devel \
    php81 \
    php81-php-cli \
    php81-php-common \
    php81-php-devel \
    php81-php-gd \
    php81-php-intl \
    php81-php-mbstring \
    php81-php-mysqlnd \
    php81-php-pear \
    php81-php-pecl-apcu \
    php81-php-process \
    php81-php-opcache \
    php81-php-redis \
    php81-php-soap \
    php81-php-pecl-xdebug3 \
    php81-php-xml \
    php81-php-zip \
    && \
    yum clean all

RUN alternatives --install /usr/bin/php php /usr/bin/php81 1

 

Was this helpful?

0 / 0

コメントを残す 0

Your email address will not be published. Required fields are marked *