-
-
Notifications
You must be signed in to change notification settings - Fork 113
/
Copy pathdocker-compose.yml
41 lines (37 loc) · 1.09 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
# Also see:
# Dockerfile
#
# https://docs.docker.com/compose/compose-file
services:
web:
build:
context: .
dockerfile: dev/web/Dockerfile
command: /bin/bash -c "
echo 'Starting static webserver at http://127.0.0.1:8080/'
&& /usr/local/bin/httpd-foreground
"
container_name: cc-search-web
ports:
- '8080:80'
restart: on-failure
volumes:
# Mount site configuration directory
- './config:/usr/local/apache2/conf/config:ro'
# Mount website directory
- './src:/usr/local/apache2/htdocs:ro'
# Example commands using this service:
# docker compose exec node prettier --write src/
node:
build:
context: .
dockerfile: dev/node/Dockerfile
# continue running until shutdown (this allows docker compose exec which is
# much faster than docker compose run)
# Thank you: https://serverfault.com/a/1084975
command: sh -c 'trap "exit" TERM; while true; do sleep 1; done'
container_name: cc-search-node
volumes:
# Mount repository to working directory
- './:/opt'
working_dir: /opt