Standardize Compose Files
This commit is contained in:
188
docker-compose/wikis/docker-compose.yaml
Normal file
188
docker-compose/wikis/docker-compose.yaml
Normal file
@@ -0,0 +1,188 @@
|
||||
services:
|
||||
# DokuWiki - Wiki without database
|
||||
# Access at: https://wiki.${DOMAIN}
|
||||
# Uses Sablier lazy loading - starts on-demand, stops after 5min inactivity
|
||||
dokuwiki:
|
||||
image: lscr.io/linuxserver/dokuwiki:latest
|
||||
container_name: dokuwiki
|
||||
restart: no
|
||||
networks:
|
||||
- homelab-network
|
||||
- traefik-network
|
||||
ports:
|
||||
- "8087:80"
|
||||
volumes:
|
||||
- ./dokuwiki/config:/config
|
||||
environment:
|
||||
- PUID=${PUID}
|
||||
- PGID=${PGID}
|
||||
- TZ=${TZ}
|
||||
labels:
|
||||
# TRAEFIK CONFIGURATION
|
||||
# Service metadata
|
||||
- "com.centurylinklabs.watchtower.enable=true"
|
||||
- "homelab.category=productivity"
|
||||
- "homelab.description=File-based wiki"
|
||||
- "traefik.enable=true"
|
||||
# Router configuration
|
||||
- "traefik.http.routers.dokuwiki.rule=Host(`dokuwiki.${DOMAIN}`)"
|
||||
- "traefik.http.routers.dokuwiki.entrypoints=websecure"
|
||||
- "traefik.http.routers.dokuwiki.tls.certresolver=letsencrypt"
|
||||
- "traefik.http.routers.dokuwiki.middlewares=authelia@docker"
|
||||
# Service configuration
|
||||
- "traefik.http.services.dokuwiki.loadbalancer.server.port=8087"
|
||||
# Sablier configuration
|
||||
- "sablier.enable=true"
|
||||
- "sablier.group=${SERVER_HOSTNAME}-dokuwiki"
|
||||
- "sablier.start-on-demand=true"
|
||||
|
||||
# BookStack - Documentation platform
|
||||
# Access at: https://docs.${DOMAIN}
|
||||
# Uses Sablier lazy loading - starts on-demand, stops after 5min inactivity
|
||||
bookstack:
|
||||
image: lscr.io/linuxserver/bookstack:latest
|
||||
container_name: bookstack
|
||||
restart: no
|
||||
networks:
|
||||
- homelab-network
|
||||
- traefik-network
|
||||
ports:
|
||||
- "6875:80"
|
||||
volumes:
|
||||
- ./bookstack/config:/config
|
||||
environment:
|
||||
- PUID=${PUID}
|
||||
- PGID=${PGID}
|
||||
- APP_URL=https://bookstack.${DOMAIN}
|
||||
- DB_HOST=bookstack-db
|
||||
- DB_PORT=3306
|
||||
- DB_DATABASE=bookstack
|
||||
- DB_USERNAME=bookstack
|
||||
- DB_PASSWORD=${BOOKSTACK_DB_PASSWORD}
|
||||
- APP_KEY=base64:NsYD8+8MAvtBhK8xw9p8pxQDy4x8aOQi/78M3CsseAw=
|
||||
healthcheck:
|
||||
test: ["CMD", "curl", "-f", "http://localhost/"]
|
||||
interval: 30s
|
||||
timeout: 10s
|
||||
retries: 3
|
||||
start_period: 60s
|
||||
depends_on:
|
||||
- bookstack-db
|
||||
labels:
|
||||
# TRAEFIK CONFIGURATION
|
||||
# Service metadata
|
||||
- "com.centurylinklabs.watchtower.enable=true"
|
||||
- "homelab.category=productivity"
|
||||
- "homelab.description=Documentation and wiki platform"
|
||||
- "traefik.enable=true"
|
||||
# Router configuration
|
||||
- "traefik.http.routers.bookstack.rule=Host(`bookstack.${DOMAIN}`)"
|
||||
- "traefik.http.routers.bookstack.entrypoints=websecure"
|
||||
- "traefik.http.routers.bookstack.tls.certresolver=letsencrypt"
|
||||
- "traefik.http.routers.bookstack.middlewares=authelia@docker"
|
||||
# Service configuration
|
||||
- "traefik.http.services.bookstack.loadbalancer.server.port=6875"
|
||||
# Sablier configuration
|
||||
- "sablier.enable=true"
|
||||
- "sablier.group=${SERVER_HOSTNAME}-bookstack"
|
||||
- "sablier.start-on-demand=true"
|
||||
|
||||
bookstack-db:
|
||||
image: mariadb:10.11
|
||||
container_name: bookstack-db
|
||||
restart: no
|
||||
networks:
|
||||
- homelab-network
|
||||
volumes:
|
||||
- bookstack-db-data:/var/lib/mysql
|
||||
environment:
|
||||
- MYSQL_ROOT_PASSWORD=${BOOKSTACK_DB_ROOT_PASSWORD}
|
||||
- MYSQL_DATABASE=bookstack
|
||||
- MYSQL_USER=bookstack
|
||||
- MYSQL_PASSWORD=${BOOKSTACK_DB_PASSWORD}
|
||||
labels:
|
||||
- "homelab.category=productivity"
|
||||
- "homelab.description=BookStack database"
|
||||
|
||||
# MediaWiki - Wiki platform
|
||||
# Access at: https://mediawiki.${DOMAIN}
|
||||
mediawiki:
|
||||
image: mediawiki:latest
|
||||
container_name: mediawiki
|
||||
restart: no
|
||||
networks:
|
||||
- homelab-network
|
||||
- traefik-network
|
||||
ports:
|
||||
- "8086:80"
|
||||
volumes:
|
||||
- ./mediawiki/images:/var/www/html/images
|
||||
- ./mediawiki/LocalSettings.php:/var/www/html/LocalSettings.php
|
||||
environment:
|
||||
- MEDIAWIKI_DB_HOST=mediawiki-db
|
||||
- MEDIAWIKI_DB_NAME=mediawiki
|
||||
- MEDIAWIKI_DB_USER=mediawiki
|
||||
- MEDIAWIKI_DB_PASSWORD=${MEDIAWIKI_DB_PASSWORD}
|
||||
healthcheck:
|
||||
test: ["CMD", "curl", "-f", "http://localhost/"]
|
||||
interval: 30s
|
||||
timeout: 10s
|
||||
retries: 3
|
||||
start_period: 60s
|
||||
depends_on:
|
||||
- mediawiki-db
|
||||
labels:
|
||||
# TRAEFIK CONFIGURATION
|
||||
# Service metadata
|
||||
- "com.centurylinklabs.watchtower.enable=true"
|
||||
- "homelab.category=productivity"
|
||||
- "homelab.description=MediaWiki platform"
|
||||
- "traefik.enable=true"
|
||||
# Router configuration
|
||||
- "traefik.http.routers.mediawiki.rule=Host(`mediawiki.${DOMAIN}`)"
|
||||
- "traefik.http.routers.mediawiki.entrypoints=websecure"
|
||||
- "traefik.http.routers.mediawiki.tls.certresolver=letsencrypt"
|
||||
- "traefik.http.routers.mediawiki.middlewares=authelia@docker"
|
||||
# Service configuration
|
||||
- "traefik.http.services.mediawiki.loadbalancer.server.port=8086"
|
||||
# Sablier configuration
|
||||
- "sablier.enable=true"
|
||||
- "sablier.group=${SERVER_HOSTNAME}-mediawiki"
|
||||
- "sablier.start-on-demand=true"
|
||||
|
||||
mediawiki-db:
|
||||
image: mariadb:10.11
|
||||
container_name: mediawiki-db
|
||||
restart: no
|
||||
networks:
|
||||
- homelab-network
|
||||
volumes:
|
||||
- mediawiki-db-data:/var/lib/mysql
|
||||
environment:
|
||||
- MYSQL_ROOT_PASSWORD=${MEDIAWIKI_DB_ROOT_PASSWORD}
|
||||
- MYSQL_DATABASE=mediawiki
|
||||
- MYSQL_USER=mediawiki
|
||||
- MYSQL_PASSWORD=${MEDIAWIKI_DB_PASSWORD}
|
||||
labels:
|
||||
- "homelab.category=productivity"
|
||||
- "homelab.description=MediaWiki database"
|
||||
|
||||
volumes:
|
||||
bookstack-db-data:
|
||||
mediawiki-db-data:
|
||||
|
||||
networks:
|
||||
homelab-network:
|
||||
external: true
|
||||
traefik-network:
|
||||
external: true
|
||||
|
||||
x-dockge:
|
||||
urls:
|
||||
# Proxied URLs (through Traefik)
|
||||
- https://bookstack.${DOMAIN}
|
||||
- https://{$SERVER_IP}:6875
|
||||
- https://dokuwiki.${DOMAIN}
|
||||
- https://{$SERVER_IP}:8087
|
||||
- https://mediawiki.${DOMAIN}
|
||||
- https://{$SERVER_IP}:8086
|
||||
Reference in New Issue
Block a user