Skip to content

Commit 54b1c73

Browse files
committed
Merge branch 'company-id-tool' of https://github.com/Concordium/concordium.github.io into company-id-tool
2 parents a113e60 + 2d797a7 commit 54b1c73

File tree

1 file changed

+18
-14
lines changed

1 file changed

+18
-14
lines changed

source/mainnet/net/guides/run-local-chain.rst

+18-14
Original file line numberDiff line numberDiff line change
@@ -16,18 +16,18 @@ The chain is run by a network of validator nodes that produce blocks. In the fol
1616

1717
Prerequisites
1818
=============
19-
You will either need a working installation of the Concordium Node distribution or Docker, instances of which will be used to run the validator node(s). You will need :term:`genesis block` data which defines your local chain and sets of credentials for validator accounts of the chain. The number of sets of validator credentials needed thus depends on the desired number of validators in the network, which in this example is 1.
19+
You will either need a working installation of the :ref:`Concordium Node distribution<node-downloads>` or `Docker <https://www.docker.com/>`_, instances of which will be used to run the validator node(s). You will need :term:`genesis block` data, which defines your local chain and sets of credentials for validator accounts of the chain. The number of sets of validator credentials needed thus depends on the desired number of validators in the network, which in this example is one.
2020

2121
Install the node distribution
2222
-----------------------------
23-
Concordium Node releases exist for Ubuntu, MacOS and Windows and Docker. See the :ref:`Node Requirements<node-requirements>` section for information on system requirements and detailed instructions on how to obtain, run, and manage a node. To run a validator, you either need a Concordium node binary supplied with your appropriate distribution in your path or a working Docker installation. This depends on whether you want to run the Node binary directly on your host or as a Docker instance. The details below assume the former, but if you want to run a Docker instance, you can skip to the next section.
23+
Concordium Node releases exist for Ubuntu, MacOS, Windows and Docker. See the :ref:`Node Requirements<node-requirements>` section for information on system requirements and detailed instructions on how to obtain, run, and manage a node. To run a validator, you either need a Concordium node binary supplied with your appropriate distribution in your path or a working Docker installation. This depends on whether you want to run the Node binary directly on your host or as a Docker instance. The details below assume the former, but if you want to run a Docker instance, you can skip to the next section.
2424

2525
The name of the binary has ``concordium-`` as its prefix but depends on the distribution, so you may have to confer with the installation instructions to figure out the exact name. Upon successful installation of the distribution, verify that the binary exists in your path at the required version:
2626

2727
.. code-block:: console
2828
2929
$ concordium-node --version # name depends on distribution
30-
concordium_node 5.3.2
30+
concordium_node 6.1.7
3131
3232
.. Note::
3333

@@ -77,19 +77,23 @@ The ``genesis-creator`` tool uses a TOML configuration file format for specifyin
7777
* keys for updating the chain
7878
* various parameters for the genesis
7979

80-
Furthermore, it specifies where to save the output that is used to invoke the node binary. Most of these options are of little importance when testing smart contracts and the easiest way to get started is to piggyback off of the example configuration file ``single-baker-example-p5.toml`` found `here <https://raw.githubusercontent.com/Concordium/concordium-misc-tools/9d347761aadd432cbb6211a7d7ba38cdc07f1d11/genesis-creator/examples/single-baker-example-p5.toml>`_. Inspecting the configuration reveals that it specifies an initial protocol version of 5 to output credentials for 1 validator account, 1 foundation account, and 100 regular accounts. It specifies the system time at generation for the genesis time, and finally, specifies 5 seconds as the average time per block.
80+
Furthermore, it specifies where to save the output that is used to invoke the node binary. Most of these options are of little importance when testing smart contracts and the easiest way to get started is to piggyback off of the example configuration file ``single-baker-example-p6.toml`` found `here <https://raw.githubusercontent.com/Concordium/concordium-misc-tools/main/genesis-creator/examples/single-baker-example-p6.toml>`_. Inspecting the configuration reveals that it specifies an initial protocol version of 6 to output credentials for 1 validator account, 1 foundation account, and 100 regular accounts. It specifies the system time at generation for the genesis time, and finally, specifies 2 seconds as the minimum time per block.
8181

82-
Further inspection of the tables at the ``accounts`` keys reveals that the validator account has an initial balance of 3.5 * 10^15 microCCD and stake of 3.0 * 10^15 microCCD, the foundation account has an initial balance of 10^16 microCCD, and the regular accounts each have an initial balance of 2.0 * 10^12. You can change the initial stake and balances if desired. The number of credentials produced for each type of account can also be adjusted by setting the values of the ``repeat`` keys to your choosing.
82+
.. note::
83+
84+
Validators were previously called *bakers*, and remnants of the old name are still present in our tools. Whenever you read *baker*, think *validator*.
85+
86+
Further inspection of the tables at the ``accounts`` keys reveals that the validator account has an initial balance of 3.5 * 10^15 microCCD and stake of 3.0 * 10^15 microCCD, the foundation account has an initial balance of 10^16 microCCD, and the regular accounts each have an initial balance of 2.0 * 10^12. You can change the initial stake and balances if desired. The number of accounts produced of each type can also be adjusted by setting the values of the ``repeat`` keys to your choosing.
8387

8488
.. Note::
8589

8690
The staked amount needed for a validator to participate in the finalization committee is some fraction of the total amount of existing CCD set in the configuration. The total amount is the sum of the balances of all the validator and foundation accounts specified in the genesis configuration file. In this particular example, the stake is sufficient for producing blocks.
8791

88-
Save the file as ``single-baker-example-p5.toml`` and generate the genesis data:
92+
Save the file as ``single-baker-example-p6.toml`` and generate the genesis data:
8993

9094
.. code-block:: console
9195
92-
$ ~/.cargo/bin/genesis-creator generate --config ./single-baker-example-p5.toml
96+
$ ~/.cargo/bin/genesis-creator generate --config ./single-baker-example-p6.toml
9397
Deleting any existing directories.
9498
Account keys will be generated in ./accounts
9599
Chain update keys will be generated in ./update-keys
@@ -153,25 +157,25 @@ If you ran the validator node by invoking the node binary directly on your host,
153157
image: concordium/mainnet-node:latest
154158
pull_policy: always
155159
environment:
156-
# Baker credentials file
160+
# Validator credentials file
157161
- CONCORDIUM_NODE_BAKER_CREDENTIALS_FILE=/mnt/baker-0-credentials.json
158-
# General node configuration Data and config directories (it's OK if they
162+
# General node configuration data and config directories (it's OK if they
159163
# are the same). This should match the volume mount below. If the location
160164
# of the mount inside the container is changed, then these should be
161165
# changed accordingly as well.
162166
- CONCORDIUM_NODE_DATA_DIR=/mnt/data
163167
- CONCORDIUM_NODE_CONFIG_DIR=/mnt/data
164-
# port on which the node will listen for incoming connections. This is a
168+
# The port on which the node will listen for incoming connections. This is a
165169
# port inside the container. It is mapped to an external port by the port
166170
# mapping in the `ports` section below. If the internal and external ports
167171
# are going to be different then you should also set
168172
# `CONCORDIUM_NODE_EXTERNAL_PORT` variable to what the external port value is.
169173
- CONCORDIUM_NODE_LISTEN_PORT=8169
170-
# Address of the V2 GRPC server
174+
# Address of the V2 GRPC server.
171175
- CONCORDIUM_NODE_GRPC2_LISTEN_ADDRESS=0.0.0.0
172-
# And its port
176+
# And its port.
173177
- CONCORDIUM_NODE_GRPC2_LISTEN_PORT=20100
174-
# Do not bootstrap via DNS
178+
# Do not bootstrap via DNS.
175179
- CONCORDIUM_NODE_CONNECTION_NO_BOOTSTRAP_DNS=true
176180
entrypoint: ["/concordium-node"]
177181
# Exposed ports. The ports the node listens on inside the container (defined
@@ -205,7 +209,7 @@ You can now interact with your local chain through the node via the :ref:`Concor
205209

206210
.. code-block:: console
207211
208-
$ concordium-client --grpc-ip 127.0.0.1 --grpc-port 20100 account list
212+
$ concordium-client --grpc-ip 127.0.0.1 --grpc-port 20100 account list
209213
Accounts:
210214
Account Address Account Names
211215
--------------------------------------------------------------------

0 commit comments

Comments
 (0)