mirror of
https://github.com/PAPAMICA/docker-compose-collection.git
synced 2026-01-19 00:37:32 +01:00
81 lines
2.4 KiB
YAML
81 lines
2.4 KiB
YAML
# Maintainer: Mickael "PAPAMICA" Asseline
|
|
# Update: 2022-05-10
|
|
|
|
#& type: 3
|
|
#& title: Bookstack
|
|
#& description: Wiki selfhosted
|
|
#& note: Website: <a href='https://www.bookstackapp.com/' target='_blank' rel='noopener'>Bookstackapp.com</a>
|
|
#& categories: SelfHosted, PAPAMICA
|
|
#& platform: linux
|
|
#& logo: https://img.papamica.com/logo/bookstack.png
|
|
|
|
#% SERVICE: Name of the service (No spaces or points) [bookstack]
|
|
#% DATA_LOCATION: data localization (Example: /apps/service) [/_data/apps]
|
|
#% URL: Service URL (Example: service.papamica.fr or service.com)
|
|
#% NETWORK: Your Traefik network (Example: proxy) [proxy]
|
|
#% DB_USER: Database user (No spaces or points) [bookstack]
|
|
#% DB_PASSWORD: Database user password
|
|
#% DB_ROOT: Database root password
|
|
#% TIME_ZONE: Time zone (Example : Europe/Paris) [Europe/Paris]
|
|
|
|
# Work with Portainer
|
|
version: "2"
|
|
services:
|
|
# BookStack : https://www.bookstackapp.com/
|
|
bookstack:
|
|
image: linuxserver/bookstack:latest
|
|
container_name: $SERVICE
|
|
environment:
|
|
- PUID=1000
|
|
- PGID=1000
|
|
- DB_HOST=bookstack_db
|
|
- DB_USER=$DB_USER
|
|
- DB_PASS=$DB_PASSWORD
|
|
- DB_DATABASE=bookstackapp
|
|
- APP_URL=https://$URL
|
|
volumes:
|
|
- $DATA_LOCATION/$SERVICE/config:/config
|
|
healthcheck:
|
|
test: curl --fail http://localhost:80 || exit 1
|
|
interval: 1m
|
|
timeout: 30s
|
|
retries: 3
|
|
restart: unless-stopped
|
|
depends_on:
|
|
- bookstack_db
|
|
networks:
|
|
- default
|
|
labels:
|
|
- "autoupdate=monitor" # https://github.com/PAPAMICA/container-updater
|
|
- "traefik.enable=true"
|
|
- "traefik.http.routers.$SERVICE.entrypoints=https"
|
|
- "traefik.http.routers.$SERVICE.rule=Host(`$URL`)"
|
|
- "traefik.http.routers.$SERVICE.tls=true"
|
|
- "traefik.http.routers.$SERVICE.tls.certresolver=http"
|
|
- "traefik.docker.network=$NETWORK"
|
|
|
|
bookstack_db:
|
|
image: linuxserver/mariadb:version-10.5.12-r0
|
|
container_name: bookstack_db
|
|
environment:
|
|
- PUID=1000
|
|
- PGID=1000
|
|
- MYSQL_ROOT_PASSWORD=$DB_ROOT
|
|
- TZ=$TIME_ZONE
|
|
- MYSQL_DATABASE=bookstackapp
|
|
- MYSQL_USER=$DB_USER
|
|
- MYSQL_PASSWORD=$DB_PASSWORD
|
|
healthcheck:
|
|
test: ["CMD", "mysqladmin" ,"ping", "-h", "localhost"]
|
|
timeout: 20s
|
|
retries: 10
|
|
volumes:
|
|
- $DATA_LOCATION/$SERVICE/db:/config
|
|
restart: unless-stopped
|
|
networks:
|
|
- default
|
|
|
|
networks:
|
|
default:
|
|
external:
|
|
name: $NETWORK |