Skip to content

Commit

Permalink
Fix syntax errors. Add mac/linux commands comments
Browse files Browse the repository at this point in the history
  • Loading branch information
blitzstern5 committed Dec 26, 2018
1 parent 2db9a1e commit 2b9cab8
Showing 1 changed file with 63 additions and 13 deletions.
76 changes: 63 additions & 13 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,76 +1,120 @@
About Genesis
=============

Genesis is an open source blockchain platform which implemented as blockchain network consisting of nodes communicating each other. Each node is backend service having own database and can be interacted by the end user with a client or web ui.
Genesis is an open source blockchain platform which implemented as blockchain network consisting of nodes communicating each other. Each node is backend service having own database and can be interacted by the end user with a client or web UI.

The goal of this quick start solution is to run a local testing network of several Genesis nodes (backends with GUI clients) to give the end user an idea of how Genesis blockchain works and provide usage examples of graphical interface elements as well as smart-contracts.

The backend-side (backend itlsef and database engine) software runs in docker containers and clients run nativly on the host system side.
The backend-side (backend itsef and database engine) software runs in docker containers and clients run natively on the host system side.
As soon as clients start user can interact with local testing Genesis blockchain network.

Usage
=====

Currently Genesis quick start was tested on Mac and Linux.
Windows support is comming.
Windows support is coming.

Use manage.sh to manage Genesis testbed on Linux/Mac and manage.exe to
manage Genesis testbed on Windows.

### Linux/Mac

To create testing network of 5 nodes on Linux/Mac use the following command:
To create a testing network of 5 nodes on Linux/Mac use the following command:

on Mac with Admin account:

```shell
./manage.sh install 5
```
on Linux with sudo-enabled account:

```shell
sudo ./manage.sh install 5
```

This will download and install all required software (docker if it's not installed yet, docker containers with Genesis backends and databases and Genesis clients)
and start 5 Genesis backend instances and 5 accordingly connected Genesis clients.

To stop clients and to stop and delete docker containers run this command:

on Mac with Admin account:
```shell
./manage delete
```
on Linux with sudo-enabled account:
```shell
sudo ./manage delete
```

To stop clients and to stop and delete docker containers and images run this command:

on Mac with Admin account:
```shell
./manage delete-all
```
on Linux with sudo-enabled account:
```shell
sudo ./manage delete-all
```

To check the status of testing network run this command:
To check the status of the testing network run this command:

on Mac with Admin account:
```shell
./manage status
```
on Linux with sudo-enabled account:
```shell
./manage status
```

To start database shell connected to appropriate backend's database run:

on Mac with Admin account:
```shell
./manage db-shell N
```
on Linux with sudo-enabled account:
```shell
sudo ./manage db-shell N
```


where N is the number of a backend.

To stop all clients run:

on Mac with Admin account:
```shell
./manage stop-clients
```
on Linux with sudo-enabled account:
```shell
sudo ./manage stop-clients
```

To start clients again run:

on Mac with Admin account:
```shell
./manage start-clients
```
on Linux with sudo-enabled account:
```shell
sudo ./manage start-clients
```

To reinstall (delete all Genesis-related containers and run installation again with the last installation parameters) run:

on Mac with Admin account:
```shell
./manage reinstall
```
on Linux with sudo-enabled account:
```shell
sudo ./manage reinstall
```

### Windows

Please see [Genesis Quick Start for Windows](https://github.com/GenesisKernel/quick-start-win)
Expand All @@ -83,15 +127,20 @@ A password is required to confirm transactions. The default password is 'genesis
Exposed ports
=============

By default docker backends and database listening ports are exposed to system by
By default docker backends and database listening ports are exposed to the system by
the following rules:

* Database port is exposed to the system port 15432
* Web frontend ports are exposed to 'web port shift' value (8300 by default) plus the index number of a backend, for example the listening port of the first backend by default is exposed to 8301, the second - to 8302 and so on
* Client ports are exposed to 'client port shift' value (17300 by default) plus the index number of a backend, for example the listening port of the first backend by default is exposed to 17301, the second - to 17302 and so on
* Web frontend ports are exposed to 'web port shift' value (8300 by default) plus the index number of a backend, for example, the listening port of the first backend by default is exposed to 8301, the second - to 8302 and so on
* Client ports are exposed to 'client port shift' value (17300 by default) plus the index number of a backend, for example, the listening port of the first backend by default is exposed to 17301, the second - to 17302 and so on

These default ports shifts values can be changed during installation:

on Mac with Admin account:
```shell
./manage.sh install N WPS CPS DBP BLEXP
```
on Linux with sudo-enabled account:
```shell
./manage.sh install N WPS CPS DBP BLEXP
```
Expand All @@ -106,21 +155,22 @@ where:

So running this command:

on Mac with Admin account:
```shell
./manage.sh install 4 9000 19000 6000
```
on Linux with sudo-enabled account:
```shell
./manage.sh install 4 9000 19000 6000
```

will start 4 backends and 4 clients, and fronend ports will be exposed to system port: 9001, 9002, 9003, 9004, clients ports will be exposed to system ports: 19001, 19002, 19003, 19004, and database port will be exposed to system port 6000
will start 4 backends and 4 clients, and frontend ports will be exposed to system port: 9001, 9002, 9003, 9004, clients ports will be exposed to system ports: 19001, 19002, 19003, 19004, and database port will be exposed to system port 6000

Block Explorer
==============

Initial support of Block Explorer was implemented. The default host port for it is 18200, use browser to open it.

Known bugs:
* In some cases requests lead to AJAX-errors
* Some blocks internals are parsed with errors

Useful Links
============

Expand Down

0 comments on commit 2b9cab8

Please sign in to comment.