inital setup
This commit is contained in:
75
docker-compose.yml
Normal file
75
docker-compose.yml
Normal file
@@ -0,0 +1,75 @@
|
||||
# https://docs.docker.com/compose/compose-file/compose-file-v3/
|
||||
---
|
||||
version: "3.9"
|
||||
services:
|
||||
wiki:
|
||||
image: requarks/wiki:${WIKITAG:-latest}
|
||||
container_name: wiki
|
||||
restart: unless-stopped
|
||||
depends_on:
|
||||
- db
|
||||
- elastic
|
||||
ports:
|
||||
- 3000:3000
|
||||
deploy:
|
||||
replicas: 1
|
||||
placement:
|
||||
max_replicas_per_node: 1
|
||||
update_config:
|
||||
parallelism: 1
|
||||
delay: 10s
|
||||
# volumes: # only need if using sqlite
|
||||
# - ${BASEDIR:-.}/files/data/:/data/
|
||||
# - ${BASEDIR:-.}/files/config/:/config/
|
||||
environment:
|
||||
- DB_TYPE=${DB_TYPE:-mariadb}
|
||||
- DB_HOST=${DB_HOST:-db}
|
||||
- DB_PORT=${DB_PORT:-3306}
|
||||
- DB_NAME=${DBNAME:-wikijs}
|
||||
- DB_USER=${DB_USER:-wikijs}
|
||||
- DB_PASS=${DB_PASS:-wikijspasswd}
|
||||
networks:
|
||||
- backend
|
||||
- wikinet
|
||||
|
||||
db:
|
||||
image: mariadb:${DBTAG:-latest}
|
||||
container_name: wikidb
|
||||
restart: unless-stopped
|
||||
deploy:
|
||||
replicas: 1
|
||||
placement:
|
||||
max_replicas_per_node: 1
|
||||
update_config:
|
||||
parallelism: 1
|
||||
delay: 10s
|
||||
volumes:
|
||||
- ${BASEDIR:-.}/files/db/:/var/lib/mysql/
|
||||
environment:
|
||||
- MARIADB_RANDOM_ROOT_PASSWORD=yes
|
||||
- MARIADB_DATABASE=${DB_NAME:-wikijs}
|
||||
- MARIADB_USER=${DB_USER:-wikijs}
|
||||
- MARIADB_PASSWORD=${DB_PASS:-wikijspasswd}
|
||||
networks:
|
||||
- wikinet
|
||||
|
||||
elastic:
|
||||
image: elasticsearch:${SEARCHTAG:-latest}
|
||||
container_name: elastic
|
||||
deploy:
|
||||
replicas: 1
|
||||
placement:
|
||||
max_replicas_per_node: 1
|
||||
update_config:
|
||||
parallelism: 1
|
||||
delay: 10s
|
||||
environment:
|
||||
- xpack.security.enabled=false
|
||||
- "discovery.type=single-node"
|
||||
networks:
|
||||
- wikinet
|
||||
|
||||
networks:
|
||||
backend:
|
||||
name: ${INTRANET:-backend}
|
||||
wikinet:
|
||||
Reference in New Issue
Block a user