-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdocker-compose.yml
30 lines (30 loc) · 1.08 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
version: '3'
services:
vending_machine-postgres-server:
image: 'postgres:latest'
ports:
- '5432:5432'
environment:
POSTGRES_DB: vending_machine_db
POSTGRES_USER: vending_machine
POSTGRES_PASSWORD: 'vending_machine_pass'
vending_machine-api-server:
build: .
ports:
- '8080:8080'
volumes:
- '.:/go/src/github.com/dhurimkelmendi/vending_machine'
environment:
API_ORIGIN: 'http://localhost:8080'
ENV: development
DB_HOST: vending_machine-postgres-server
DB_PORT: 5432
DB_NAME: vending_machine_db
DB_USERNAME: vending_machine
DB_PASSWORD: 'vending_machine_pass'
# When set to any value other than 'true', the container will pack/build a binary and then run
# that binary. When set to 'true', the container will run from source directly.
RUN_FROM_SOURCE: 'false'
# When set to any value other than 'true', the container will NOT run database migration reset
# commands. When set to 'true', the container will reset and rerun database migrations.
RESET_DB: "${RESET_DB}"