-
Notifications
You must be signed in to change notification settings - Fork 1
/
docker-compose.dev.yml
126 lines (113 loc) · 2.98 KB
/
docker-compose.dev.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
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
version: '3.8'
services:
# Frontend
frontend:
build:
context: ./frontend
dockerfile: Dockerfile
ports:
- "3000:3000"
environment:
- "NEXT_PUBLIC_API_ENDPOINT_HOST=http://api.agents.cardanoapi.io/api"
# FastAPI application (build the image)
api:
build: ./api # Path to your FastAPI project directory
ports:
- "8000:8000"
environment:
- DATABASE_URL=postgresql://root:root@postgres:5432/cardano_autonomous_agent_testing_db
- KAFKA_BROKERS=kafka:9093
- DOCS_URL=/api/docs
- OPENAPI_URL=/aio/openapi.json
depends_on:
- postgres
- kafka
- pgadmin
# Agent Manager application (build image)
agent_manager:
build:
context: ./agent-manager
dockerfile: Dockerfile
ports:
- "3001:3001"
depends_on:
- postgres
- kafka
- api
environment:
- DATABASE_URL=postgresql://root:root@postgres:5432/cardano_autonomous_agent_testing_db
- BROKER_URL=kafka:9093
- CLIENT_ID=my-app
- CARDANO_NODE_URL=95.217.224.100:3006
- API_URL=http://api:8000
#Agent (build image)
agent:
build:
context: ./agent-node
dockerfile: Dockerfile
ports:
- "3002:3002"
depends_on:
- agent_manager
environment:
- WS_URL= # Use service name as hostname within Docker network
- AGENT_ID= # Provide the agent ID as needed
#Database
postgres:
image: postgres:16.2
environment:
POSTGRES_DB: cardano_autonomous_agent_testing_db
POSTGRES_USER: root
POSTGRES_PASSWORD: root
ports:
- "5432:5432"
volumes:
- pg-data:/var/lib/postgresql/data
#Pgadmin
pgadmin:
image: dpage/pgadmin4:8.2
environment:
PGADMIN_DEFAULT_EMAIL: [email protected]
PGADMIN_DEFAULT_PASSWORD: password
ports:
- "5050:80"
#Zookeper
zookeeper:
image: confluentinc/cp-zookeeper:7.0.1
ports:
- "2181:2181"
environment:
ZOOKEEPER_CLIENT_PORT: 2181
ZOOKEEPER_TICK_TIME: 2000
ZOOKEEPER_SYNC_LIMIT: 2
#Kafka
kafka:
image: confluentinc/cp-kafka:7.0.1
hostname: kafka
depends_on:
- zookeeper
ports:
- "9092:9092"
environment:
KAFKA_BROKER_ID: 1
KAFKA_ZOOKEEPER_CONNECT: zookeeper:2181
KAFKA_LISTENER_SECURITY_PROTOCOL_MAP: DOCKER_NET:PLAINTEXT,HOST_NET:PLAINTEXT
KAFKA_ADVERTISED_LISTENERS: DOCKER_NET://kafka:9093,HOST_NET://localhost:9092
KAFKA_INTER_BROKER_LISTENER_NAME: DOCKER_NET
KAFKA_OFFSETS_TOPIC_REPLICATION_FACTOR: 1
KAFKA_TRANSACTION_STATE_LOG_MIN_ISR: 1
KAFKA_TRANSACTION_STATE_LOG_REPLICATION_FACTOR: 1
KAFKA_GROUP_INITIAL_REBALANCE_DELAY_MS: 0
KAFKA_JMX_PORT: 9999
KAFKA_CREATE_TOPICS: "trigger_config_updates:1:1"
#Kafka UI
kafka-ui:
image: provectuslabs/kafka-ui
ports:
- "8080:8080"
restart: always
environment:
- KAFKA_CLUSTERS_0_NAME=local
- KAFKA_CLUSTERS_0_BOOTSTRAP_SERVERS=kafka:9093
volumes:
pg-data: