Archipel tooling is now multi-services

Francois Branciard
Lugus Labs
Published in
4 min readJan 24, 2021

Trustlines Network and Centrifuge nodes support!

Introduction

What is Archipel

Archipel is a consensus-based high availability solution for running blockchain services.

Initially developed to support Polkadot/Kusama nodes operation, we introduced a multi-service feature in the latest 2.2.0 release. It allows to easily support and add other Proof-of-Stake validator nodes operations . With this multi-services feature, many blockchain nodes can now benefit from what has been developed so far. Moreover, multiple services can run in parallel on a single machine.

For deployment, Archipel uses Docker and DappNode Package first. DappNode is a software and hardware to promote decentralized infrastructure, installed at home or anywhere else, to launch blockchain nodes or services and #serve yourself.

Why decentralized infrastructure first? Anticipate future GAFA blockchain service bans, for any good reasons, for any powerful establishment?

In this article, we will present a multi-services example with Trustlines Network Node and Centrifuge Node operation.

More info at Archipel 2.0 blog post.

What is Trustlines Network

The Trustlines Network ecosystem aims to promote the financial & economic inclusion of all people through decentralized and open source systems. The Trustlines Protocol is being built to support a range of use cases by leveraging existing networks of mutual trust and mapping trust-based relationships onto trustless infrastructure.

More info at https://trustlines.network/

What is Centrifuge

Centrifuge is a protocol for decentralized asset finance. Asset Originators can access bankless liquidity, and investors can earn attractive yields from an open marketplace of asset pools.

More info at https://centrifuge.io/

Archipel multi-services Feature

Archipel DAppNode Package Configuration

In the DappNode Package config panel, you can now choose a list of services. These services will be launched in parallel on your hardware. For our example, we select: “centrifuge,trustlines”.

If you have several DappNode hardwares and want to create an unsinkable cluster to assure High Availability of the service. You can switch the ‘Archipel Mode’ to ‘orchestrator’.

Cluster config ( Peers ids, Wirguard VPN configs, etc …) can be generated with archipel-cli. It generates a global zip file. This zip file has to be uploaded on each DAppNode instance. In the configuration tab, you select the appropriate number, 1 to n, identifying your instance number in the federation (aka cluster).

If you use only 1 machine or if you want to force your instance to operate in a specific mode, you can set ‘active’ or ‘passive’ mode instead of ’orchestrator’. ‘active’ mode means leader, in our cases for Centrifuge and Trustlines nodes, it means validator node of the blockchain.

You also need to fill some system environment parameters according to each service’s requirements: docker images to target, optional commands line for the service, wallets address to use, etc … You may also need to load files in Docker shared volumes keystore files for nodes, for instance. You can load these files using the “File Manager” tab of the DappNode web interface.

DAppNode Package Config to launch Centrifuge and Trustlines services

What will happen when the Archipel DappNode Package starts?

  • Your instance launches an Archipel node and connects to the Archipel chain. Archipel chain is used to share federation states, heartbeats, and transactional decisions between all instances in order to elect a leader.
  • The orchestrator component launches Trustlines Node and Centrifuge Node. In the schema example below of 4 instances, there is only one leader and 3 passive instances. Passive instances only sync the network as full nodes. The leader instance runs nodes in validator mode, for both, Centrifuge and Trustlines.

If your active instance crashes, has a power/network issue, another instance takes the leadership and restarts services in active mode, from full node to validator node.

Cluster example using 4 DAppNode instances

In Archipel Package logs you see the orchestrator starting Centrifuge node and Trustlines node in our case :

Archipel orchestrator launch trustlines and centrifuge nodes

In your machine, if you list docker containers, you see your Archipel container supervising 2 other docker containers: ‘trustines-validator’ and ‘centrifuge validator’. In these containers, you find your usual node logs for each service.

Archipel, Trustines, Centrifuge docker containers

Conclusion

Archipel solution uses the Substrate babe/Granda consensus chain to operate properly. As you need 2/3 of nodes up and running to finalized consensus, it means, to tolerate one node down, you need at least 4 instances for your automatic smart high-availability to work. 4 instances, is a lot for only one service operation. But now, with the multi-service feature, you need at least 4 instances for running many services in parallel. It is entirely reasonable!

The more you add instances in the cluster, the more you tolerate servers down. Choose your number of hardware instances and how many services to run on each that suit your cost/benefit/security infrastructure requirements!

About us

We are 2 open source develop-found-ers at Lugus Labs.

You can follow our updates on Twitter.

Like what we are doing? You can support us by nominating our 3 Polkadot validators.

--

--