Skip to content

Instantly share code, notes, and snippets.

@danielschmitz
Created March 26, 2019 10:03
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save danielschmitz/f0dd2e9a3b82eae6f8ce37d81399a9dd to your computer and use it in GitHub Desktop.
Save danielschmitz/f0dd2e9a3b82eae6f8ce37d81399a9dd to your computer and use it in GitHub Desktop.
version: "3"
services:
web:
build: ./.docker/php7
container_name: reportei_web
tty: true
stdin_open: true
hostname: reports
domainname: local.com
environment:
- XDEBUG_ENABLED=true
- PHP_IDE_CONFIG=serverName=ambientum
volumes:
- ./:/var/www/html
- ./.docker/php7/sites-enabled:/etc/apache2/sites-enabled
- ./.docker/php7/envvars:/etc/apache2/envvars
ports:
- "8081:80"
- "8443:443"
networks:
network:
ipv4_address: 172.20.128.25
depends_on:
- mysql
FROM php:7.1-apache
COPY server.crt /etc/apache2/ssl/server.crt
COPY server.key /etc/apache2/ssl/server.key
RUN useradd -u 1000 reportei
RUN apt-get update && apt-get install -y \
libfreetype6-dev \
libjpeg62-turbo-dev \
libmcrypt-dev \
zlib1g-dev \
libbz2-dev \
libxml2-dev \
git zip \
libfontconfig \
&& rm -rf /var/lib/apt/lists/* \
&& docker-php-ext-install -j$(nproc) iconv mcrypt \
&& docker-php-ext-configure gd --with-freetype-dir=/usr/include/ --with-jpeg-dir=/usr/include/ \
&& docker-php-ext-install -j$(nproc) gd \
&& docker-php-ext-install zip \
&& docker-php-ext-install soap \
&& docker-php-ext-install sockets \
&& docker-php-ext-install bz2 \
&& docker-php-ext-install pdo pdo_mysql
RUN curl -sS https://getcomposer.org/installer | php -- --install-dir=/usr/local/bin --filename=composer
RUN a2enmod rewrite && a2enmod ssl
# Node
RUN apt-get update && apt-get install gnupg gnupg2 gnupg1 -y
RUN curl -sL https://deb.nodesource.com/setup_10.x | bash -
RUN apt-get install nodejs -y
# Chrome/Puppeteer
RUN apt-get update && \
apt-get install -yq --no-install-recommends \
libasound2 libatk1.0-0 libc6 libcairo2 libcups2 libdbus-1-3 \
libexpat1 libfontconfig1 libgcc1 libgconf-2-4 libgdk-pixbuf2.0-0 libglib2.0-0 libgtk-3-0 libnspr4 \
libpango-1.0-0 libpangocairo-1.0-0 libstdc++6 libx11-6 libx11-xcb1 libxcb1 \
libxcursor1 libxdamage1 libxext6 libxfixes3 libxi6 libxrandr2 libxrender1 libxss1 libxtst6 \
libnss3
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment