This repository has been archived by the owner on Mar 31, 2020. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yml
80 lines (73 loc) · 2 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
###
### Default configuration
###
version: "3.3"
networks:
default:
services:
lighttpd:
image: ${DOCKER_IMAGE}
depends_on:
- simple_ca
environment:
- DOCKER_ENTRYPOINT_DEBUG=true
- DOCKER_ENTRYPOINT_INFO=true
- SERVER_CRT_HOST=${SERVER_CRT_HOST}
- SIMPLE_CA_URL=https://simple-ca.local
networks:
default:
aliases:
- lighttpd.local
volumes:
- /var/run/docker.sock:/var/run/docker.sock:ro
- simple_ca_secrets:/run/secrets:ro
simple_ca:
image: ${SIMPLE_CA_IMAGE}
environment:
- DOCKER_ENTRYPOINT_DEBUG=true
- DOCKER_ENTRYPOINT_INFO=true
- SERVER_CRT_HOST=simple-ca.local
networks:
default:
aliases:
- simple-ca.local
volumes:
- /var/run/docker.sock:/var/run/docker.sock:ro
- simple_ca_data:/var/lib/simple-ca
- simple_ca_secrets:/var/lib/simple-ca/secrets
test:
image: ${TEST_IMAGE}
command: ${TEST_CMD}
depends_on:
- lighttpd
env_file:
- ${TEST_ENV_FILE}
environment:
- DOCKER_ENTRYPOINT_DEBUG=true
- DOCKER_ENTRYPOINT_INFO=true
# Wait until the tested container is started
- WAIT_FOR_URL=http://lighttpd.local https://lighttpd.local
- WAIT_FOR_TIMEOUT=5
volumes:
- /var/run/docker.sock:/var/run/docker.sock:ro
- simple_ca_secrets:/run/secrets:ro
# Use project dir as host volume for debugging tests if Docker host is local
- ${TEST_PROJECT_DIR:-test_project_dir}:${PROJECT_DIR}
working_dir: ${TEST_DIR}
wait:
image: ${TEST_IMAGE}
depends_on:
- lighttpd
environment:
- DOCKER_ENTRYPOINT_DEBUG=true
- DOCKER_ENTRYPOINT_INFO=true
# Wait until the tested container is started
- WAIT_FOR_URL=http://lighttpd.local https://lighttpd.local
- WAIT_FOR_TIMEOUT=5
volumes:
- /var/run/docker.sock:/var/run/docker.sock:ro
- simple_ca_secrets:/run/secrets:ro
volumes:
test_project_dir:
simple_ca_data:
simple_ca_secrets: