aurweb/docker-compose.override.yml
Steven Guikal 1cb1ce0d99 feat(docker): allow production docker setup to use dedicated mariadb
Signed-off-by: Steven Guikal <void@fluix.one>
2021-10-19 17:21:03 -04:00

70 lines
1.7 KiB
YAML

services:
mariadb:
image: aurweb:latest
init: true
entrypoint: /docker/mariadb-entrypoint.sh
command: /usr/bin/mysqld_safe --datadir=/var/lib/mysql
ports:
# This will expose mariadbd on 127.0.0.1:13306 in the host.
# Ex: `mysql -uaur -paur -h 127.0.0.1 -P 13306 aurweb`
- "13306:3306"
volumes:
- mariadb_run:/var/run/mysqld # Bind socket in this volume.
- mariadb_data:/var/lib/mysql
healthcheck:
test: "bash /docker/health/mariadb.sh"
mariadb_init:
depends_on:
mariadb:
condition: service_healthy
ca:
volumes:
- ./cache:/cache
git:
volumes:
- git_data:/aurweb/aur.git
- ./cache:/cache
smartgit:
volumes:
- git_data:/aurweb/aur.git
- ./cache:/cache
- smartgit_run:/var/run/smartgit
depends_on:
mariadb:
condition: service_healthy
php-fpm:
volumes:
- ./cache:/cache
- ./aurweb:/aurweb/aurweb
- ./migrations:/aurweb/migrations
- ./test:/aurweb/test
- ./web/html:/aurweb/web/html
- ./web/template:/aurweb/web/template
- ./web/lib:/aurweb/web/lib
- ./templates:/aurweb/templates
fastapi:
volumes:
- ./cache:/cache
- ./aurweb:/aurweb/aurweb
- ./migrations:/aurweb/migrations
- ./test:/aurweb/test
- ./web/html:/aurweb/web/html
- ./web/template:/aurweb/web/template
- ./web/lib:/aurweb/web/lib
- ./templates:/aurweb/templates
nginx:
volumes:
- git_data:/aurweb/aur.git
- ./cache:/cache
- ./logs:/var/log/nginx
- ./web/html:/aurweb/web/html
- ./web/template:/aurweb/web/template
- ./web/lib:/aurweb/web/lib
- smartgit_run:/var/run/smartgit