-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathdocker-compose.yaml
81 lines (74 loc) · 2.58 KB
/
docker-compose.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
# This docker-compose file will bring up a production system.
# As per README.md, direct docker-compose commands are not
# recommended because that requires many environment variables
# to be set. Instead, the use of deploy_tool.py is recommended
# as per README.md.
# Before any other docker-compose commands above are executed,
# the necessary images must be built according to the instructions
# in README.md.
# python3 deploy_tool.py <SITE_NAME> dc build
version: '3.6'
services:
# The RopeWiki MySQL database; see instructions in README.md to build the image
ropewiki_db:
image: ropewiki/database
build:
context: .
dockerfile: database/Dockerfile
ports:
- "22001:22"
environment:
- MYSQL_ROOT_PASSWORD=${RW_ROOT_DB_PASSWORD:-thispasswordonlyworksuntildbisrestored}
- RW_ROOT_DB_PASSWORD=${RW_ROOT_DB_PASSWORD:-}
volumes:
- ropewiki_database_storage:/var/lib/mysql
- ${SQL_BACKUP_FOLDER:?SQL_BACKUP_FOLDER environment variable must be set}:/root/backup
# restart: always
# The main RopeWiki server running MediaWiki; see instructions in README.md to build the image
ropewiki_webserver:
image: ropewiki/webserver
build:
context: .
dockerfile: webserver/Dockerfile
args:
codebaseversion: ${CODEBASE_VERSION:-When this image was built with docker-compose, <pre>CODEBASE_VERSION</pre> environment variable was not present.}
ports:
- "8080:80"
- "22002:22"
environment:
- WG_PROTOCOL=${WG_PROTOCOL:-http}
- WG_HOSTNAME=${WG_HOSTNAME:-localhost:8080}
- WG_DB_SERVER=ropewiki_db
- WG_DB_USER=${WG_DB_USERNAME:-ropewiki}
- WG_DB_PASSWORD=${WG_DB_PASSWORD:-thispasswordonlyworksuntildbisrestored}
depends_on:
- ropewiki_db
volumes:
- ${IMAGES_FOLDER:?IMAGES_FOLDER environment variable must be set}:/usr/share/nginx/html/ropewiki/images
#restart: always
# The reverse proxy that directs traffic to the appropriate places; see instructions in README.md to build the image
ropewiki_reverse_proxy:
image: ropewiki/reverse_proxy
build:
context: .
dockerfile: reverse_proxy/Dockerfile
logging:
driver: json-file
options:
max-size: 10m
# max-file: 10
ports:
- "80:80"
- "443:443"
environment:
- WG_HOSTNAME=${WG_HOSTNAME:-localhost}
depends_on:
- ropewiki_webserver
volumes:
- ropewiki_proxy_certs:/etc/letsencrypt
# restart: always
volumes:
ropewiki_database_storage:
name: ropewiki_database_storage
ropewiki_proxy_certs:
name: ropewiki_proxy_certs