7

If I have the eos chain running in a Docker container, how can I interact with it from my local file system? I would love to be able to create my contracts, compile them, and deploy to my docker container without being in the Docker exec terminal. Is there a way to have this traditional development environment using Docker? It is so much easier for me to upgrade chains using it, rather than compiling locally. Thanks!

  • Can't you use an alias? alias cleos='docker-compose exec keosd /opt/eos/bin/cleos -H nodeos' – TeeAttack42 May 8 '18 at 16:37
  • Hm, this seems more of a Docker question than EOS. You have to figure out 1.) how to share data from the host with the docker container and 2.) how to connect to the docker container to run commands (ssh i guess). Maybe this helps: digitalocean.com/community/tutorials/… – Soleone May 8 '18 at 16:38
  • yeah, I can add an alias, but that doesn't allow me to refer to a local contract file. This is something that I want as a smart contract developer – cipherz May 8 '18 at 16:40
  • Can't you bind a docker volume to a local path of your filesystem and push it from there? – TeeAttack42 May 8 '18 at 16:44
4

The EOS.io Wiki page on using the Docker image suggests using the following command: alias cleos='docker-compose exec keosd /opt/eosio/bin/cleos -H nodeosd' to setup a local alias of the cleos command that operates on the docker image.

With this alias setup, you can execute the EOS client commands just like you would on a local instance.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.