common.yml 8.31 KB
Newer Older
1
---
2
version: '3'
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22

networks:
  backend:
    driver: bridge

volumes:
  koha_index: {}
  koha_state: {}
  koha_mysql_data: {}
  elasticsearch_data: {}
  fuseki_data: {}

services:
  koha:
    container_name: xkoha
    image: "digibib/koha:${KOHA_IMAGE_TAG}"
    networks:
      - backend
    depends_on:
      - sms
23
      - smtp
24
      - koha_mysql
25
26
27
28
29
30
      - sip_proxy
    cap_add:
      - SYS_NICE
      - DAC_READ_SEARCH
      - MKNOD
    environment:
31
      KOHA_HOME: "${KOHA_HOME:-/usr/share/koha/}"
32
33
34
35
      KOHA_ADMINPASS: "${KOHA_ADMINPASS:-secret}"
      KOHA_ADMINUSER: "${KOHA_ADMINUSER:-admin}"
      KOHA_INSTANCE: "${KOHA_INSTANCE:-name}"
      KOHA_DBHOST: koha_mysql
36
37
      INSTALL_LANGUAGES: "${INSTALL_LANGUAGES}"
      DEFAULT_LANGUAGE: "${DEFAULT_LANGUAGE}"
38
      EMAIL_ENABLED: "True"
39
      ENABLE_MYSQL_TRIGGERS: "${ENABLE_MYSQL_TRIGGERS:-true}"
40
      ENABLE_MYSQL_SCHEMA: "${ENABLE_MYSQL_SCHEMA:-true}"
41
42
43
44
45
46
47
48
      SMTP_SERVER_HOST: mailrelay # access through network 'backend'
      SMTP_SERVER_PORT: 2525
      MESSAGE_QUEUE_FREQUENCY: "${MESSAGE_QUEUE_FREQUENCY:-5}"
      SMS_SENDER: "${SMS_SENDER:-Deichman}"
      SMS_DRIVER: "${SMS_DRIVER:-NO::LinkMobilityHTTP}"
      SMS_USER: "${SMS_USER:-smsuser}"
      SMS_PASS: "${SMS_PASS:-smspass}"
      API_PASSPHRASE: "${API_PASSPHRASE:-ChangeMe}"
49
      NLENABLE: "${NLENABLE:-0}"
50
51
      NLBASEUSER: "${NLBASEUSER:-nlbaseuser}"
      NLBASEPASS: "${NLBASEPASS:-nlbasepass}"
52
      NLVENDORURL: "${NLVENDORURL:-http://nlsink:9999}"
53
54
55
56
57
58
59
60
61
62
63
64
      NLVENDORUSER: "${NLVENDORUSER:-nlvendoruser}"
      NLVENDORPASS: "${NLVENDORPASS:-nlvendorpass}"
      NLVENDORKEY: "${NLVENDORKEY:-nlvendorkey}"
      PIDGEON_URL: "${PIDGEON_URL:-pidgeonurl}"
      PIDGEON_USER: "${PIDGEON_USER:-pidgeonuser}"
      PIDGEON_PASS: "${PIDGEON_PASS:-pidgeonpass}"
      SIP_AUTOPASS: "${SIP_AUTOPASS:-autopass}"
      SIP_WORKERS: "${SIP_WORKERS:-5}"
      APACHE_MINSERVERS: "${APACHE_MINSERVERS:-5}"
      APACHE_TIMEOUT: "${APACHE_TIMEOUT:-300}"
      APACHE_SERVER_STATUS_NET: "${APACHE_SERVER_STATUS_NET:-127.0.0.1/24}"
      APACHE_REMOTE_INTERNAL_PROXY: "${APACHE_REMOTE_INTERNAL_PROXY:-172.19.0.0/16}"
65
66
      PLACK_MAX_REQUESTS: "${PLACK_MAX_REQUESTS:-100}"
      PLACK_WORKERS: "${PLACK_WORKERS:-4}"
67
68
69
      ILLENABLE: "${ILLENABLE:-0}"
      ILLUSER: "${ILLUSER:-illuser}"
      ILLNAME: "${ILLNAME:-Interlibrary loan}"
70
71
72
    ports:
      - "6001:6001"
      - "8081:8081"
73
      - "6009:3000"
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
    volumes:
      - "koha_index:/var/lib/koha/${KOHA_INSTANCE:-name}"
      - "koha_state:/var/lib/state"
    logging:
      driver: "json-file"
      options:
        max-size: "1m"
        max-file: "2"

  koha_mysql:
    container_name: koha_mysql
    image: mysql:5.6.20
    networks:
      - backend
    cap_add:
      - MKNOD
    command:
      - mysqld
      - "--datadir=/var/lib/mysql"
      - "--user=mysql"
      - "--max_allowed_packet=64M"
      - "--wait_timeout=6000"
      - "--bind-address=0.0.0.0"
97
98
99
100
101
102
      - "--server-id=101"
      - "--log_bin=mysql-bin"
      - "--sync_binlog=1"
      - "--binlog-format=row"
      - "--max_binlog_size=100M"
      - "--log_bin_trust_function_creators=true"
Petter Goksøyr Åsen's avatar
Petter Goksøyr Åsen committed
103
104
105
      - "--slow-query-log=1"
      - "--slow-query-log-file=/var/lib/mysql/slow-query.log"
      - "--long-query-time=10"
106
107
108
109
110
    environment:
      MYSQL_DATABASE: "koha_${KOHA_INSTANCE:-name}"
      MYSQL_PASSWORD: "${KOHA_ADMINPASS:-secret}"
      MYSQL_ROOT_PASSWORD: "${KOHA_ADMINPASS:-secret}"
      MYSQL_USER: "${KOHA_ADMINUSER:-admin}"
Petter Goksøyr Åsen's avatar
Petter Goksøyr Åsen committed
111
112
      SIBYL_USER: "${SIBYL_USER:-admin}"
      SIBYL_PASSWORD: "${SIBYL_PASSWORD:-admin}"
113
114
    volumes:
      - "koha_mysql_data:/var/lib/mysql"
Petter Goksøyr Åsen's avatar
Petter Goksøyr Åsen committed
115
      - ./setup_sibyl.sql:/docker-entrypoint-initdb.d/setup_sibyl.sql
116
117
118
119
120
121
    logging:
      driver: "json-file"
      options:
        max-size: "1m"
        max-file: "2"

Petter Goksøyr Åsen's avatar
Petter Goksøyr Åsen committed
122
  sibyl:
Petter Goksøyr Åsen's avatar
Petter Goksøyr Åsen committed
123
    container_name: sibyl
Petter Goksøyr Åsen's avatar
Petter Goksøyr Åsen committed
124
125
    depends_on:
      - koha_mysql
Petter Goksøyr Åsen's avatar
Petter Goksøyr Åsen committed
126
127
128
129
130
131
132
133
134
    image: digibib/sibyl:test
    networks:
      - backend
    environment:
      SIBYL_USER: "${SIBYL_USER:-admin}"
      SIBYL_PASSWORD: "${SIBYL_PASSWORD:-secret}"
      KOHA_ADMINPASS: "${KOHA_ADMINPASS:-secret}"
      KOHA_ADMINUSER: "${KOHA_ADMINUSER:-admin}"
      KOHA_INSTANCE: "${KOHA_INSTANCE:-name}"
Petter Goksøyr Åsen's avatar
Petter Goksøyr Åsen committed
135

136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
  catalinker:
    container_name: catalinker
    image: "digibib/redef-catalinker:${GITREF}"
    networks:
      - backend
    depends_on:
      - services
    ports:
      - "8010:8010"
    environment:
      KOHA_OPAC_PORT: "http://xkoha:8080"
      KOHA_INTRA_PORT: "http://xkoha:8081"
      SERVICES_PORT: "http://services:8005"
      GITREF: "${GITREF:-0}"
      BUILD_TAG: "${BUILD_TAG:-0}"
    logging:
      driver: "json-file"
      options:
        max-size: "1m"
        max-file: "2"

  services:
    container_name: services
    image: "digibib/redef-services:${GITREF}"
    networks:
      - backend
    depends_on:
      - fuseki
      - koha
    environment:
      KOHA_API_USER: "${KOHA_API_USER:-api}"
      KOHA_API_PASS: "${KOHA_API_PASS:-secret}"
      GITREF: "${GITREF:-0}"
      BUILD_TAG: "${BUILD_TAG:-0}"
Petter Goksøyr Åsen's avatar
Petter Goksøyr Åsen committed
170
      ELASTICSEARCH_URL: "sibyl:1666"
171
172
173
174
175
176
177
178
179
180
181
182
183
    logging:
      driver: "json-file"
      options:
        max-size: "1m"
        max-file: "2"

  patron_client:
    container_name: patron_client
    image: "digibib/redef-patron-client:${GITREF}"
    networks:
      - backend
    depends_on:
      - services
184
185
    ports:
      - "8000:8000"
186
187
188
189
190
191
    environment:
      SERVICES_PORT: "http://services:${SERVICES_PORT:-8005}"
      GITREF: "${GITREF:-0}"
      BUILD_TAG: "${BUILD_TAG:-0}"
      KOHA_API_USER: "${KOHA_API_USER:-api}"
      KOHA_API_PASS: "${KOHA_API_PASS:-secret}"
192
      RECAPTCHA_SECRET: "${RECAPTCHA_SECRET}"
193
194
      NETS_MERCHANT_ID: "${NETS_MERCHANT_ID}"
      NETS_TOKEN: "${NETS_TOKEN}"
195
      NETS_URL: "${NETS_URL}"
196
197
198
199
200
201
202
203
    logging:
      driver: "json-file"
      options:
        max-size: "1m"
        max-file: "2"

  elasticsearch:
    container_name: elasticsearch
204
    image: digibib/elasticsearch:9be13a2a600e3112430c2a54a4493373e73a94b3
205
206
207
208
    networks:
      - backend
    volumes:
      - "elasticsearch_data:/usr/share/elasticsearch/data"
209
210
211
212
    ulimits:
      nofile:
        soft: 65536
        hard: 65536
213
214
215
216
217
218
219
220
    logging:
      driver: "json-file"
      options:
        max-size: "1m"
        max-file: "2"

  fuseki:
    container_name: fuseki
221
    image: "digibib/fuseki2:ae95941f9bb3799b253f40e5be278866c4113fa7"
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
    networks:
      - backend
    volumes:
      - "fuseki_data:/data/databases/ds"
    logging:
      driver: "json-file"
      options:
        max-size: "1m"
        max-file: "2"

  sms:
    container_name: smsproxy
    image: "digibib/proximity:3ce6b65df303302420d2fb85bd6b625744bfb907"
    networks:
      - backend
    environment:
      FORWARD_SMS: http://tcpsink:9999
    command:
      - "/proximity"
      - "-no-verify"
      - "-r"
      - '${FORWARD_SMS}'
    logging:
      driver: "json-file"
      options:
        max-size: "1m"
        max-file: "2"

250
  smtp:
251
252
253
254
255
256
257
258
259
260
261
262
    container_name: mailrelay
    image: "digibib/gosmtpd:e51ec0b872867560461ab1e8c12b10fd63f5d3c1"
    networks:
      - backend
    logging:
      driver: "json-file"
      options:
        max-size: "1m"
        max-file: "2"

  sip_proxy:
    container_name: sip_proxy
263
    image: "digibib/sip2proxy:3891478ccc5dc17abd16004b6780885774cd6d44"
264
265
266
267
268
269
270
271
272
    networks:
      - backend
    ports:
      - "6002:9999"
    command:
      - "/sip2proxy"
      - "-from=:9999"
      - "-to=xkoha:${SIP_PORT:-6001}"
      - "-log-messages=true"
273
      - "-log-pre-transform=true"
274
275
276
      #- "-patron-session=true"
      - "-ensure-branch=true"
      - "-strip-barcode=true"
277
278
      #- "-extend-barcode=true"
      #- "-no-alert-if-same-branch=true"
279
280
281
282
283
284
    logging:
      driver: "json-file"
      options:
        max-size: "1m"
        max-file: "2"

Petter Goksøyr Åsen's avatar
Petter Goksøyr Åsen committed
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
  # koha_indexer:
  #   container_name: koha_indexer
  #   image: "digibib/koha-indexer:8fe76d382ea8333a7392a7c6f22ae181da28fd99"
  #   networks:
  #     - backend
  #   command:
  #     - "/koha-indexer"
  #     - "-db=/var/lib/state/koharecords.db"
  #     - "-sparql=http://fuseki:3030/ds/update"
  #     - "-freq=15m"
  #     - "-update"
  #     - "-initial-import"
  #     - "-services=http://services:8005/search/publication/reindex"
  #   environment:
  #     KOHA_ADMINPASS: "${KOHA_ADMINPASS:-secret}"
  #     KOHA_ADMINUSER: "${KOHA_ADMINUSER:-admin}"
  #     KOHA_INSTANCE: "${KOHA_INSTANCE:-name}"
  #   volumes:
  #     - "koha_state:/var/lib/state"
  #   logging:
  #     driver: "json-file"
  #     options:
  #       max-size: "1m"
  #       max-file: "2"