Skip to content

Deploy Fabric Network using Operator

Introduction

The bevel-operator-fabric provides a different approach to deploying the Fabric Network. It uses the kubernetes operator to deploy CAs, Orderers and Peers. This release supports bevel-operator-fabric version 1.9.0 and all the Fabric platforms supported by it. Also, chaincode and user/certificate management is not yet supported, there will be separate issues to handle this. Current implementation supports till Channel creation and joining.

Due to open issues with bevel-operator-fabric, it is not recommended for Production workloads yet.


NOTE: The bevel-operator-fabric deployment has been tested only for Fabric 2.5.3


Modifying Configuration File

A Sample configuration file for deploying using bevel-operator-fabric is available here. Following are the main changes in this file from previous versions:

  1. network.env.type must be operator. This is how Ansible will understand that bevel-operator-fabric will be used.
  2. network.env.proxy must be istio as no other proxy is supported by bevel-operator-fabric.
  3. Only 443 is supported as external port because that is what bevel-operator-fabric supports.
  4. vault and gitops sections are removed as they are not applicable.
# yaml-language-server: $schema=../../../../platforms/network-schema.json
# This is a sample configuration file for setting up initial Fabric network with 1 RAFT Orderer and 5 Nodes.
network:
  # Network level configuration specifies the attributes required for each organization
  # to join an existing network.
  type: fabric
  version: 2.5.3                 # currently tested on 2.5.3

  #Environment section for Kubernetes setup
  env:
    type: "operator"          # Do not change this for using 'bevel-operator-fabric'. Any other value will trigger Flux based deployment
    proxy: istio              # values can be 'istio' only. No other proxy is supported at the moment
    retry_count: 20           # Retry count for the checks
    external_dns: enabled     # Should be enabled if using external-dns for automatic route configuration
    ..
    .. 

For generic instructions on the Fabric configuration file, refer this guide.

Run playbook

After all the configurations are updated in the network.yaml, execute the following to create the DLT network

# Run the provisioning scripts
ansible-playbook platforms/shared/configuration/site.yaml -e "@./build/network.yaml" 
The site.yaml playbook, in turn calls various playbooks depending on the configuration file and sets up your DLT/Blockchain network.

The deploy-operator-network.yaml playbook can be used as well if the pre-requisites like Istio and krew is already installed. This can be done using the following command

ansible-playbook platforms/hyperledger-fabric/configuration/deploy-operator-network.yaml -e "@/path/to/network.yaml"

Refer to bevel-operator-fabric docs for details the operator and latest releases.