From 2ed70df29a365ef25e55e8c18c4a72d32126c1d5 Mon Sep 17 00:00:00 2001 From: cardosofede Date: Fri, 28 Apr 2023 18:39:19 -0300 Subject: [PATCH 1/3] (feat) first implementation of Hummingbot + Dashboard --- hummingbot_with_dashboard/docker-compose.yml | 26 ++++++++++++++++++++ 1 file changed, 26 insertions(+) create mode 100644 hummingbot_with_dashboard/docker-compose.yml diff --git a/hummingbot_with_dashboard/docker-compose.yml b/hummingbot_with_dashboard/docker-compose.yml new file mode 100644 index 0000000..78a77d2 --- /dev/null +++ b/hummingbot_with_dashboard/docker-compose.yml @@ -0,0 +1,26 @@ +version: "3.9" +services: + bot: + container_name: hummingbot + image: dardonacci/hummingbot:multiarch + volumes: + - ./hummingbot_files/conf:/home/hummingbot/conf + - ./hummingbot_files/conf/connectors:/home/hummingbot/conf/connectors + - ./hummingbot_files/conf/strategies:/home/hummingbot/conf/strategies + - ./hummingbot_files/logs:/home/hummingbot/logs + - ./hummingbot_files/data:/home/hummingbot/data + logging: + driver: "json-file" + options: + max-size: "10m" + max-file: 5 + tty: true + stdin_open: true + network_mode: host + dashboard: + container_name: dashboard + image: dardonacci/streamlit-apps:latest + volumes: + - ./hummingbot_files/data:/home/streamlit-apps/data + ports: + - "8501:8501" From 6cfa158be684a3a9510cb730347a6c1e3ffbf051 Mon Sep 17 00:00:00 2001 From: cardosofede Date: Thu, 4 May 2023 12:22:02 -0300 Subject: [PATCH 2/3] (feat) update mount point version based on new dockerfile --- .../docker-compose.yml | 25 ++++++----- hummingbot_gateway_compose/docker-compose.yml | 22 ++++------ .../docker-compose.yml | 41 ++++++++----------- simple_hummingbot_compose/docker-compose.yml | 17 ++++---- 4 files changed, 46 insertions(+), 59 deletions(-) diff --git a/autostart_hummingbot_compose/docker-compose.yml b/autostart_hummingbot_compose/docker-compose.yml index 31bacc4..e8b573b 100644 --- a/autostart_hummingbot_compose/docker-compose.yml +++ b/autostart_hummingbot_compose/docker-compose.yml @@ -1,21 +1,20 @@ version: "3.9" services: hummingbot: - container_name: "hummingbot" + container_name: hummingbot image: hummingbot/hummingbot:latest - # image: hummingbot/hummingbot:latest-arm volumes: - - "./hummingbot_files/conf:/conf" - - "./hummingbot_files/conf/connectors:/conf/connectors" - - "./hummingbot_files/conf/strategies:/conf/strategies" - - "./hummingbot_files/logs:/logs" - - "./hummingbot_files/data:/data" - - "./hummingbot_files/scripts:/scripts" - - "./hummingbot_files/certs:/certs" - # environment: - # - CONFIG_PASSWORD=[password] - # - CONFIG_FILE_NAME=simple_pmm_example.py - # - CONFIG_FILE_NAME=conf_pure_mm_1.yml + - "./hummingbot_files/conf:/home/hummingbot/conf" + - "./hummingbot_files/conf/connectors:/home/hummingbot/conf/connectors" + - "./hummingbot_files/conf/strategies:/home/hummingbot/conf/strategies" + - "./hummingbot_files/logs:/home/hummingbot/logs" + - "./hummingbot_files/data:/home/hummingbot/data" + - "./hummingbot_files/scripts:/home/hummingbot/scripts" + - "./hummingbot_files/certs:/home/hummingbot/certs" +# environment: +# - CONFIG_PASSWORD=[password] +# - CONFIG_FILE_NAME=simple_pmm_example.py +# - CONFIG_FILE_NAME=conf_pure_mm_1.yml logging: driver: "json-file" options: diff --git a/hummingbot_gateway_compose/docker-compose.yml b/hummingbot_gateway_compose/docker-compose.yml index e15e33e..b096d70 100644 --- a/hummingbot_gateway_compose/docker-compose.yml +++ b/hummingbot_gateway_compose/docker-compose.yml @@ -1,19 +1,16 @@ version: "3.9" services: hummingbot: - container_name: "hummingbot" + container_name: hummingbot image: hummingbot/hummingbot:latest - # image: hummingbot/hummingbot:latest-arm volumes: - - "./hummingbot_files/conf:/conf" - - "./hummingbot_files/conf/connectors:/conf/connectors" - - "./hummingbot_files/conf/strategies:/conf/strategies" - - "./hummingbot_files/logs:/logs" - - "./hummingbot_files/data:/data" - - "./hummingbot_files/scripts:/scripts" - - "./hummingbot_files/certs:/certs" - # environment: - # - CONFIG_PASSWORD=[password] + - "./hummingbot_files/conf:/home/hummingbot/conf" + - "./hummingbot_files/conf/connectors:/home/hummingbot/conf/connectors" + - "./hummingbot_files/conf/strategies:/home/hummingbot/conf/strategies" + - "./hummingbot_files/logs:/home/hummingbot/logs" + - "./hummingbot_files/data:/home/hummingbot/data" + - "./hummingbot_files/scripts:/home/hummingbot/scripts" + - "./hummingbot_files/certs:/home/hummingbot/certs" logging: driver: "json-file" options: @@ -24,9 +21,8 @@ services: network_mode: host gateway: - container_name: "gateway" + container_name: gateway image: hummingbot/gateway:latest - # image: hummingbot/gateway:latest-arm ports: - "15888:15888" - "8080:8080" diff --git a/multiple_hummingbot_gateway_compose/docker-compose.yml b/multiple_hummingbot_gateway_compose/docker-compose.yml index 77c4073..1848ef7 100644 --- a/multiple_hummingbot_gateway_compose/docker-compose.yml +++ b/multiple_hummingbot_gateway_compose/docker-compose.yml @@ -1,19 +1,16 @@ version: "3.9" services: hummingbot-1: - container_name: "hummingbot-1" + container_name: hummingbot-1 image: hummingbot/hummingbot:latest - # image: hummingbot/hummingbot:latest-arm volumes: - - "./hummingbot_files/conf:/conf" - - "./hummingbot_files/conf/connectors:/conf/connectors" - - "./hummingbot_files/conf/strategies:/conf/strategies" - - "./hummingbot_files/logs:/logs" - - "./hummingbot_files/data:/data" - - "./hummingbot_files/scripts:/scripts" - - "./hummingbot_files/certs:/certs" - # environment: - # - CONFIG_PASSWORD=[password] + - "./hummingbot_files/conf:/home/hummingbot/conf" + - "./hummingbot_files/conf/connectors:/home/hummingbot/conf/connectors" + - "./hummingbot_files/conf/strategies:/home/hummingbot/conf/strategies" + - "./hummingbot_files/logs:/home/hummingbot/logs" + - "./hummingbot_files/data:/home/hummingbot/data" + - "./hummingbot_files/scripts:/home/hummingbot/scripts" + - "./hummingbot_files/certs:/home/hummingbot/certs" logging: driver: "json-file" options: @@ -24,19 +21,16 @@ services: network_mode: host hummingbot-2: - container_name: "hummingbot-2" + container_name: hummingbot-2 image: hummingbot/hummingbot:latest - # image: hummingbot/hummingbot:latest-arm volumes: - - "./hummingbot_files/conf:/conf" - - "./hummingbot_files/conf/connectors:/conf/connectors" - - "./hummingbot_files/conf/strategies:/conf/strategies" - - "./hummingbot_files/logs:/logs" - - "./hummingbot_files/data:/data" - - "./hummingbot_files/scripts:/scripts" - - "./hummingbot_files/certs:/certs" - # environment: - # - CONFIG_PASSWORD=[password] + - "./hummingbot_files/conf:/home/hummingbot/conf" + - "./hummingbot_files/logs:/home/hummingbot/logs" + - "./hummingbot_files/data:/home/hummingbot/data" + - "./hummingbot_files/scripts:/home/hummingbot/scripts" + - "./hummingbot_files/certs:/home/hummingbot/certs" + environment: + - CONFIG_PASSWORD=a logging: driver: "json-file" options: @@ -47,9 +41,8 @@ services: network_mode: host gateway: - container_name: "gateway" + container_name: gateway image: hummingbot/gateway:latest - # image: hummingbot/gateway:latest-arm ports: - "15888:15888" - "8080:8080" diff --git a/simple_hummingbot_compose/docker-compose.yml b/simple_hummingbot_compose/docker-compose.yml index 33148ce..a06fa83 100644 --- a/simple_hummingbot_compose/docker-compose.yml +++ b/simple_hummingbot_compose/docker-compose.yml @@ -1,17 +1,16 @@ version: "3.9" services: hummingbot: - container_name: "hummingbot" + container_name: hummingbot image: hummingbot/hummingbot:latest - # image: hummingbot/hummingbot:latest-arm volumes: - - "./hummingbot_files/conf:/conf" - - "./hummingbot_files/conf/connectors:/conf/connectors" - - "./hummingbot_files/conf/strategies:/conf/strategies" - - "./hummingbot_files/logs:/logs" - - "./hummingbot_files/data:/data" - - "./hummingbot_files/scripts:/scripts" - - "./hummingbot_files/certs:/certs" + - "./hummingbot_files/conf:/home/hummingbot/conf" + - "./hummingbot_files/conf/connectors:/home/hummingbot/conf/connectors" + - "./hummingbot_files/conf/strategies:/home/hummingbot/conf/strategies" + - "./hummingbot_files/logs:/home/hummingbot/logs" + - "./hummingbot_files/data:/home/hummingbot/data" + - "./hummingbot_files/scripts:/home/hummingbot/scripts" + - "./hummingbot_files/certs:/home/hummingbot/certs" logging: driver: "json-file" options: From 85ebeda280e6c03b97a8e19d5ede8634e22f27a3 Mon Sep 17 00:00:00 2001 From: cardosofede Date: Fri, 5 May 2023 10:39:44 -0300 Subject: [PATCH 3/3] (feat) update bash scripts --- bash_scripts/hummingbot-create.sh | 16 ++++++++-------- bash_scripts/hummingbot-update.sh | 16 ++++++++-------- 2 files changed, 16 insertions(+), 16 deletions(-) diff --git a/bash_scripts/hummingbot-create.sh b/bash_scripts/hummingbot-create.sh index bd4e8d7..712583e 100755 --- a/bash_scripts/hummingbot-create.sh +++ b/bash_scripts/hummingbot-create.sh @@ -86,14 +86,14 @@ create_instance () { docker run -it --log-opt max-size=10m --log-opt max-file=5 \ --name $INSTANCE_NAME \ --network host \ - -v $CONF_FOLDER:/conf \ - -v $CONF_FOLDER/connectors:/conf/connectors \ - -v $CONF_FOLDER/strategies:/conf/strategies \ - -v $LOGS_FOLDER:/logs \ - -v $DATA_FOLDER:/data \ - -v $PMM_SCRIPTS_FOLDER:/pmm_scripts \ - -v $SCRIPTS_FOLDER:/scripts \ - -v $CERTS_FOLDER:/certs \ + -v $CONF_FOLDER:/home/hummingbot/conf \ + -v $CONF_FOLDER/connectors:/home/hummingbot/conf/connectors \ + -v $CONF_FOLDER/strategies:/home/hummingbot/conf/strategies \ + -v $LOGS_FOLDER:/home/hummingbot/logs \ + -v $DATA_FOLDER:/home/hummingbot/data \ + -v $PMM_SCRIPTS_FOLDER:/home/hummingbot/pmm_scripts \ + -v $SCRIPTS_FOLDER:/home/hummingbot/scripts \ + -v $CERTS_FOLDER:/home/hummingbot/certs \ hummingbot/hummingbot:$TAG } diff --git a/bash_scripts/hummingbot-update.sh b/bash_scripts/hummingbot-update.sh index c049892..79accda 100755 --- a/bash_scripts/hummingbot-update.sh +++ b/bash_scripts/hummingbot-update.sh @@ -105,14 +105,14 @@ execute_docker () { docker run -itd --log-opt max-size=10m --log-opt max-file=5 \ --network host \ --name ${INSTANCES[$j]} \ - -v ${FOLDERS[$j]}/conf:/conf \ - -v ${FOLDERS[$j]}/conf/connectors:/conf/connectors \ - -v ${FOLDERS[$j]}/conf/strategies:/conf/strategies \ - -v ${FOLDERS[$j]}/logs:/logs \ - -v ${FOLDERS[$j]}/data:/data \ - -v ${FOLDERS[$j]}/pmm-scripts:/pmm-scripts \ - -v ${FOLDERS[$j]}/scripts:/scripts \ - -v ${FOLDERS[$j]}/certs:/certs \ + -v ${FOLDERS[$j]}/conf:/home/hummingbot/conf \ + -v ${FOLDERS[$j]}/conf/connectors:/home/hummingbot/conf/connectors \ + -v ${FOLDERS[$j]}/conf/strategies:/home/hummingbot/conf/strategies \ + -v ${FOLDERS[$j]}/logs:/home/hummingbot/logs \ + -v ${FOLDERS[$j]}/data:/home/hummingbot/data \ + -v ${FOLDERS[$j]}/pmm-scripts:/home/hummingbot/pmm-scripts \ + -v ${FOLDERS[$j]}/scripts:/home/hummingbot/scripts \ + -v ${FOLDERS[$j]}/certs:/home/hummingbot/certs \ hummingbot/hummingbot:$TAG j=$[$j+1] # Update file ownership