-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathcompose.yaml
56 lines (53 loc) · 1.87 KB
/
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
services:
trader:
restart: always
build:
context: ./
# dockerfile: docker/trader.Dockerfile # This is for strategy in the strategies directory, just make sure your have a pyproject.toml file in the root directory
dockerfile: Docker/localTrader.Dockerfile # like trader.Dockerfile but for internal use - local framework source code
args:
STRATEGY: ${STRATEGY}
ports:
- 50000:50000 # This is the port for the SharedStrategyManager (SSM) to extract performance metrics
- 8050:8050 # This is the port the dashboard will be available on
env_file:
# - .env
- stack.env
healthcheck:
# test: ["CMD-SHELL", "nc -vz trader 50000"]
# test: ["CMD-SHELL", "wget -q --spider trader:8050 -O /dev/null"]
interval: "5s"
retries: 300
# TODO: Add Timescale Postgres or MongoDB database service here.
# The commented out section below is an example of how to define a PostgreSQL
# database that your application can use. `depends_on` tells Docker Compose to
# start the database before your application. The `db-data` volume persists the
# database data between container restarts. The `db-password` secret is used
# to set the database password. You must create `db/password.txt` and add
# a password of your choosing to it before running `docker compose up`.
# depends_on:
# db:
# condition: service_healthy
# db:
# image: postgres
# restart: always
# user: postgres
# secrets:
# - db-password
# volumes:
# - db-data:/var/lib/postgresql/data
# environment:
# - POSTGRES_DB=example
# - POSTGRES_PASSWORD_FILE=/run/secrets/db-password
# expose:
# - 5432
# healthcheck:
# test: [ "CMD", "pg_isready" ]
# interval: 10s
# timeout: 5s
# retries: 5
# volumes:
# db-data:
# secrets:
# db-password:
# file: db/password.txt