-
Notifications
You must be signed in to change notification settings - Fork 1
/
docker-compose.yaml
154 lines (146 loc) · 4.37 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
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
services:
wordpress:
image: gcr.io/digital-ucdavis-edu/main-wp-website:v4.0.1
env_file:
- .env
ports:
- ${HOST_PORT:-8000}:80
restart: always
environment:
WORDPRESS_DB_HOST: ${DB_HOST:-db:3306}
WORDPRESS_DB_DATABASE: ${DB_DATABASE}
WORDPRESS_DB_PASSWORD: ${DB_PASSWORD}
WORDPRESS_DB_USER: ${DB_USER}
WORDPRESS_CONFIG_EXTRA: |
define('WP_SITEURL', '${SERVER_URL}' );
define('WP_HOME', '${SERVER_URL}' );
define('FORCE_SSL_ADMIN', true);
FORMINATOR_ADDON_RT_HOST: ${FORMINATOR_ADDON_RT_HOST:-https://rt.lib.ucdavis.edu}
tmpfs:
- /run
- /tmp
volumes:
- uploads-data:/usr/src/wordpress/wp-content/uploads
- wp-logs-data:/var/log/wordpress
- wphb-logs:/usr/src/wordpress/wp-content/wphb-logs
- wphb-cache:/usr/src/wordpress/wp-content/wphb-cache
elasticsearch:
image: docker.elastic.co/elasticsearch/elasticsearch:7.16.3
restart: always
environment:
- bootstrap.memory_lock=true
- discovery.type=single-node
- cluster.routing.allocation.disk.threshold_enabled=false
- cluster.routing.allocation.disk.watermark.flood_stage=98%
- "ES_JAVA_OPTS=-Xms512m -Xmx512m"
- xpack.security.enabled=false
ulimits:
memlock:
soft: -1
hard: -1
volumes:
- es-data:/usr/share/elasticsearch/data
kibana:
image: docker.elastic.co/kibana/kibana:7.16.3
restart: always
ports:
- ${KIBANA_HOST_PORT:-8002}:5601
environment:
- ELASTICSEARCH_URL:http://elasticsearch:9200
- xpack.security.enabled=false
- telemetry.enabled=false
depends_on:
- elasticsearch
monitoring:
image: gcr.io/digital-ucdavis-edu/main-wp-website-utils:v4.0.1
restart: always
env_file:
- .env
environment:
GOOGLE_APPLICATION_CREDENTIALS: /etc/service-account.json
depends_on:
- db
- wordpress
volumes:
- ./main-website-content-writer-key.json:/etc/service-account.json
command: /util-cmds/monitor.sh
init:
image: gcr.io/digital-ucdavis-edu/main-wp-website-utils:v4.0.1
env_file:
- .env
environment:
BACKUP_ENV: ${BACKUP_ENV:-sandbox}
WORDPRESS_DB_HOST: ${DB_HOST:-db:3306}
HOST_PORT: ${HOST_PORT:-8000}
WORDPRESS_DB_DATABASE: ${DB_DATABASE:-wordpress}
WORDPRESS_DB_PASSWORD: ${DB_PASSWORD:-wordpress}
WORDPRESS_DB_USER: ${DB_USER:-wordpress}
MYSQL_ROOT_PASSWORD: ${MYSQL_ROOT_PASSWORD:-wordpress}
GOOGLE_APPLICATION_CREDENTIALS: /etc/service-account.json
depends_on:
- db
- wordpress
volumes:
- uploads-data:/uploads
- wphb-cache:/wphb-cache
- ./main-website-content-reader-key.json:/etc/service-account.json
command: /util-cmds/init.sh
backup:
image: gcr.io/digital-ucdavis-edu/main-wp-website-utils:v4.0.1
env_file:
- .env
environment:
BACKUP_ENV: ${BACKUP_ENV:-sandbox}
WORDPRESS_DB_HOST: ${DB_HOST:-db:3306}
HOST_PORT: ${HOST_PORT:-8000}
WORDPRESS_DB_DATABASE: ${DB_DATABASE:-wordpress}
WORDPRESS_DB_PASSWORD: ${DB_PASSWORD:-wordpress}
WORDPRESS_DB_USER: ${DB_USER:-wordpress}
MYSQL_ROOT_PASSWORD: ${MYSQL_ROOT_PASSWORD:-wordpress}
GOOGLE_APPLICATION_CREDENTIALS: /etc/service-account.json
depends_on:
- db
- wordpress
volumes:
- uploads-data:/uploads
- backup-data:/snapshots
- wphb-cache:/wphb-cache
- ./main-website-content-writer-key.json:/etc/service-account.json
command: "/util-cmds/backup_entrypoint.sh"
indexer:
image: gcr.io/digital-ucdavis-edu/main-wp-website-es-indexer:v4.0.1
restart: always
env_file:
- .env
ports:
- ${INDEXER_HOST_PORT:-8001}:3000
environment:
GOOGLE_APPLICATION_CREDENTIALS: /etc/service-account.json
depends_on:
- elasticsearch
volumes:
- ./main-website-content-writer-key.json:/etc/service-account.json
db:
image: mysql:5.7
restart: always
env_file:
- .env
environment:
MYSQL_ROOT_PASSWORD: ${MYSQL_ROOT_PASSWORD}
MYSQL_DATABASE: ${DB_DATABASE}
MYSQL_USER: ${DB_USER}
MYSQL_PASSWORD: ${DB_PASSWORD}
volumes:
- db-data:/var/lib/mysql
ulimits:
nofile:
soft: 262114
hard: 262114
volumes:
db-data:
uploads-data:
wp-logs-data:
wphb-cache:
wphb-logs:
backup-data:
es-data: