-
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose.yml
30 lines (30 loc) · 1002 Bytes
/
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
version: '3'
services:
db:
image: postgres:9
environment:
- POSTGRES_USER=deploy
- POSTGRES_PASSWORD=weaver7
# These lines are for our application.
web:
# The build line causes an image to be created based on the Dockerfile and directory contents.
build: .
# Import environment variable settings from the .env file in the directory compose is being run on.
env_file: .env
environment:
- DB_SERVICE_HOST=db_1
- SERVER_PRODUCTION=www.802-1.org
- HOST_PORT=:80
# The command to run when the image is started. Can use bash -c "string; of; commands"
# command: bundle exec rails s Puma -p 3100 -b '0.0.0.0'
command: ./init.sh
volumes:
# When the image runs, map its /myapp file to the directory before the colon, in this case the current directory
- .:/myapp
# Expose the image's port 3000 as the port 3000 on the host. Format: "HOST:CONTAINER"
ports:
- "3000:3000"
links:
- db
depends_on:
- db