I am trying to setup a sawtooth node for testing with docker in ubuntu like in the tutorial:
https://sawtooth.hyperledger.org/docs/1.2/app_developers_guide/installing_sawtooth.html
After downloading the Docker images for the Sawtooth environment I check that the containers are up with docker ps
:
running containers
and then I connect to the client and run:
curl http://rest-api:8008/blocks
to confirm that the REST-API and validator are reachable by the client but the command returns nothing so we have a connectivity issue.
On the other hand, connectivity from the host machine seems to be working. I have seen that most people encountered this issue instead of mine.
This is the part of the configuration file sawtooth-default.yaml consering the rest-api container.
rest-api:
image: hyperledger/sawtooth-rest-api:chime
container_name: sawtooth-rest-api-default
ports:
- "8008:8008"
depends_on:
- validator
entrypoint: sawtooth-rest-api -C tcp://validator:4004 --bind rest-api:8008
I have tried the solutions proposed here: https://stackoverflow.com/questions/49568174/facing-issues-while-testing-connectivity-from-docker-container-to-validator-cur but to no use.
Since I also use docker for the first time, I have a feeling I messed up sth during during docker installation.
Does anyone know what might be the source of the problem? Thank you
As I expected, the source of the problem was some mistake I did during the installation of docker.
More specificaly, I configured docker to use a proxy server even thought I am not behind one so communication between containers was hindered. Once I fixed this, the client could communicate properly with the validator.