-
Notifications
You must be signed in to change notification settings - Fork 0
/
docker-compose.yml
87 lines (79 loc) · 1.81 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
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
83
84
85
86
87
version: "3"
services:
# Executes the bot only, without extra services
bot:
build:
context: .
args:
- ETHERSCAN_API_KEY=${ETHERSCAN_API_KEY}
env_file: .env
container_name: zodiac-bot
restart: unless-stopped
# Starts services (DB, HardHat) and the bot
bot-dev:
build:
context: .
args:
- ETHERSCAN_API_KEY=${ETHERSCAN_API_KEY}
env_file: .env
container_name: zodiac-bot-dev
restart: unless-stopped
depends_on:
- db
- hardhat
- smtp
networks:
- zodiac-bots-network
# Starts services and runs the test suite
tests:
build:
context: .
args:
- ETHERSCAN_API_KEY=${ETHERSCAN_API_KEY}
command: "yarn test"
env_file: .env
environment:
- MAINNET_RPC_URL=http://hardhat:8545
container_name: zodiac-tests
depends_on:
- hardhat
- db
- smtp
networks:
- zodiac-bots-network
# Hardhat Instance, controllable via RPC
hardhat:
build:
context: .
dockerfile: ./Dockerfile.hardhat-container
args:
- ETHERSCAN_API_KEY=${ETHERSCAN_API_KEY}
env_file: .env
container_name: zodiac-hardhat-fork
restart: unless-stopped
networks:
- zodiac-bots-network
# PostgreSQL instance for persistance
db:
image: postgres:15-alpine
environment:
- POSTGRES_PASSWORD=zodiac-bots
- POSTGRES_USER=zodiac-bots
- POSTGRES_DB=zodiac-bots
container_name: zodiac-db
networks:
- zodiac-bots-network
volumes:
- pgdata:/var/lib/postgresql/data
smtp:
image: maildev/maildev
environment:
- MAILDEV_WEBMAIL_USER=kleros
- MAILDEV_WEBMAIL_PASSWORD=sorelk
container_name: zodiac-smtp
networks:
- zodiac-bots-network
networks:
zodiac-bots-network:
volumes:
pgdata: