Untitled
user_3839718
dockerfile
2 years ago
1.5 kB
4
Indexable
# Stage 1: Composer dependencies FROM composer:1.10.19 AS composer # Stage 2: PHP dependencies FROM php:7.4-fpm AS php # copy the Composer PHAR from the Composer image into the PHP image COPY --from=composer /usr/bin/composer /usr/bin/composer # Install required system packages RUN apt-get update && apt-get install -y git zip unzip WORKDIR /apps/chickenboy-site # Copy application files from the composer stage COPY . . # Install Pyton 3 RUN apt-get update && apt-get install -y python3-pip # Install pandas, numpy and mysql-connector RUN pip3 install pandas RUN pip3 install numpy RUN pip3 install mysql-connector==2.2.9 # Install dependencies RUN apt-get update && apt-get install -y \ libicu-dev \ libzip-dev \ zip \ unzip \ git \ wget \ awscli \ && docker-php-ext-configure intl \ && docker-php-ext-install intl \ && docker-php-ext-install zip \ && docker-php-ext-install bcmath \ && docker-php-ext-install sockets \ && docker-php-ext-install mysqli pdo pdo_mysql # Composer install RUN composer install # Permissions RUN chmod -R 777 /apps/chickenboy-site RUN chmod -R 777 /apps/chickenboy-site/data # Copy PHP configurations COPY provisioning/php/chickenboy.ini /usr/local/etc/php/conf.d/chickenboy.ini # Configure AWS CLI COPY provisioning/aws/config /root/.aws/config COPY provisioning/aws/credentials /root/.aws/credentials ARG DEPLOY_TO COPY provisioning/php/${DEPLOY_TO}.php /apps/chickenboy-site/config/autoload/local.php EXPOSE 80 8080 443
Editor is loading...