-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose.yml
55 lines (50 loc) · 1.07 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
version: '3.8'
services:
postgres:
build:
context: .
dockerfile: docker/postgres/Dockerfile
volumes:
- pgdata:/var/lib/postgresql/data
restart: unless-stopped
environment:
- POSTGRES_PASSWORD=postgres
networks:
databasetestcase:
mysql:
build:
context: .
dockerfile: docker/mysql/Dockerfile
volumes:
- mysqldata:/var/lib/mysql
restart: unless-stopped
environment:
- MYSQL_DATABASE=mysql
- MYSQL_USER=mysql
- MYSQL_PASSWORD=mysql
- MYSQL_ROOT_PASSWORD=mysql
networks:
databasetestcase:
tests:
build:
context: .
dockerfile: docker/php/Dockerfile
target: app
depends_on:
postgres:
condition: service_healthy
mysql:
condition: service_healthy
volumes:
- ./src:/app/src
- ./tests:/app/tests
- ./resources:/app/resources
- ./phpunit.xml:/app/phpunit.xml
- ./composer.json:/app/composer.json
networks:
databasetestcase:
networks:
databasetestcase:
volumes:
mysqldata:
pgdata: