-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathdocker-compose.tests.yml
44 lines (40 loc) · 1.07 KB
/
docker-compose.tests.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
# Defines the services
services:
php-test:
image: bandsintown/php:${VERSION}-test
build:
context: .
dockerfile: ./versions/${VERSION}/test/Dockerfile
container_name: php-test
environment:
- SERVICE_NAME=php-fpm
- CONSUL_HTTP_ADDR=consul:8500
ports:
- 9000:9000
# Test image (packages, services, scripts)
test-image:
image: bandsintown/php:${VERSION}-test
command: bats /tests/image
environment:
- VERSION=${VERSION}
# Tests for consul template
test-consul-template:
image: bandsintown/php:${VERSION}-test
command: dockerize -wait http://consul:8500 -timeout 10s bats /tests/consul-template
depends_on:
- consul
environment:
- DISABLE_CONSUL_TEMPLATE=true
- CONSUL_HTTP_ADDR=consul:8500
- VERSION=${VERSION}
# Consul
consul:
image: consul:0.7.5
command: "agent -dev -client 0.0.0.0 -ui"
ports:
- 8500
environment:
- CONSUL_BIND_INTERFACE=eth0
# We disable the log in order to increase lisibility in CI
logging:
driver: "none"