-
Notifications
You must be signed in to change notification settings - Fork 5
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
116 lines (109 loc) · 2.67 KB
/
Copy pathdocker-compose.yml
File metadata and controls
116 lines (109 loc) · 2.67 KB
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
services:
web:
build: .
hostname: ursus
depends_on:
db:
condition: service_healthy
solr:
condition: service_healthy
dbsetup:
condition: service_completed_successfully
solrload:
condition: service_completed_successfully
env_file:
- ./default.env
- ./docker.env
stdin_open: true
tty: true
ports:
- '127.0.0.1:3003:3000'
volumes:
- .:/ursus
- ursus_public_uv:/ursus/public/uv
- ursus_tmp:/ursus/tmp
working_dir: /ursus
db:
image: uclalibrary/californica-mariadb:10.3
healthcheck:
test: ["CMD", "healthcheck.sh", "--connect", "--innodb_initialized"]
start_period: 3s
interval: 10s
timeout: 5s
retries: 3
volumes:
- ./docker-entrypoint-initdb.d:/docker-entrypoint-initdb.d
- mysql_data:/var/lib/mysql
ports:
- '127.0.0.1:3306:3306'
environment:
MYSQL_ALLOW_EMPTY_PASSWORD: 'yes'
solr:
image: uclalibrary/solr-ursus:8
ports:
- '127.0.0.1:8983:8983'
healthcheck:
test: ["CMD", "curl", "-f", "http://localhost:8983/solr/admin/info/system"]
interval: 30s
timeout: 10s
retries: 3
start_period: 2s
solr_test:
image: uclalibrary/solr-ursus:8
ports:
- '127.0.0.1:8985:8983'
healthcheck:
test: ["CMD", "curl", "-f", "http://localhost:8983/solr/admin/info/system"]
interval: 30s
timeout: 10s
retries: 3
start_period: 2s
dbsetup:
build: .
depends_on:
db:
condition: service_healthy
env_file:
- ./default.env
- ./docker.env
volumes:
- .:/ursus
- ursus_public_uv:/ursus/public/uv
- ursus_tmp:/ursus/tmp
working_dir: /ursus
command: ["/bin/sh", "-c", "bundle exec rails db:setup"]
solrload:
depends_on:
solr:
condition: service_healthy
image: ghcr.io/astral-sh/uv:python3.14-trixie
volumes:
- ./fixtures:/fixtures
- uv-cache:/root/.cache/uv
working_dir: /fixtures
command: ["/bin/sh", "-c", "uvx feed_ursus@latest --solr_url http://solr:8983/solr/ursus loaddump *.jsonl"]
rspec:
build: .
depends_on:
db:
condition: service_healthy
solr_test:
condition: service_healthy
dbsetup:
condition: service_completed_successfully
env_file:
- ./default.env
- ./docker.env
volumes:
- .:/ursus
- ursus_public_uv:/ursus/public/uv
- ursus_tmp:/ursus/tmp
working_dir: /ursus
command: ["/bin/sh", "-c", "bundle exec rspec spec"]
volumes:
mysql_data:
ursus_bundle_dir:
ursus_node_modules:
ursus_public_uv:
ursus_tmp:
uv-cache: