ogcore/docker/Dockerfile-jenkins-php

27 lines
857 B
Plaintext

FROM php:8.3-fpm-alpine
ENV COMPOSER_ALLOW_SUPERUSER=1
# Install PHP extensions
RUN docker-php-ext-install pdo mysqli pdo_mysql opcache
# Install Zip and more extension
RUN apk add --no-cache bash libzip-dev zip unzip
RUN docker-php-ext-install zip
# Install Composer
RUN curl -sS https://getcomposer.org/installer | php -- --install-dir=/usr/local/bin --filename=composer
RUN composer self-update
# Install bash
RUN apk add --no-cache bash git jq moreutils openssh rsync yq
ADD https://github.com/mlocati/docker-php-extension-installer/releases/latest/download/install-php-extensions /usr/local/bin/
RUN chmod +x /usr/local/bin/install-php-extensions
RUN install-php-extensions sockets
COPY . /var/www/html
RUN APP_ENV=prod composer install --no-dev --no-interaction --no-progress --optimize-autoloader
RUN chown -R www-data:www-data /var/www/html