Skip to content
This repository has been archived by the owner on Apr 27, 2021. It is now read-only.

No data on Dashboard when I use on docker #19

Open
manumonti opened this issue Jun 19, 2020 · 0 comments
Open

No data on Dashboard when I use on docker #19

manumonti opened this issue Jun 19, 2020 · 0 comments

Comments

@manumonti
Copy link

manumonti commented Jun 19, 2020

Hi,
I'm deploying a private network based on Hyperledger Besu.

I have 5 docker containers, one per node, running Besu (v 1.5).

Also, I have 5 docker container running ethstats-cli (last version at this moment), one per Besu node and some containers running ethstats network server, deepstream and dashboard.

Well, I have found this problem: If I try to run all these containers with docker compose, Network Statistics dashboard doesn't show all the data:

image

But, if I run all the dockers containers with a docker-compose file except ethstats-cli, and waits about 30 seconds, and then I run the ethstats-cli containers, then everything works properly.

I tried using depends_on instruction on docker-compose with no result. I think the issue is that if ethstat-client tries to connect with deepstream too early, the connection will never succeed.

This is my docker-compose file:

services:
    correlatornode:
        container_name: bcnode-correlator
        image: hyperledger/besu:1.5
        network_mode: "host"
        volumes:
            - ./BcNodesVolumes/correlatorNode:/opt/sadecei
        environment:
            - BESU_RPC_HTTP_PORT=10101
            - BESU_P2P_PORT=11101
            - BESU_DATA_PATH=/opt/sadecei
            - BESU_GENESIS_FILE=/opt/sadecei/genesis.json
            - BESU_DISCOVERY_ENABLED=false
            - BESU_PERMISSIONS_NODES_CONFIG_FILE_ENABLED=true
            - BESU_PERMISSIONS_NODES_CONFIG_FILE=/opt/sadecei/permissions_config_nodes.toml
            - BESU_PERMISSIONS_ACCOUNTS_CONFIG_FILE_ENABLED=true
            - BESU_PERMISSIONS_ACCOUNTS_CONFIG_FILE=/opt/sadecei/permissions_config_accounts.toml
            - BESU_RPC_HTTP_ENABLED=true
            - BESU_RPC_HTTP_API=ADMIN,ETH,NET,WEB3,PERM,IBFT
            - BESU_HOST_WHITELIST=*
            - BESU_RPC_HTTP_CORS_ORIGINS=*
            - BESU_MIN_GAS_PRICE=0

    
    dtnode:
        container_name: bcnode-dt
        image: hyperledger/besu:1.5
        network_mode: "host"
        volumes:
            - ./BcNodesVolumes/dtNode:/opt/sadecei
        environment:
        - BESU_RPC_HTTP_PORT=10102
        - BESU_P2P_PORT=11102
        - BESU_DATA_PATH=/opt/sadecei
        - BESU_GENESIS_FILE=/opt/sadecei/genesis.json
        - BESU_DISCOVERY_ENABLED=false
        - BESU_PERMISSIONS_NODES_CONFIG_FILE_ENABLED=true
        - BESU_PERMISSIONS_NODES_CONFIG_FILE=/opt/sadecei/permissions_config_nodes.toml
        - BESU_PERMISSIONS_ACCOUNTS_CONFIG_FILE_ENABLED=true
        - BESU_PERMISSIONS_ACCOUNTS_CONFIG_FILE=/opt/sadecei/permissions_config_accounts.toml
        - BESU_RPC_HTTP_ENABLED=true
        - BESU_RPC_HTTP_API=ADMIN,ETH,NET,WEB3,PERM,IBFT
        - BESU_HOST_WHITELIST=*
        - BESU_RPC_HTTP_CORS_ORIGINS=*
        - BESU_MIN_GAS_PRICE=0

    fdnode:
        container_name: bcnode-fd
        image: hyperledger/besu:1.5
        network_mode: "host"
        volumes:
            - ./BcNodesVolumes/fdNode:/opt/sadecei
        environment:
        - BESU_RPC_HTTP_PORT=10103
        - BESU_P2P_PORT=11103
        - BESU_DATA_PATH=/opt/sadecei
        - BESU_GENESIS_FILE=/opt/sadecei/genesis.json
        - BESU_DISCOVERY_ENABLED=false
        - BESU_PERMISSIONS_NODES_CONFIG_FILE_ENABLED=true
        - BESU_PERMISSIONS_NODES_CONFIG_FILE=/opt/sadecei/permissions_config_nodes.toml
        - BESU_PERMISSIONS_ACCOUNTS_CONFIG_FILE_ENABLED=true
        - BESU_PERMISSIONS_ACCOUNTS_CONFIG_FILE=/opt/sadecei/permissions_config_accounts.toml
        - BESU_RPC_HTTP_ENABLED=true
        - BESU_RPC_HTTP_API=ADMIN,ETH,NET,WEB3,PERM,IBFT
        - BESU_HOST_WHITELIST=*
        - BESU_RPC_HTTP_CORS_ORIGINS=*
        - BESU_MIN_GAS_PRICE=0

    plcnode:
        container_name: bcnode-plc
        image: hyperledger/besu:1.5
        network_mode: "host"
        volumes:
            - ./BcNodesVolumes/plcNode:/opt/sadecei
        environment:
        - BESU_RPC_HTTP_PORT=10104
        - BESU_P2P_PORT=11104
        - BESU_DATA_PATH=/opt/sadecei
        - BESU_GENESIS_FILE=/opt/sadecei/genesis.json
        - BESU_DISCOVERY_ENABLED=false
        - BESU_PERMISSIONS_NODES_CONFIG_FILE_ENABLED=true
        - BESU_PERMISSIONS_NODES_CONFIG_FILE=/opt/sadecei/permissions_config_nodes.toml
        - BESU_PERMISSIONS_ACCOUNTS_CONFIG_FILE_ENABLED=true
        - BESU_PERMISSIONS_ACCOUNTS_CONFIG_FILE=/opt/sadecei/permissions_config_accounts.toml
        - BESU_RPC_HTTP_ENABLED=true
        - BESU_RPC_HTTP_API=ADMIN,ETH,NET,WEB3,PERM,IBFT
        - BESU_HOST_WHITELIST=*
        - BESU_RPC_HTTP_CORS_ORIGINS=*
        - BESU_MIN_GAS_PRICE=0

    scadanode:
        container_name: bcnode-scada
        image: hyperledger/besu:1.5
        network_mode: "host"
        volumes:
            - ./BcNodesVolumes/scadaNode:/opt/sadecei
        environment:
        - BESU_RPC_HTTP_PORT=10105
        - BESU_P2P_PORT=11105
        - BESU_DATA_PATH=/opt/sadecei
        - BESU_GENESIS_FILE=/opt/sadecei/genesis.json
        - BESU_DISCOVERY_ENABLED=false
        - BESU_PERMISSIONS_NODES_CONFIG_FILE_ENABLED=true
        - BESU_PERMISSIONS_NODES_CONFIG_FILE=/opt/sadecei/permissions_config_nodes.toml
        - BESU_PERMISSIONS_ACCOUNTS_CONFIG_FILE_ENABLED=true
        - BESU_PERMISSIONS_ACCOUNTS_CONFIG_FILE=/opt/sadecei/permissions_config_accounts.toml
        - BESU_RPC_HTTP_ENABLED=true
        - BESU_RPC_HTTP_API=ADMIN,ETH,NET,WEB3,PERM,IBFT
        - BESU_HOST_WHITELIST=*
        - BESU_RPC_HTTP_CORS_ORIGINS=*
        - BESU_MIN_GAS_PRICE=0

    netstatsserver:
        container_name: netstats-server
        image: alethio/ethstats-network-server:latest
        restart: always
        depends_on:
            - deepstream
        ports:
            - 127.0.0.1:3000:3000
            - 127.0.0.1:3030:3030
            - 127.0.0.1:8888:8888
        environment:
            - NETWORK_ID=5403
            - NETWORK_NAME=SADECEI-4.0
            - LITE=1
            - LITE_DB_PERSIST=0
            - LITE_API_PORT=3030
            - APP_PORT=3000
            - METRICS_PORT=8888
            - DEEPSTREAM_HOST=deepstream
        command: ["./bin/app.js", "-v"]
    deepstream:
        container_name: netstats-deepstream
        image: deepstreamio/deepstream.io:3.2.2
        restart: always
        depends_on:
            - correlatornode
            - dtnode
            - fdnode
            - plcnode
            - scadanode
        ports:
            - 6020:6020
    netstatsdashboard:
        container_name: netstats-dashboard
        image: alethio/ethstats-network-dashboard:latest
        restart: always
        depends_on:
            - netstatsserver
        ports:
            - 80:80
        environment:
            - NETSTATS_API_URL=http://localhost:3030
            - DS_URL=${IPServer}:6020
            - DS_USER=frontend
            - DS_PASS=
    blockexplorer:
        container_name: blockexplorer-server
        image: alethio/ethereum-lite-explorer
        depends_on:
            - correlatornode
        ports:
            - 8080:80
        environment: 
            - APP_NODE_URL=http://${IPServer}:10101

    netstatsclientcorrelator:
        container_name: netstats-client-correlator
        image: alethio/ethstats-cli:latest
        depends_on:
            - netstatsserver
        restart: always
        command: --register --account-email [email protected] --node-name correlatorNode --server-url http://localhost:3000 --client-url http://localhost:10101
        network_mode: "host"
    netstatsclientdt:
        container_name: netstats-client-dt
        image: alethio/ethstats-cli:latest
        depends_on:
            - netstatsserver
        restart: always
        command: --register --account-email [email protected] --node-name dtNode --server-url http://localhost:3000 --client-url http://localhost:10102
        network_mode: "host"
    netstatsclientfd:
        container_name: netstats-client-fd
        image: alethio/ethstats-cli:latest
        depends_on:
            - netstatsserver
        restart: always
        command: --register --account-email [email protected] --node-name fdNode --server-url http://localhost:3000 --client-url http://localhost:10103
        network_mode: "host"
    netstatsclientplc:
        container_name: netstats-client-plc
        image: alethio/ethstats-cli:latest
        depends_on:
            - netstatsserver
        restart: always
        command: --register --account-email [email protected] --node-name plcNode --server-url http://localhost:3000 --client-url http://localhost:10104
        network_mode: "host"
    netstatsclientscada:
        container_name: netstats-client-scada
        image: alethio/ethstats-cli:latest
        depends_on:
            - netstatsserver
        restart: always
        command: --register --account-email [email protected] --node-name scadaNode --server-url http://localhost:3000 --client-url http://localhost:10105
        network_mode: "host"
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant