BookStack/docker-compose.yml

53 lines
1.3 KiB
YAML
Raw Permalink Normal View History

2019-06-23 19:16:45 +08:00
# This is a Docker Compose configuration
# intended for development purposes only
2019-06-23 19:16:45 +08:00
volumes:
db: {}
services:
db:
image: mysql:8.4
2019-06-23 19:16:45 +08:00
environment:
MYSQL_DATABASE: bookstack-dev
2019-06-23 19:16:45 +08:00
MYSQL_USER: bookstack-test
MYSQL_PASSWORD: bookstack-test
MYSQL_RANDOM_ROOT_PASSWORD: 'true'
volumes:
- ./dev/docker/init.db:/docker-entrypoint-initdb.d
2019-06-23 19:16:45 +08:00
- db:/var/lib/mysql
app:
build:
context: .
2019-08-13 04:19:58 +08:00
dockerfile: ./dev/docker/Dockerfile
environment:
APP_URL: http://localhost:${DEV_PORT:-8080}
DB_CONNECTION: mysql
DB_HOST: db
DB_PORT: 3306
DB_DATABASE: bookstack-dev
2019-08-13 04:19:58 +08:00
DB_USERNAME: bookstack-test
DB_PASSWORD: bookstack-test
TEST_DATABASE_URL: mysql://bookstack-test:bookstack-test@db/bookstack-test
MAIL_DRIVER: smtp
MAIL_HOST: mailhog
MAIL_PORT: 1025
2019-06-23 19:16:45 +08:00
ports:
2019-08-13 04:19:58 +08:00
- ${DEV_PORT:-8080}:80
2019-06-23 19:16:45 +08:00
volumes:
- ./:/app
- ./dev/docker/php/conf.d/xdebug.ini:/usr/local/etc/php/conf.d/docker-php-ext-xdebug.ini
2019-08-13 04:19:58 +08:00
entrypoint: /app/dev/docker/entrypoint.app.sh
extra_hosts:
- "host.docker.internal:host-gateway"
2019-06-23 19:16:45 +08:00
node:
image: node:22-alpine
2019-06-23 19:16:45 +08:00
working_dir: /app
user: node
2019-06-23 19:16:45 +08:00
volumes:
- ./:/app
2019-08-13 04:19:58 +08:00
entrypoint: /app/dev/docker/entrypoint.node.sh
mailhog:
image: mailhog/mailhog
ports:
- ${DEV_MAIL_PORT:-8025}:8025