-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathdocker-compose.yaml
More file actions
97 lines (97 loc) · 2.79 KB
/
docker-compose.yaml
File metadata and controls
97 lines (97 loc) · 2.79 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
services:
opensearch:
image: opensearchproject/opensearch:3.5.0@sha256:919ff4e7d0d57dbc4bd0999ddf0e43e961bba844ec2a5b6734fc979eb4e32399
environment:
- cluster.name=opensearch-cluster
- node.name=opensearch
- discovery.type=single-node
- DISABLE_SECURITY_PLUGIN=true
- bootstrap.memory_lock=true # along with the memlock settings below, disables swapping
ulimits:
memlock:
soft: -1
hard: -1
nofile:
soft: 65536 # maximum number of open files for the OpenSearch user, set to at least 65536 on modern systems
hard: 65536
volumes:
- opensearch-data1:/usr/share/opensearch/data
ports:
- '9200:9200'
- '9600:9600' # required for Performance Analyzer
healthcheck:
test: ["CMD-SHELL", "curl --silent --fail localhost:9200/_cluster/health || exit 1"]
interval: 2s
timeout: 2s
retries: 50
api-dummy:
image: ghcr.io/elifesciences/api-dummy:20251121085356.0.0-g8586240-19565166180-1@sha256:6fcfdf74e493527eb23d348ebb6eba8b2d21f885046378557c58dd98ce7a1b44
platform: linux/amd64
ports:
- '5002:8080'
healthcheck:
test: ["CMD-SHELL", "curl --silent --fail localhost:8080/articles || exit 1"]
interval: 2s
timeout: 2s
retries: 10
stop_grace_period: 1s
localstack:
image: localstack/localstack:4.14.0@sha256:3ebc37595918b8accb852f8048fef2aff047d465167edd655528065b07bc364a
environment:
- SERVICES=sqs
- AWS_DEFAULT_REGION=eu-central-1
- HOSTNAME=localstack
- HOSTNAME_EXTERNAL=localstack
ports:
- "127.0.0.1:4566:4566" # LocalStack Gateway
- "127.0.0.1:4510-4559:4510-4559" # external services port range
setup:
build:
context: .
dockerfile: Dockerfile
command:
- /bin/bash
- "-c"
- |
composer install
php bin/console queue:create;
php bin/console search:setup;
php bin/console keyvalue:setup
volumes:
- ./config.php:/app/config.php
depends_on:
opensearch:
condition: service_healthy
localstack:
condition: service_healthy
app:
build:
context: .
dockerfile: Dockerfile
volumes:
- ./config.php:/app/config.php
ports:
- '8888:80'
depends_on:
setup:
condition: service_completed_successfully
api-dummy:
condition: service_healthy
stdin_open: true
tty: true
extra_hosts:
host.docker.internal: host-gateway
stop_grace_period: 1s
queue-watcher:
build:
context: .
dockerfile: Dockerfile
command: bin/console queue:watch
volumes:
- ./config.php:/app/config.php
depends_on:
setup:
condition: service_completed_successfully
stop_grace_period: 1s
volumes:
opensearch-data1: