Commit 530e7678 authored by Thomas Parisot's avatar Thomas Parisot

Fully functional reproducible setup

parent ff079b5a
FROM alterway/php:5.3-fpm
RUN gpg --keyserver keys.gnupg.net --recv-key 89DF5277 && gpg -a --export 89DF5277 | apt-key add - && \
echo 'deb http://archive.debian.org/debian wheezy main' > /etc/apt/sources.list && \
echo 'deb http://packages.dotdeb.org wheezy all' >> /etc/apt/sources.list && \
echo 'deb-src http://packages.dotdeb.org wheezy all' >> /etc/apt/sources.list && \
apt-get update && apt-get upgrade -y && \
apt-get install -y libbz2-dev libzip-dev php5-curl php5-mysql
RUN docker-php-ext-install gd zip xml mbstring curl mysql curl
RUN mkdir -p upload \
docannexe docannexe/file docannexe/image \
lodel-0.9 \
lodel/sources lodel/icons \
lodeladmin-0.9/CACHE CACHE
RUN chmod -R g-rwx lodeladmin-0.9/CACHE CACHE docannexe lodel lodel-0.9
version: "3.7"
services:
db:
image: mariadb:10.5
networks:
- backend
volumes:
- db-data:/var/lib/mysql
environment:
MYSQL_ALLOW_EMPTY_PASSWORD: 1
MYSQL_ROOT_PASSWORD: ''
MYSQL_ROOT_HOST: '%'
MYSQL_DATABASE: lodel
command: --character-set-server=utf8mb4 --collation-server=utf8mb4_unicode_ci
healthcheck:
test: ["CMD", "mysqladmin", "ping", "--silent"]
web:
image: nginx:1
volumes:
- ./:/app
- ./share-0.9/nginx/site.conf:/etc/nginx/conf.d/default.conf
depends_on:
- app
networks:
- frontend
ports:
- "8000:80"
app:
build: .
# image: php:7.3-fpm-alpine-gd-zip
volumes:
- ./:/app
networks:
- frontend
- backend
depends_on:
- db
networks:
frontend:
backend:
volumes:
db-data:
......@@ -11,6 +11,12 @@ server {
fastcgi_pass app:9000;
fastcgi_index index.php;
include fastcgi_params;
#app config
fastcgi_param MYSQL_HOST 'db';
fastcgi_param MYSQL_DB 'lodel';
fastcgi_param MYSQL_USER 'root';
fastcgi_param MYSQL_PASSWORD '';
#fcgi config
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
fastcgi_param PATH_INFO $fastcgi_path_info;
fastcgi_param SERVER_NAME $host;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment