(feat) update compose files

This commit is contained in:
cardosofede
2025-07-11 02:57:16 +03:00
parent 83e48663fa
commit 91cd3d0365
2 changed files with 64 additions and 16 deletions

View File

@@ -6,7 +6,7 @@ services:
- "8501:8501" - "8501:8501"
environment: environment:
- AUTH_SYSTEM_ENABLED=False - AUTH_SYSTEM_ENABLED=False
- BACKEND_API_HOST=backend-api - BACKEND_API_HOST=hummingbot-api
- BACKEND_API_PORT=8000 - BACKEND_API_PORT=8000
- BACKEND_API_USERNAME=admin - BACKEND_API_USERNAME=admin
- BACKEND_API_PASSWORD=admin - BACKEND_API_PASSWORD=admin
@@ -15,23 +15,24 @@ services:
- ./pages:/home/dashboard/frontend/pages - ./pages:/home/dashboard/frontend/pages
networks: networks:
- emqx-bridge - emqx-bridge
backend-api: hummingbot-api:
container_name: backend-api container_name: hummingbot-api
image: hummingbot/backend-api:dydx image: hummingbot/hummingbot-api:dydx
ports: ports:
- "8000:8000" - "8000:8000"
volumes: volumes:
- ./bots:/backend-api/bots - ./bots:/hummingbot-api/bots
- /var/run/docker.sock:/var/run/docker.sock - /var/run/docker.sock:/var/run/docker.sock
env_file: env_file:
- .env - .env
environment: environment:
# Override specific values for Docker networking
- BROKER_HOST=emqx - BROKER_HOST=emqx
- BROKER_PORT=1883 - DATABASE_URL=postgresql+asyncpg://hbot:hummingbot-api@postgres:5432/hummingbot_api
- USERNAME=admin
- PASSWORD=admin
networks: networks:
- emqx-bridge - emqx-bridge
depends_on:
- postgres
emqx: emqx:
container_name: hummingbot-broker container_name: hummingbot-broker
image: emqx:5 image: emqx:5
@@ -64,6 +65,30 @@ services:
timeout: 25s timeout: 25s
retries: 5 retries: 5
networks:
emqx-bridge:
driver: bridge
postgres:
container_name: hummingbot-postgres
image: postgres:15
restart: unless-stopped
environment:
- POSTGRES_DB=hummingbot_api
- POSTGRES_USER=hbot
- POSTGRES_PASSWORD=hummingbot-api
volumes:
- postgres-data:/var/lib/postgresql/data
ports:
- "5432:5432"
networks:
- emqx-bridge
healthcheck:
test: ["CMD-SHELL", "pg_isready -U hbot -d hummingbot_api"]
interval: 10s
timeout: 5s
retries: 5
networks: networks:
emqx-bridge: emqx-bridge:
driver: bridge driver: bridge
@@ -72,3 +97,4 @@ volumes:
emqx-data: { } emqx-data: { }
emqx-log: { } emqx-log: { }
emqx-etc: { } emqx-etc: { }
postgres-data: { }

View File

@@ -6,7 +6,7 @@ services:
- "8501:8501" - "8501:8501"
environment: environment:
- AUTH_SYSTEM_ENABLED=False - AUTH_SYSTEM_ENABLED=False
- BACKEND_API_HOST=backend-api - BACKEND_API_HOST=hummingbot-api
- BACKEND_API_PORT=8000 - BACKEND_API_PORT=8000
- BACKEND_API_USERNAME=admin - BACKEND_API_USERNAME=admin
- BACKEND_API_PASSWORD=admin - BACKEND_API_PASSWORD=admin
@@ -15,23 +15,24 @@ services:
- ./pages:/home/dashboard/frontend/pages - ./pages:/home/dashboard/frontend/pages
networks: networks:
- emqx-bridge - emqx-bridge
backend-api: hummingbot-api:
container_name: backend-api container_name: hummingbot-api
image: hummingbot/backend-api:latest image: hummingbot/hummingbot-api:latest
ports: ports:
- "8000:8000" - "8000:8000"
volumes: volumes:
- ./bots:/backend-api/bots - ./bots:/hummingbot-api/bots
- /var/run/docker.sock:/var/run/docker.sock - /var/run/docker.sock:/var/run/docker.sock
env_file: env_file:
- .env - .env
environment: environment:
# Override specific values for Docker networking
- BROKER_HOST=emqx - BROKER_HOST=emqx
- BROKER_PORT=1883 - DATABASE_URL=postgresql+asyncpg://hbot:hummingbot-api@postgres:5432/hummingbot_api
- USERNAME=admin
- PASSWORD=admin
networks: networks:
- emqx-bridge - emqx-bridge
depends_on:
- postgres
emqx: emqx:
container_name: hummingbot-broker container_name: hummingbot-broker
image: emqx:5 image: emqx:5
@@ -64,6 +65,26 @@ services:
timeout: 25s timeout: 25s
retries: 5 retries: 5
postgres:
container_name: hummingbot-postgres
image: postgres:15
restart: unless-stopped
environment:
- POSTGRES_DB=hummingbot_api
- POSTGRES_USER=hbot
- POSTGRES_PASSWORD=hummingbot-api
volumes:
- postgres-data:/var/lib/postgresql/data
ports:
- "5432:5432"
networks:
- emqx-bridge
healthcheck:
test: ["CMD-SHELL", "pg_isready -U hbot -d hummingbot_api"]
interval: 10s
timeout: 5s
retries: 5
networks: networks:
emqx-bridge: emqx-bridge:
driver: bridge driver: bridge
@@ -72,3 +93,4 @@ volumes:
emqx-data: { } emqx-data: { }
emqx-log: { } emqx-log: { }
emqx-etc: { } emqx-etc: { }
postgres-data: { }