Skip to main content

No project description provided

Project description

hoprd-config-tool

Tool to generate HOPRd identity, configuration, and docker-compose files from a single input where all required data is specified.

Installation

 pip(3) install (-U) hoprd-config-tool

Usage

To generate the required ressources (identities, configurations and docker-compose files) from a config file, run the following command:

 python -m hoprd-config-tool --params .config/network_1.toml

You can specify the root folder where identity and configuration files will be generated by appending the optional parameter --folder <FOLDER> which by default is set to ./.hoprd-nodes/.

The generated docker compose file follows the default naming: docker-compose.yml

Custom Docker networks

If you need the generated compose file to reference custom networks (for example to attach the services to an existing external network) you can define them in your configuration file under the networks key, using the same syntax as in a regular docker-compose.yml file:

[networks.default]
name = "hoprd-network1"
external = true

The contents of this section are copied verbatim into the rendered compose file and every generated service automatically references all declared networks.

Using tagged values in TOML

The TOML params file can express the YAML tags used by the generated configuration (for example !AutoFunding, !AutoRedeeming, or !ClosureFinalizer) by embedding the tag in the array-of-table header:

[[config.hopr.strategy.strategies.AutoFunding]]
funding_amount = "500 xDAI"
min_stake_threshold = "100 HOPR"

The tool converts those entries into the appropriate YAML objects before rendering the final .cfg.yaml files, so the output format remains unchanged.

Naming nodes with surnames

Each entry in the [[nodes]] section can optionally embed the node's surname directly into the table header to differentiate nodes within the same params file:

[[nodes.alpha]]
safe_address = "SAFE_ADDRESS_1"
...

The surname in the header is converted to a slug (letters, numbers, and dashes only) and used in every generated file path and docker-compose service name. If a node omits the surname (for example by sticking with a plain [[nodes]] entry) the tool falls back to the numeric index, preserving the existing behavior.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

hoprd_config_tool-0.2.0.tar.gz (27.6 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

hoprd_config_tool-0.2.0-py3-none-any.whl (13.7 kB view details)

Uploaded Python 3

File details

Details for the file hoprd_config_tool-0.2.0.tar.gz.

File metadata

  • Download URL: hoprd_config_tool-0.2.0.tar.gz
  • Upload date:
  • Size: 27.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for hoprd_config_tool-0.2.0.tar.gz
Algorithm Hash digest
SHA256 dd8af48b69f65942e361c3ff87b0dc2e14ec6d46f171b6ec3cae1a3c4b5dc17a
MD5 79841829a26fb640d3b4a0bcfcfe9cf7
BLAKE2b-256 98a3e7d9c68040883db4260742d7e06361e03b39e3dcab1ff8a8d44f43eddbf2

See more details on using hashes here.

Provenance

The following attestation bundles were made for hoprd_config_tool-0.2.0.tar.gz:

Publisher: publish.yml on jeandemeusy/hoprd-config-tool

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file hoprd_config_tool-0.2.0-py3-none-any.whl.

File metadata

File hashes

Hashes for hoprd_config_tool-0.2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 1fbc5d35273d9338f78bd8483f7c97bfedfb371a05e92027df69636537564125
MD5 82c5b877bfc9255a6148d856fe6436f4
BLAKE2b-256 9d640cdece7d078730c1786a8d213bd09040d3869d1ab391e04752518ca2258d

See more details on using hashes here.

Provenance

The following attestation bundles were made for hoprd_config_tool-0.2.0-py3-none-any.whl:

Publisher: publish.yml on jeandemeusy/hoprd-config-tool

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page