Skip to content
This repository has been archived by the owner on Apr 17, 2024. It is now read-only.

Update to the latest requirements #39

Open
wants to merge 8 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@ The container doesn't automatically run `drush site-install` because we want it

`docker-compose exec php composer run-script install:with-mysql`

Environment configuration used by the install script is described in `.env`.

# Persistence

Persistent state is stored in a database volume named `data`. You can destroy and recreate the containers as much as you like and your site will be preserved until you also destroy the volume.
Expand Down
2 changes: 1 addition & 1 deletion database/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
FROM amazeeio/centos:7

ENV MARIADB_VERSION=10.1
ENV MARIADB_VERSION=10.3

RUN { \
echo '[mariadb]'; \
Expand Down
12 changes: 5 additions & 7 deletions docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,7 @@ services:
nginx:
build: ./nginx
ports:
- "80:80"
- "443:443"
- "80:8080"
networks:
- contenta
volumes:
Expand All @@ -15,27 +14,26 @@ services:
- php
php:
build: ./php
ports:
- "9000:9000"
volumes:
- ./www:/var/www:cached
env_file:
- .env
networks:
- contenta
- contenta_internal
depends_on: [database]
database:
build: ./database
ports:
- "3306:3306"
volumes:
- data:/var/lib/mysql
env_file:
- .env
networks:
- contenta
- contenta_internal

volumes:
data:

networks:
contenta:
contenta_internal:
14 changes: 12 additions & 2 deletions nginx/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,5 +1,15 @@
FROM amazeeio/centos7-nginx:1.10
FROM amazeeio/centos:7

COPY conf/drupal.conf /etc/nginx/sites/drupal.conf
RUN yum install -y epel-release \
yum check-update \
yum update -y
RUN yum install -y nginx \
yum clean all

EXPOSE 8080
COPY conf/drupal.conf /etc/nginx/conf.d/default.conf

RUN fix-permissions /etc/nginx
RUN curl -sLo /usr/local/bin/ep https://github.com/kreuzwerker/envplate/releases/download/v0.0.8/ep-linux && chmod +x /usr/local/bin/ep

CMD [ "/usr/local/bin/ep", "-v", "/etc/nginx/conf.d/default.conf", "--", "/usr/sbin/nginx", "-g", "daemon off;" ]
3 changes: 2 additions & 1 deletion nginx/conf/drupal.conf
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
server {
listen 80;
listen 8080 default_server;
listen [::]:8080 default_server;

fastcgi_keep_conn on;
root /var/www/web;
Expand Down
5 changes: 3 additions & 2 deletions php/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ FROM amazeeio/centos:7
RUN yum install -y epel-release \
http://rpms.remirepo.net/enterprise/remi-release-7.rpm \
yum-utils && \
yum-config-manager --enable remi-php71 && \
yum-config-manager --enable remi-php74 && \
yum update -y && \
yum install -y \
php-bcmath \
Expand All @@ -22,6 +22,7 @@ RUN yum install -y epel-release \
php-opcache \
php-pcntl \
php-pdo \
php-zip \
php-pecl-apcu \
php-pecl-apcu-bc \
php-pecl-geoip \
Expand All @@ -39,7 +40,7 @@ RUN yum install -y epel-release \
yum clean all

# Install Composer
ENV COMPOSER_VERSION 1.9.0
ENV COMPOSER_VERSION 1.10.20
RUN curl -sS https://getcomposer.org/installer | php -- --install-dir=/usr/local/bin --filename=composer --version=${COMPOSER_VERSION} && \
chmod +x /usr/local/bin/composer && \
composer global require "hirak/prestissimo:^0.3" && \
Expand Down