-
Notifications
You must be signed in to change notification settings - Fork 18
/
docker-compose.yml
140 lines (132 loc) · 3.04 KB
/
docker-compose.yml
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
version: '3.8'
services:
proxy:
container_name: proxy
build:
context: .
dockerfile: ${DOCKERFILE}
target: proxy
image: ${ACCOUNT_NAME}/${PREFIX_NAME}-proxy${PRODUCT_EDITION}:${DOCKER_TAG}
environment:
- DOCSERVICE_HOST_PORT=docservice:8000
- EXAMPLE_HOST_PORT=example:3000
stdin_open: true
restart: always
ports:
- '80:8888'
volumes:
- common_data:/var/lib/${COMPANY_NAME}
docservice:
build:
context: .
dockerfile: ${DOCKERFILE}
target: docservice
image: ${ACCOUNT_NAME}/${PREFIX_NAME}-docservice${PRODUCT_EDITION}:${DOCKER_TAG}
deploy:
replicas: 1
environment:
- DB_HOST=postgresql
- DB_NAME=mydb
- DB_USER=myuser
- REDIST_SERVER_HOST=redis
- AMQP_HOST=rabbitmq
#- METRICS_HOST=metrics
#- METRICS_ENABLED=true
- WOPI_ENABLED=false
- JWT_ENABLED=${JWT_ENABLED}
- JWT_HEADER=${JWT_HEADER}
- JWT_SECRET=${JWT_SECRET}
depends_on:
- proxy
- postgresql
- redis
- rabbitmq
#- metrics
stdin_open: true
restart: always
expose:
- '8000'
volumes:
- common_data:/var/lib/${COMPANY_NAME}
converter:
build:
context: .
dockerfile: ${DOCKERFILE}
target: converter
image: ${ACCOUNT_NAME}/${PREFIX_NAME}-converter${PRODUCT_EDITION}:${DOCKER_TAG}
deploy:
replicas: 2
environment:
- DB_HOST=postgresql
- DB_NAME=mydb
- DB_USER=myuser
- REDIST_SERVER_HOST=redis
- AMQP_HOST=rabbitmq
#- METRICS_HOST=metrics
#- METRICS_ENABLED=true
- JWT_ENABLED=${JWT_ENABLED}
- JWT_HEADER=${JWT_HEADER}
- JWT_SECRET=${JWT_SECRET}
depends_on:
- proxy
- postgresql
- redis
- rabbitmq
#- metrics
stdin_open: true
restart: always
volumes:
- common_data:/var/lib/${COMPANY_NAME}
#metrics:
# build:
# context: .
# dockerfile: ${DOCKERFILE}
# target: metrics
# container_name: metrics
# expose:
# - '8125'
# - '8126'
example:
image: ${COMPANY_NAME}/${PREFIX_NAME}-example:${DOCKER_TAG}
container_name: example
environment:
- JWT_ENABLED=${JWT_ENABLED}
- JWT_HEADER=${JWT_HEADER}
- JWT_SECRET=${JWT_SECRET}
# Uncomment the line below and enter your ONLYOFFICE Docs address
# - DS_URL=http://onlyoffice-docs-address/
depends_on:
- proxy
stdin_open: true
restart: always
expose:
- '3000'
redis:
container_name: redis
image: redis
restart: always
expose:
- '6379'
rabbitmq:
container_name: rabbitmq
image: rabbitmq
restart: always
expose:
- '5672'
postgresql:
container_name: postgresql
build:
context: .
target: db
environment:
- POSTGRES_DB=mydb
- POSTGRES_USER=myuser
- POSTGRES_HOST_AUTH_METHOD=trust
restart: always
expose:
- '5432'
volumes:
- postgresql_data:/var/lib/postgresql
volumes:
common_data:
postgresql_data: