forked from spree/spree
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yml
More file actions
80 lines (74 loc) · 1.87 KB
/
Copy pathdocker-compose.yml
File metadata and controls
80 lines (74 loc) · 1.87 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
# Local development services.
# Just works: pnpm dev (uses prebuilt Spree image)
# Rails devs: pnpm server:setup, then pnpm server:dev (runs natively)
x-app: &app
image: ghcr.io/spree/spree:latest
depends_on:
postgres:
condition: service_healthy
redis:
condition: service_healthy
meilisearch:
condition: service_healthy
environment: &app-env
DATABASE_URL: postgres://postgres@postgres:5432/spree_development
REDIS_URL: redis://redis:6379/0
SECRET_KEY_BASE: development_secret_key_base_not_for_production_use_only
RAILS_FORCE_SSL: "false"
RAILS_ASSUME_SSL: "false"
MEILISEARCH_URL: http://meilisearch:7700
# Admin/system emails use letter_opener in development (opens in browser).
# Customer transactional emails are handled by the storefront via webhooks.
services:
postgres:
image: postgres:18-alpine
environment:
POSTGRES_HOST_AUTH_METHOD: trust
volumes:
- postgres_data:/var/lib/postgresql
ports:
- "5432:5432"
healthcheck:
test: pg_isready -U postgres
interval: 5s
timeout: 5s
retries: 5
redis:
image: redis:7-alpine
volumes:
- redis_data:/data
ports:
- "6379:6379"
healthcheck:
test: redis-cli ping
interval: 5s
timeout: 5s
retries: 5
meilisearch:
image: getmeili/meilisearch:latest
volumes:
- meilisearch_data:/meili_data
ports:
- "7700:7700"
healthcheck:
test: curl -f http://localhost:7700/health || exit 1
interval: 5s
timeout: 5s
retries: 5
web:
<<: *app
ports:
- "3000:3000"
healthcheck:
test: curl -f http://localhost:3000/up || exit 1
interval: 10s
timeout: 5s
retries: 10
start_period: 30s
worker:
<<: *app
command: bundle exec sidekiq
volumes:
postgres_data:
redis_data:
meilisearch_data: