-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.test.yml
56 lines (53 loc) · 1.42 KB
/
docker-compose.test.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
services:
mysql-test:
image: mariadb
environment:
MARIADB_USER: ${DB_USERNAME}
MARIADB_PASSWORD: ${DB_PASSWORD}
MARIADB_DATABASE: ${DB_TEST_DATABASE}
MARIADB_HOST: ${DB_HOST}
MARIADB_PORT: ${DB_PORT}
MYSQL_TCP_PORT: ${DB_PORT}
MARIADB_ROOT_PASSWORD: ${DB_PASSWORD}
volumes:
- test-db-data:/var/lib/mysql
healthcheck:
test: ["CMD", "healthcheck.sh", "--connect", "--innodb_initialized"]
interval: 2s
timeout: 20s
retries: 10
# Uncomment to expose the port to the host machine
#ports:
#- ${DB_PORT}:${DB_PORT}
api-test:
build:
dockerfile: Dockerfile
context: .
target: development
depends_on:
mysql-test:
condition: service_healthy
tty: true
environment:
- API_PORT=${API_PORT}
- DB_HOST=${DB_HOST}
- DB_PORT=${DB_PORT}
- DB_USERNAME=${DB_USERNAME}
- DB_PASSWORD=${DB_PASSWORD}
- DB_DATABASE=${DB_DATABASE}
- DB_TEST_DATABASE=${DB_TEST_DATABASE}
- DB_SYNCHRONIZE=${DB_SYNCHRONIZE}
- STEAM_API_KEY=${STEAM_API_KEY}
- AGDB_MASTER_KEY=${AGDB_MASTER_KEY}
- APITALLY_CLIENT_ID=${APITALLY_CLIENT_ID}
- APITALLY_ENVIRONMENT=${APITALLY_ENVIRONMENT}
volumes:
- /usr/src/app/node_modules
- .:/usr/src/app
ports:
- ${API_PORT}:${API_PORT}
volumes:
test-db-data:
networks:
default:
name: agdb-test-network