-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yml
59 lines (50 loc) · 1.3 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
---
x-condition-healthy: &healthy
condition: service_healthy
x-healthcheck-defaults: &healthcheck-defaults
interval: 5s
timeout: 10s
start_period: 10s
retries: 5
services:
web: &web
build:
context: .
target: development
ports:
- "4567:4567"
volumes:
- .:/usr/src/app
- gem_cache:/gems
command: bundle exec ruby oai_solr.rb -o 0.0.0.0
environment:
SOLR_URL: http://solr-sdr-catalog:9033/solr/catalog
RIGHTS_DATABASE_CONNECTION_STRING: "mysql2://ht_rights:ht_rights@mariadb/ht"
depends_on:
solr-sdr-catalog: *healthy
mariadb: *healthy
test:
<<: *web
command: bundle exec rspec
profiles:
- test
solr-sdr-catalog:
image: ghcr.io/hathitrust/catalog-solr-sample
ports:
- "9033:9033"
healthcheck:
<<: *healthcheck-defaults
test: [ "CMD", "/usr/bin/curl", "-s", "-f", "http://localhost:9033/solr/catalog/admin/ping"]
mariadb:
image: ghcr.io/hathitrust/db-image
restart: always
environment:
MYSQL_RANDOM_ROOT_PASSWORD: 1
MYSQL_DATABASE: ht
MYSQL_USER: ht_rights
MYSQL_PASSWORD: ht_rights
healthcheck:
<<: *healthcheck-defaults
test: [ "CMD", "healthcheck.sh", "--su-mysql", "--connect", "--innodb_initialized" ]
volumes:
gem_cache: