forked from sbomify/sbomify
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.tests.yml
More file actions
68 lines (64 loc) · 1.82 KB
/
docker-compose.tests.yml
File metadata and controls
68 lines (64 loc) · 1.82 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
---
services:
db:
image: postgres:17-alpine
environment:
POSTGRES_USER: sbomify_test
POSTGRES_PASSWORD: sbomify_test
POSTGRES_DB: sbomify_test
volumes:
- sbomify_test_postgres_data:/var/lib/postgresql/data
healthcheck:
test: ["CMD-SHELL", "pg_isready -U sbomify_test"]
interval: 2s
timeout: 2s
retries: 10
networks:
testnet:
ipv4_address: 172.25.0.10
chromium:
image: zenika/alpine-chrome:124
command: ["chromium-browser", "--headless", "--disable-gpu", "--no-sandbox", "--remote-debugging-address=0.0.0.0", "--remote-debugging-port=9222"]
shm_size: '2g'
healthcheck:
test: ["CMD-SHELL", "curl -f http://localhost:9222/json/version || exit 1"]
interval: 2s
retries: 10
timeout: 2s
networks:
testnet:
ipv4_address: 172.25.0.11
tests:
build:
context: .
target: python-dependencies
args:
BUILD_ENV: tests
command: ["tail", "-f", "/dev/null"]
environment:
TEST_DATABASE_HOST: 172.25.0.10
TEST_DATABASE_PORT: 5432
TEST_DATABASE_USER: sbomify_test
TEST_DATABASE_PASSWORD: sbomify_test
TEST_DATABASE_NAME: sbomify_test
PLAYWRIGHT_DJANGO_HOST: 172.25.0.12
PLAYWRIGHT_CDP_ENDPOINT: http://172.25.0.11:9222
DJANGO_SETTINGS_MODULE: sbomify.test_settings
volumes:
- ./sbomify:/code/sbomify:ro
- ./sbomify/apps/core/tests/e2e/__diffs__:/code/sbomify/apps/core/tests/e2e/__diffs__
- ./sbomify/apps/core/tests/e2e/__snapshots__:/code/sbomify/apps/core/tests/e2e/__snapshots__
depends_on:
- chromium
- db
networks:
testnet:
ipv4_address: 172.25.0.12
volumes:
sbomify_test_postgres_data:
networks:
testnet:
driver: bridge
ipam:
config:
- subnet: 172.25.0.0/16