avalanchego icon indicating copy to clipboard operation
avalanchego copied to clipboard

lack of information about docker container

Open nicosolo opened this issue 5 years ago • 6 comments

Hello,

The infos about the docker on the README.md is lacking important informations.

It should mention to map a volume like so: docker run -ti -p 9650:9650 -p 9651:9651 -v /host/avalanche:/root/.avalanchego avalanchego-xxxxxxxx /avalanchego/build/avalanchego --network-id=local --staking-enabled=false --snow-sample-size=1 --snow-quorum-size=1

If not set when removing the container eg. for an update. the stacker.crt and stacker.key will be removed so the NodeId will be reseted.

nicosolo avatar Sep 26 '20 09:09 nicosolo

Also would love to see more docker support here. I can't seem to figure out how to call the API with outside of the docker container. It looks like port 9650 should be exposed right?

PatrickAlphaC avatar Sep 26 '20 22:09 PatrickAlphaC

@PatrickAlphaC thanks for raising this issue. Our docker support definitely needs some work, so I'll try to fix this ASAP.

As for sending API requests to the docker container, you will have to start it with the command line parameter --http-host= . This is the same as if you wanted to publicly expose the http API port.

aaronbuchwald avatar Oct 02 '20 01:10 aaronbuchwald

Yes, your comment on https://github.com/ava-labs/avalanchego/issues/453 helped a lot.

PatrickAlphaC avatar Oct 02 '20 01:10 PatrickAlphaC

Looks like the README.md needs to be updated again.

The docker image is now avaplatform/avalanchego and you run the node with docker run -ti -p 9650:9650 -p 9651:9651 avaplatform/avalanchego /avalanchego/build/avalanchego --network-id=fuji --http-host=

It looks like the avalanchego-xxxxxx has been removed.

FYI, I think this syntax is much nicer :)

PatrickAlphaC avatar Oct 13 '20 14:10 PatrickAlphaC

I'm trying to get a Docker-compose file to use the Avalanche Docker image and am running into a few issues.

The file is below https://github.com/pangolin-community/subgraph/blob/master/docker-compose.yaml

But I haven't figured out how to add the command line arguments to the docker-compose file. Any tips on what I should be attempting?

HariSeldon23 avatar Mar 22 '21 02:03 HariSeldon23

I checked avalanchego docker file https://github.com/ava-labs/avalanchego/blob/master/Dockerfile ... does it have any volumes at all? When I ran it and study with docker inspect it's not working. Obviously it's made for short term testing? I would consider current Dockerfile as a bug.

eino-makitalo avatar Jun 21 '21 17:06 eino-makitalo