-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathdocker-compose.yaml
82 lines (76 loc) · 1.97 KB
/
docker-compose.yaml
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
81
82
version: '3.5'
networks:
developer-network:
driver: bridge
volumes:
mongo_data:
services:
mongo-dev:
image: mongo:latest
container_name: mongo-dev
hostname: mongo-dev
environment:
MONGO_INITDB_ROOT_USERNAME: "${MY_MONGO_INITDB_ROOT_USERNAME}"
MONGO_INITDB_ROOT_PASSWORD: "${MY_MONGO_INITDB_ROOT_PASSWORD}"
ports:
- "${MY_MONGO_PORT}:27017"
volumes:
- mongo_data:/data/db
healthcheck:
test: echo 'db.runCommand("ping").ok' | mongo mongo-dev:27017/test --quiet
interval: 30s
timeout: 2s
retries: 5
start_period: 5s
networks:
- developer-network
totem-food-service:
container_name: totem-food-service
hostname: totem-food-service
build:
context: .
dockerfile: Dockerfile
environment:
SPRING_DATA_MONGODB_HOST: mongo-dev
SPRING_DATA_MONGODB_PORT: 27017
SPRING_DATA_MONGODB_DATABASE: totem-food
SPRING_DATA_MONGODB_USERNAME: root
SPRING_DATA_MONGODB_PASSWORD: qwe123
SPRING_DATA_MONGODB_AUTHENTICATION_DATABASE: admin
PAYMENT_GATEWAY_URL: http://payment-gateway:5000/v1/online-payment
SMTP_HOST: mailhog
SMTP_PORT: 1025
SMTP_USERNAME: username
SMTP_PASSWORD: password
SMTP_AUTH_ENABLED: "false"
SMTP_TLS_ENABLED: "false"
SMTP_EMAIL: contato@totem.food.service.com.br
ports:
- "8080:8080"
- "8787:8787" # DEBUG
depends_on:
- mongo-dev
networks:
- developer-network
payment-gateway:
container_name: payment-gateway
hostname: payment-gateway
build:
context: ./mock-payment-gateway
dockerfile: Dockerfile
ports:
- "5000:5000"
volumes:
- ./mock-payment-gateway/mocks:/app/mocks
networks:
- developer-network
mailhog:
container_name: mailhog
hostname: mailhog
image: mailhog/mailhog:latest
restart: always
ports:
- 1025:1025
- 8025:8025
networks:
- developer-network