-
Notifications
You must be signed in to change notification settings - Fork 16
/
docker-compose.yml
96 lines (88 loc) · 2.64 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
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
# Default development deployment
version: "3.9"
volumes:
repository-service-tuf-storage:
repository-service-tuf-api-data:
repository-service-tuf-mq-data:
repository-service-tuf-settings:
repository-service-tuf-redis-data:
repository-service-tuf-pgsql-data:
services:
rabbitmq:
image: rabbitmq:3.10.7-management-alpine
volumes:
- "repository-service-tuf-mq-data:/var/lib/rabbitmq"
ports:
- 5672:5672
- 15672:15672
healthcheck:
test: "exit 0"
restart: always
postgres:
image: postgres:15.1
ports:
# 5432 may already in use by another PostgreSQL on host
- "5433:5432"
environment:
- POSTGRES_PASSWORD=secret
volumes:
- "repository-service-tuf-pgsql-data:/var/lib/postgresql/data"
healthcheck:
test: ["CMD", "pg_isready", "-U", "postgres", "-d", "postgres"]
interval: 1s
repository-service-tuf-api:
image: ghcr.io/repository-service-tuf/repository-service-tuf-api:${API_VERSION}
volumes:
- repository-service-tuf-api-data:/data
ports:
- 80:80
environment:
- RSTUF_BROKER_SERVER="amqp://guest:guest@rabbitmq:5672"
- RSTUF_REDIS_SERVER="redis://redis"
depends_on:
rabbitmq:
condition: service_healthy
web:
image: python:3.12
command: python -m http.server -d /var/opt/repository-service-tuf/storage 8080
volumes:
- repository-service-tuf-storage:/var/opt/repository-service-tuf/storage
ports:
- "8080:8080"
redis:
image: redis:4.0
volumes:
- repository-service-tuf-redis-data:/data
ports:
- "6379:6379"
repository-service-tuf-worker:
build:
context: .
entrypoint: "bash entrypoint-dev.sh"
environment:
- DATA_DIR=./data
- RSTUF_STORAGE_BACKEND=LocalStorage
- RSTUF_LOCAL_STORAGE_BACKEND_PATH=/var/opt/repository-service-tuf/storage
- RSTUF_ONLINE_KEY_DIR=/var/opt/repository-service-tuf/key_storage
- RSTUF_BROKER_SERVER=amqp://guest:guest@rabbitmq:5672
- RSTUF_DB_SERVER=postgresql://postgres:5432
- RSTUF_DB_USER=postgres
- RSTUF_DB_PASSWORD=secret
- RSTUF_REDIS_SERVER=redis://redis
volumes:
- ./:/opt/repository-service-tuf-worker:z
- repository-service-tuf-storage:/var/opt/repository-service-tuf/storage
- ./tests/files/key_storage/:/var/opt/repository-service-tuf/key_storage
depends_on:
rabbitmq:
condition: service_healthy
postgres:
condition: service_healthy
tty: true
stdin_open: true
rstuf-ft-runner:
image: python:3.12-slim
command: python -V
working_dir: /rstuf-runner
volumes:
- ./:/rstuf-runner