GithubHelp home page GithubHelp logo

hophat / ethereum-docker-nika Goto Github PK

View Code? Open in Web Editor NEW

This project forked from dawar2151/ethereum-docker

0.0 0.0 0.0 1.09 MB

That project build an Ethereum containerized private network without bootnode.

Shell 50.01% Python 49.99%

ethereum-docker-nika's Introduction

Ethereum-docker

Build Ethereum Private Network in Production with Docker, and without cluster. Documentation used:

Install prerequisites (nodes & local)

To enable the launchpad repository run:

sudo add-apt-repository -y ppa:ethereum/ethereum

After that you can install the stable version of Go Ethereum:

sudo apt-get update
sudo apt-get -y install ethereum

Install prerequisites (local only)

Clone the repo in the same folder than blockchain-generator !

Install pip

sudo apt-get install python3-pip

Then install virtualenv using pip

sudo pip install virtualenv

Now create a virtual environment

virtualenv venv

you can use any name insted of venv

Active your virtual environment:

source venv/bin/activate

then install requirements

pip install -r requirements.txt

Required parameters

Node_number: the number of node needed for the network. 2

Network_path: The path from where nodes will be copied/ nodes

Network_Id: the blockchain identifiant. 1234

IP_Address: Enter the public/private ip address: 127.0.0.1 (it must be a private ip or public ip accessible in all nodes)

install docker

Usage:

From https://get.docker.com:

curl -fsSL https://get.docker.com -o get-docker.sh
sh get-docker.sh

From https://test.docker.com:

curl -fsSL https://test.docker.com -o test-docker.sh
sh test-docker.sh

Start the script

sh start.sh

Run nodes

docker-compose up

Run nodes in separate terminal

For 2 nodes cases Open first ternminal

docker-compose run node_1

Open second ternminal

docker-compose run node_2

To verify if it works, launch this command in local :

curl -X POST -H "Content-Type: application/json" --data '{"jsonrpc":"2.0","method":"net_version","params":[],"id":67}' http://[IP private/public address]:8503

ethereum-docker-nika's People

Contributors

dawar2151 avatar dependabot[bot] avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.