piler-docker/config/piler-ssl.yml

110 lines
2.6 KiB
YAML
Raw Normal View History

2022-03-08 11:02:21 +00:00
version: "3"
services:
2022-03-09 13:28:14 +00:00
nginx-proxy:
image: jwilder/nginx-proxy
container_name: nginx-proxy
restart: always
ports:
- "80:80"
- "443:443"
volumes:
- ./nginx-data/certs:/etc/nginx/certs
- ./nginx-data/vhost.d:/etc/nginx/vhost.d
- ./nginx-data/html:/usr/share/nginx/html
- /var/run/docker.sock:/tmp/docker.sock:ro
nginx-letsencrypt:
image: jrcs/letsencrypt-nginx-proxy-companion
container_name: nginx-letsencrypt
restart: always
volumes_from:
- nginx-proxy
volumes:
- /var/run/docker.sock:/var/run/docker.sock:ro
environment:
- DEFAULT_EMAIL=${LETSENCRYPT_EMAIL}
2022-03-08 11:02:21 +00:00
mysql:
image: mariadb:10.5
2022-03-09 13:28:14 +00:00
container_name: mysql-piler
2022-03-08 11:02:21 +00:00
restart: unless-stopped
cap_drop:
- ALL
cap_add:
- dac_override
- setuid
- setgid
environment:
- MYSQL_DATABASE=${MYSQL_DATABASE}
- MYSQL_USER=${MYSQL_USER}
- MYSQL_PASSWORD=${MYSQL_PASSWORD}
- MYSQL_RANDOM_ROOT_PASSWORD=yes
- "TZ=Europe/Berlin"
command: --character-set-server=utf8mb4 --collation-server=utf8mb4_unicode_ci
healthcheck:
test: mysql --user=${MYSQL_USER} --password=${MYSQL_PASSWORD} piler --execute "show tables"
interval: "60s"
timeout: "5s"
start_period: "15s"
retries: 3
volumes:
- db_data:/var/lib/mysql
memcached:
image: memcached:latest
2022-03-09 13:28:14 +00:00
container_name: memcached-piler
2022-03-08 11:02:21 +00:00
restart: unless-stopped
cap_drop:
- ALL
command: -m 64
piler:
image: sutoj/piler:1.3.11
container_name: piler
restart: unless-stopped
2022-03-09 13:28:14 +00:00
expose:
- "80"
2022-03-08 11:02:21 +00:00
hostname: ${PILER_DOMAIN}
init: true
environment:
- MYSQL_DATABASE=${MYSQL_DATABASE}
- MYSQL_USER=${MYSQL_USER}
- MYSQL_PASSWORD=${MYSQL_PASSWORD}
- MYSQL_HOSTNAME=mysql
- PILER_HOSTNAME=${PILER_DOMAIN}
- MEMCACHED_HOST=memcached
- TZ=Europe/Berlin
2022-03-09 13:28:14 +00:00
- VIRTUAL_HOST=${PILER_DOMAIN}
- LETSENCRYPT_HOST=${PILER_DOMAIN}
- LETSENCRYPT_EMAIL=${LETSENCRYPT_EMAIL}
2022-03-08 11:02:21 +00:00
ports:
- "25:25"
volumes:
- piler_etc:/etc/piler
- piler_var:/var/piler
- /etc/localtime:/etc/localtime
healthcheck:
test: curl -s smtp://localhost/
interval: "60s"
timeout: "3s"
start_period: "15s"
retries: 3
deploy:
resources:
reservations:
memory: 512M
limits:
memory: 512M
depends_on:
- "memcached"
- "mysql"
2022-03-09 13:28:14 +00:00
networks:
default:
external:
name: nginx-proxy
2022-03-08 11:02:21 +00:00
volumes:
2022-03-09 13:28:14 +00:00
db_data:
piler_etc:
piler_var: