-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yml
42 lines (39 loc) · 1004 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
31
32
33
34
35
36
37
38
39
40
41
42
version: '3.1'
services:
database:
image: mongo
container_name: mongodb-container
ports:
- "27017:27017"
environment:
- MONGO_INITDB_DATABASE=${MONGO_INITDB_DATABASE}
- MONGO_INITDB_ROOT_USERNAME=${MONGO_INITDB_ROOT_USERNAME}
- MONGO_INITDB_ROOT_PASSWORD=${MONGO_INITDB_ROOT_PASSWORD}
volumes:
- "./.mongo-data:/data/db"
scraping:
build: .
command: ["go", "run", "cmd/scraping/main.go"]
container_name: scraping-container
environment:
- MAPS_API_KEY=${MAPS_API_KEY}
- MONGODB_URI=${MONGODB_DOCKER_URI}
- DOCKER=TRUE
depends_on:
- database
links:
- database:database
website:
build: .
command: [ "go", "run", "cmd/web/main.go" ]
container_name: website-container
environment:
- MONGODB_URI=${MONGODB_DOCKER_URI}
- MAPS_API_KEY=${MAPS_API_KEY}
- DOCKER=TRUE
depends_on:
- database
links:
- database:database
ports:
- "8080:8080"