### Starting Fablo Hyperledger Fabric Network (Fablo CLI) Source: https://github.com/hyperledger-labs/fablo/blob/main/samples/gateway/node/README.md Initializes and starts a Hyperledger Fabric network using Fablo, based on a provided configuration file. This command provisions organizations, peers, and chaincode. ```Shell fablo up samples/fablo-config-hlf3-1orgs-1chaincode.json ``` -------------------------------- ### Installing Node.js Gateway Dependencies (npm) Source: https://github.com/hyperledger-labs/fablo/blob/main/samples/gateway/node/README.md Installs all required Node.js packages and dependencies for the gateway application, as specified in its 'package.json' file. ```Shell npm i ``` -------------------------------- ### Starting Node.js Gateway Server (Node.js) Source: https://github.com/hyperledger-labs/fablo/blob/main/samples/gateway/node/README.md Launches the Node.js gateway server, loading environment variables from the '.env' file. This server interacts with the deployed Hyperledger Fabric network. ```Shell node --env-file=.env server.js ``` -------------------------------- ### Copying Environment Example File (Shell) Source: https://github.com/hyperledger-labs/fablo/blob/main/samples/gateway/node/README.md Duplicates the example environment configuration file ('.env.example') to a usable '.env' file, which will contain sensitive or environment-specific variables. ```Shell cp .env.example .env ``` -------------------------------- ### Starting Hyperledger Fabric Network with Custom Configuration (Bash) Source: https://github.com/hyperledger-labs/fablo/blob/main/README.md This command starts a Hyperledger Fabric network using a specified Fablo configuration file. It creates the initial network setup and brings up all necessary Docker containers, allowing for custom network topologies and chaincode deployments. ```bash fablo up /path/to/fablo-config.json ``` -------------------------------- ### Initializing and Starting a Hyperledger Fabric Network with Fablo (Bash) Source: https://github.com/hyperledger-labs/fablo/blob/main/README.md These commands initialize a new Fablo configuration for a Hyperledger Fabric network, including Node.js chaincode and a REST API client, then start the network. The first command prepares the configuration, and the second brings up all the Docker containers for the network components. ```bash fablo init node rest # if installed globally # or ./fablo init node rest # if using local script ./fablo up ``` -------------------------------- ### Fablo Up Command Syntax (Bash) Source: https://github.com/hyperledger-labs/fablo/blob/main/README.md This command starts the Hyperledger Fabric network defined by a Fablo configuration file. It handles the creation of channels, installation, and instantiation of chaincodes, effectively bringing the entire blockchain network online. If no configuration exists, it will first call the `generate` command. ```bash fablo up [/path/to/fablo-config.json|yaml] ``` -------------------------------- ### Navigating to Fablo Directory (Shell) Source: https://github.com/hyperledger-labs/fablo/blob/main/samples/gateway/node/README.md Changes the current directory to the newly cloned Fablo repository, preparing for subsequent Fablo commands. ```Shell cd fablo ``` -------------------------------- ### Navigating to Node.js Gateway Sample Directory (Shell) Source: https://github.com/hyperledger-labs/fablo/blob/main/samples/gateway/node/README.md Changes the current directory to the Node.js gateway sample within the Fablo repository, where the application code resides. ```Shell cd samples/gateway/node ``` -------------------------------- ### Starting Node.js Chaincode in Watch Dev Mode Source: https://github.com/hyperledger-labs/fablo/blob/main/README.md This command navigates into the sample Node.js chaincode directory, ensures the correct Node.js version is used with `nvm`, installs dependencies, and then starts the chaincode in watch mode. This enables automatic refreshing of the chaincode on the Hyperledger Fabric Network upon source code changes, facilitating rapid development. ```bash (cd chaincodes/chaincode-kv-node && nvm use && npm i && npm run start:watch) ``` -------------------------------- ### Cloning Fablo Repository (Git) Source: https://github.com/hyperledger-labs/fablo/blob/main/samples/gateway/node/README.md Clones the Fablo repository from GitHub, which contains the necessary tools and samples for setting up Hyperledger Fabric networks. ```Shell git clone https://github.com/hyperledger-labs/fablo.git ``` -------------------------------- ### Installing Fablo Globally (Bash) Source: https://github.com/hyperledger-labs/fablo/blob/main/README.md This command downloads the Fablo shell script from its GitHub releases and installs it globally on the system, making it accessible from any directory. It uses `sudo` to write to `/usr/local/bin` and makes the script executable. ```bash sudo curl -Lf https://github.com/hyperledger-labs/fablo/releases/download/2.2.0/fablo.sh -o /usr/local/bin/fablo && sudo chmod +x /usr/local/bin/fablo ``` -------------------------------- ### Installing All Chaincodes with Fablo Source: https://github.com/hyperledger-labs/fablo/blob/main/README.md This command installs all chaincodes defined in the Fablo configuration. It is useful as a fallback if Fablo's automatic chaincode deployment encounters issues. ```Bash fablo chaincodes install ``` -------------------------------- ### Installing a Specific Chaincode with Fablo Source: https://github.com/hyperledger-labs/fablo/blob/main/README.md This command allows for the installation of a single chaincode by specifying its name and version, as defined in the Fablo config file. ```Bash fablo chaincode install ``` -------------------------------- ### Installing Fablo Locally for a Project (Bash) Source: https://github.com/hyperledger-labs/fablo/blob/main/README.md This command downloads the Fablo shell script into the current project's root directory. It makes the script executable, allowing it to be run locally without global installation, ideal for project-specific configurations. ```bash curl -Lf https://github.com/hyperledger-labs/fablo/releases/download/2.2.0/fablo.sh -o ./fablo && chmod +x ./fablo ``` -------------------------------- ### Loading Sample Data into JSONEditor (JavaScript) Source: https://github.com/hyperledger-labs/fablo/blob/main/docs/editor.html This snippet fetches 'sample.json' using the Fetch API, parses the JSON response, and then sets the editor's value with the loaded data. This populates the editor with initial configuration values, providing a starting point for user interaction. ```javascript fetch('sample.json') .then(resp => resp.json()) .then(json => { editor.setValue(json); }); ``` -------------------------------- ### Example Fablo Global Configuration Settings Source: https://github.com/hyperledger-labs/fablo/blob/main/README.md This JSON snippet provides an example of the `global` section within a Fablo configuration file. It defines network-wide settings such as `fabricVersion`, `tls` enablement, `peerDevMode` status, `monitoring` log level, and `tools` like explorer, influencing the overall behavior of the deployed Hyperledger Fabric network. ```json "global": { "fabricVersion": "2.4.2", "tls": false, "peerDevMode": false, "monitoring": { "loglevel": "debug" }, "tools": { "explorer": false } }, ``` -------------------------------- ### Node.js Chaincode Dev Mode `package.json` Scripts Source: https://github.com/hyperledger-labs/fablo/blob/main/README.md These `npm` scripts define how the Node.js chaincode runs in development mode. `start:dev` directly starts the chaincode node, specifying the peer address, chaincode ID, and disabling TLS. `start:watch` uses `nodemon` to automatically restart `start:dev` whenever source files change, enabling hot reloading during development. ```json "scripts": { ... "start:dev": "fabric-chaincode-node start --peer.address \"127.0.0.1:8541\" --chaincode-id-name \"chaincode1:0.0.1\" --tls.enabled false", "start:watch": "nodemon --exec \"npm run start:dev\"", ... }, ``` -------------------------------- ### Displaying Fablo Version Information Source: https://github.com/hyperledger-labs/fablo/blob/main/README.md This command prints the currently installed Fablo version. Using the optional `--verbose` or `-v` flag will also display the supported Fablo and Hyperledger Fabric versions, providing more detailed environment compatibility information. ```bash fablo version [--verbose | -v] ``` -------------------------------- ### Sample Chaincode Invocation with Fablo Source: https://github.com/hyperledger-labs/fablo/blob/main/README.md This is an example of invoking a chaincode function named `put` on `chaincode1` within `my-channel1` on `peer0.org1.example.com`. It demonstrates passing arguments to the `KVContract` to store a key-value pair. ```Bash fablo chaincode invoke "peer0.org1.example.com" "my-channel1" "chaincode1" '{"Args":["KVContract:put", "name", "Willy Wonka"]}' ``` -------------------------------- ### Listing Chaincodes with Fablo Source: https://github.com/hyperledger-labs/fablo/blob/main/README.md This command retrieves a list of instantiated or installed chaincodes on a specified peer or within a particular channel, providing visibility into deployed chaincodes. ```Bash fablo chaincodes list ``` -------------------------------- ### Listing Channels for a Specific Peer Source: https://github.com/hyperledger-labs/fablo/blob/main/README.md This command lists all channels that are joined by a specified peer within a given organization. The example shows listing channels for `peer0` of `org1`. ```bash fablo channel list org1 peer0 ``` -------------------------------- ### Example DCO Signed-off Commit Message Source: https://github.com/hyperledger-labs/fablo/blob/main/CONTRIBUTING.md Illustrates the required format for a commit message that includes a 'Signed-off-by' line, certifying adherence to the Developer Certificate of Origin (DCO) for contributions. ```text This is my commit message Signed-off-by: John Doe ``` -------------------------------- ### Restoring Hyperledger Fabric Network State with Fablo Source: https://github.com/hyperledger-labs/fablo/blob/main/README.md This command restores a previously created network snapshot into the current directory. Before restoring, any existing network must be pruned to avoid conflicts, and after restoration, the network needs to be started. ```Bash fablo restore ``` -------------------------------- ### Fablo Generate Command Syntax (Bash) Source: https://github.com/hyperledger-labs/fablo/blob/main/README.md This command generates all necessary network configuration files for Hyperledger Fabric based on a specified Fablo configuration file (JSON or YAML). It can output these files to a custom target directory, allowing users to version control or manually tweak the generated setup. ```bash fablo generate [/path/to/fablo-config.json|yaml [/path/to/fablo/target]] ``` -------------------------------- ### Managing Hyperledger Fabric Network Lifecycle with Fablo Source: https://github.com/hyperledger-labs/fablo/blob/main/README.md This command allows users to control the lifecycle of a Hyperledger Fabric network configured in the current directory, similar to Docker Compose commands. It can be used to bring the network down, start it up, or stop its operations. ```Bash fablo [down | start | stop] ``` -------------------------------- ### Defining Post-Generation Hooks in Fablo Source: https://github.com/hyperledger-labs/fablo/blob/main/README.md This snippet shows how to define postGenerate hooks in Fablo, which are Bash commands executed after the network configuration is generated (e.g., after ./fablo generate or ./fablo up). The example demonstrates modifying MaxMessageCount in configtx.yaml. Hooks are saved in fablo-target/hooks. ```json "hooks": { "postGenerate": "perl -i -pe 's/MaxMessageCount: 10/MaxMessageCount: 1/g' \"./fablo-target/fabric-config/configtx.yaml\"" } ``` -------------------------------- ### Executing Unit Tests with npm Source: https://github.com/hyperledger-labs/fablo/blob/main/CONTRIBUTING.md Command to run unit tests for the project, ensuring that individual components function correctly after changes. This is part of the testing phase before submitting contributions. ```shell npm run test:unit ``` -------------------------------- ### Building Fablo Docker Image Locally Source: https://github.com/hyperledger-labs/fablo/blob/main/CONTRIBUTING.md Script to build a local Docker image for Fablo, necessary for verifying changes by running Fablo in a local environment. This prepares the environment for local testing. ```shell ./fablo-build.sh ``` -------------------------------- ### Calling Fablo Commands Locally Source: https://github.com/hyperledger-labs/fablo/blob/main/CONTRIBUTING.md Script to execute Fablo commands from the source root directory, allowing developers to interact with the locally built Fablo instance and test its functionality. ```shell ./fablo.sh ``` -------------------------------- ### Fablo Init Command Syntax (Bash) Source: https://github.com/hyperledger-labs/fablo/blob/main/README.md This command creates a basic Fablo network configuration file in the current directory. It supports optional parameters to include a sample Node.js chaincode (`node`), enable a REST API client (`rest`), or run peers in development mode (`dev`) for hot reloading. ```bash fablo init [node] [rest] [dev] ``` -------------------------------- ### Executing End-to-End Tests with npm Source: https://github.com/hyperledger-labs/fablo/blob/main/CONTRIBUTING.md Command to run end-to-end (E2E) tests, verifying the entire application flow from a user's perspective. This helps ensure that integrated components work together as expected. ```shell npm run test:e2e ``` -------------------------------- ### Creating a Snapshot of Hyperledger Fabric Network State with Fablo Source: https://github.com/hyperledger-labs/fablo/blob/main/README.md This command creates a snapshot (backup) of the Hyperledger Fabric network's current state, including artifacts, certificates, and node data. The snapshot does not include the Fablo config file or chaincode source code, and the network does not need to be stopped beforehand. ```Bash fablo snapshot ``` -------------------------------- ### Listing Available Fablo Versions Source: https://github.com/hyperledger-labs/fablo/blob/main/README.md This command lists all Fablo versions that are available for use. It helps users identify which versions can be switched to for different project requirements or compatibility needs. ```bash fablo use ``` -------------------------------- ### Initializing Fablo with Node.js Chaincode and Dev Mode (Bash) Source: https://github.com/hyperledger-labs/fablo/blob/main/README.md This command initializes a Fablo configuration that includes a sample Node.js chaincode and sets up peers in development mode. Development mode allows for hot reloading of chaincode, which is useful during development and testing. ```bash fablo init node dev ``` -------------------------------- ### Fablo 'up' Command Sequence Diagram Source: https://github.com/hyperledger-labs/fablo/blob/main/ARCHITECTURE.md This Mermaid sequence diagram illustrates the flow of the `fablo.sh up` command. It shows the interaction between the user, `fablo.sh` script, Fablo Docker container, and the `fablo-target` directory, including the conditional generation of network files. ```Mermaid sequenceDiagram actor User User ->> fablo.sh: Call `up` command fablo.sh ->> fablo-target: Verify if network files
are generated alt no network files fablo.sh ->> Fablo Docker: Generate network files Fablo Docker ->> fablo-target: Generate network files
from `fablo-config.json`
and templates (Yeoman) end fablo.sh ->> fablo-target: Call `up` command ``` -------------------------------- ### Displaying Fablo Channel Command Help Source: https://github.com/hyperledger-labs/fablo/blob/main/README.md This command displays a list of all available `fablo channel` subcommands. These commands are dynamically generated based on the `fablo-config.json` file to provide specific queries for each channel, organization, and peer defined in the network configuration. ```bash fablo channel --help ``` -------------------------------- ### Recreating Hyperledger Fabric Network with Fablo Source: https://github.com/hyperledger-labs/fablo/blob/main/README.md The `recreate` command performs a prune, generates new configuration files, and then brings up the network. This is particularly useful after modifying the `fablo-config` file and wanting to deploy a new version of the network in one command. ```Bash fablo recreate [/path/to/fablo-config.json|yaml] ``` -------------------------------- ### Sample Fablo Network Configuration in YAML Source: https://github.com/hyperledger-labs/fablo/blob/main/README.md This YAML configuration defines a Hyperledger Fabric network using Fablo. It specifies global settings like Fabric version and TLS, sets up multiple organizations (Orderer, Org1, Org2) with their domains and peer instances, defines a channel 'my-channel1' with participating organizations, and configures a Node.js chaincode 'and-policy-chaincode' with an endorsement policy and private data collection. ```yaml --- "$schema": https://github.com/hyperledger-labs/fablo/releases/download/2.2.0/schema.json global: fabricVersion: 2.4.2 tls: false orgs: - organization: name: Orderer domain: root.com orderers: - groupName: group1 prefix: orderer type: solo instances: 1 - organization: name: Org1 domain: org1.example.com tools: fabloRest: true explorer: true peer: instances: 2 - organization: name: Org2 domain: org2.example.com peer: instances: 1 channels: - name: my-channel1 orgs: - name: Org1 peers: - peer0 - peer1 - name: Org2 peers: - peer0 chaincodes: - name: and-policy-chaincode version: 0.0.1 lang: node channel: my-channel1 init: '{"Args":[]}' endorsement: AND('Org1MSP.member', 'Org2MSP.member') directory: "./chaincodes/chaincode-kv-node" privateData: - name: org1-collection orgNames: - Org1 ``` -------------------------------- ### Updating E2E Test Snapshots with npm Source: https://github.com/hyperledger-labs/fablo/blob/main/CONTRIBUTING.md Command used to update E2E test snapshots, particularly relevant when template changes or other modifications affect expected output. This ensures tests reflect the new valid state. ```shell npm run test:e2e-update ``` -------------------------------- ### Pushing Changes to Forked Repository Source: https://github.com/hyperledger-labs/fablo/blob/main/CONTRIBUTING.md Command to push local changes from a specific branch to the contributor's forked GitHub repository. This is the first step in submitting changes for review via a pull request. ```shell git push origin [branch-name] ``` -------------------------------- ### Initializing JSONEditor Instance (JavaScript) Source: https://github.com/hyperledger-labs/fablo/blob/main/docs/editor.html This code initializes a new JSONEditor instance, attaching it to an HTML element with the ID 'editor_holder'. It enables AJAX for schema fetching and specifies 'schema.json' as the primary schema, formatted as a grid, to define the editor's structure and validation rules. ```javascript // Initialize the editor const editor = new JSONEditor(document.getElementById('editor_holder'), { // Enable fetching schemas via ajax ajax: true, // The schema for the editor schema: { $ref: "schema.json", format: "grid" } }); ``` -------------------------------- ### Understanding Git Sign-off Option Source: https://github.com/hyperledger-labs/fablo/blob/main/CONTRIBUTING.md Shows the help output for the `git commit -s` (or `--signoff`) option, explaining its purpose to add a 'Signed-off-by' line to the commit log message, typically certifying DCO adherence. ```text -s, --signoff Add Signed-off-by line by the committer at the end of the commit log message. The meaning of a signoff depends on the project, but it typically certifies that committer has the rights to submit this work under the same license and agrees to a Developer Certificate of Origin (see http://developercertificate.org/ for more information). ``` -------------------------------- ### Configuring Chaincodes in Fablo Source: https://github.com/hyperledger-labs/fablo/blob/main/README.md This snippet demonstrates how to configure chaincodes for deployment on channels. It specifies the chaincode name, version, language (golang, java, or node), the channel it belongs to, its directory, and optional privateData collection details. It also covers init, initRequired, and endorsement parameters for different Fabric versions. ```json "chaincodes": [ { "name": "chaincode1", "version": "0.0.1", "lang": "node", "channel": "my-channel1", "directory": "./chaincodes/chaincode-kv-node", "privateData": { "name": "org1-collection", "orgNames": ["Org1"] } }, { "name": "chaincode2", "version": "0.0.1", "lang": "java", "channel": "my-channel2" } ] ``` -------------------------------- ### Basic Fablo Configuration File Structure Source: https://github.com/hyperledger-labs/fablo/blob/main/README.md This JSON snippet illustrates the basic top-level structure of a Fablo configuration file. It includes a `$schema` for validation, and sections for `global` settings, `orgs` (organizations), `channels`, and `chaincodes`, defining the Hyperledger Fabric network topology. ```json { "$schema": "https://github.com/hyperledger-labs/fablo/releases/download/2.2.0/schema.json", "global": { ... }, "orgs": [ ... ], "channels": [ ... ], "chaincodes": [ ... ] } ``` -------------------------------- ### Fetching and Decoding Channel Config Block Source: https://github.com/hyperledger-labs/fablo/blob/main/README.md This command fetches the latest configuration block for a specified channel, decodes its content, and writes it to a JSON file. Optional `file_name.json` allows specifying the output file; otherwise, it defaults to a standard name. ```bash fablo channel fetch config channel_name org1 peer0 [file_name.json] ``` -------------------------------- ### Fetching Raw Channel Blocks Source: https://github.com/hyperledger-labs/fablo/blob/main/README.md This command fetches a raw block from a specified channel. Users can choose to fetch the `oldest`, `newest`, or a block by its specific `block-number`. The fetched block is then written to a file, with an optional `file_name.json` parameter for the output file. ```bash fablo channel fetch channel_name org1 peer0 [file_name.json] ``` -------------------------------- ### Switching to a Specific Fablo Version Source: https://github.com/hyperledger-labs/fablo/blob/main/README.md This command allows users to switch the current Fablo script to a specified version number. This is useful for managing different project environments or testing against specific Fablo releases. ```bash fablo use ``` -------------------------------- ### Validating Hyperledger Fabric Network Configuration with Fablo Source: https://github.com/hyperledger-labs/fablo/blob/main/README.md This command validates the network configuration file, providing suggestions for necessary changes or additional tweaks. It is automatically executed before each `generate` command to ensure critical errors are addressed. ```Bash fablo validate [/path/to/fablo-config.json|yaml] ``` -------------------------------- ### Configuring Organizations (orgs) in Fablo Source: https://github.com/hyperledger-labs/fablo/blob/main/README.md This snippet defines how to configure organizations within a Hyperledger Fabric network using Fablo. It specifies organization name, domain, peer instances, database type, orderer groups, and optional tools like Fablo REST and Blockchain Explorer. It also details other available parameters like mspName, ca.prefix, ca.db, peer.prefix, peer.anchorPeerInstances, orderers, tools.explorer, and tools.fabloRest, along with peer.db and orderers.type options. ```json "orgs": [ { "organization": { "name": "Org1", "domain": "org1.example.com" }, "peer": { "instances": 2, "db": "LevelDb" }, "orderers": [{ "groupName": "group1", "type": "raft", "instances": 3 }], "tools": { "fabloRest": true, "explorer": true } }, ... ], ``` -------------------------------- ### Resetting Hyperledger Fabric Network with Fablo Source: https://github.com/hyperledger-labs/fablo/blob/main/README.md The `reset` command combines the down and up steps, effectively restarting the network. It causes the loss of network state but preserves the configuration, making it useful for obtaining a fresh network instance without existing data. ```Bash fablo reset ``` -------------------------------- ### Setting Global JSONEditor Defaults (JavaScript) Source: https://github.com/hyperledger-labs/fablo/blob/main/docs/editor.html This snippet configures the default theme and icon library for the JSONEditor instance globally, ensuring a consistent look and feel across all editor instances. It sets the theme to 'html' and the icon library to 'fontawesome5'. ```javascript JSONEditor.defaults.theme = 'html'; JSONEditor.defaults.iconlib = 'fontawesome5'; ``` -------------------------------- ### Retrieving Channel Information for a Peer Source: https://github.com/hyperledger-labs/fablo/blob/main/README.md This command prints detailed information about a specified channel, such as its current block height, as seen from a particular peer. The parameters include the `channel_name`, `org` name, and `peer` name. ```bash fablo channel getinfo channel_name org1 peer0 ``` -------------------------------- ### Upgrading a Chaincode with Fablo Source: https://github.com/hyperledger-labs/fablo/blob/main/README.md This command upgrades a specified chaincode to a new version across all relevant peers. The chaincode's directory is determined by the Fablo config file. ```Bash fablo chaincode upgrade ``` -------------------------------- ### Pruning Hyperledger Fabric Network with Fablo Source: https://github.com/hyperledger-labs/fablo/blob/main/README.md This command downs the Hyperledger Fabric network and completely removes the `fablo-target` directory, effectively cleaning up all generated network artifacts and data. ```Bash fablo prune ``` -------------------------------- ### Handling JSONEditor Change Events for Validation (JavaScript) Source: https://github.com/hyperledger-labs/fablo/blob/main/docs/editor.html This code registers a 'change' event listener on the JSONEditor instance. Whenever the editor's content changes, it validates the input against the schema and logs any detected errors to the console, providing real-time feedback on the validity of the configuration. ```javascript // Hook up the validation indicator to update its // status whenever the editor changes editor.on('change', function () { // Get an array of errors from the validator const errors = editor.validate(); console.log(errors) // Not valid if (errors.length) { errors.forEach(err => { console.error(err); }) } }); ``` -------------------------------- ### Fablo Config Editor CSS Styling Source: https://github.com/hyperledger-labs/fablo/blob/main/docs/editor.html This CSS block defines the visual styles for the Fablo config editor, including general box-sizing, font families, heading sizes, and specific styles for form controls, buttons, and input fields to enhance user interface consistency and readability. ```css * { box-sizing: border-box; } body { font-family: 'Roboto', sans-serif; /*background: #d6e8f0;*/ color: #333333; } h1, h2, h3, h4 { font-weight: 300; } h1 { font-size: 3em; } h2 { font-size: 2em; } h3 { font-size: 1.5em; } .je-indented-panel { /*background: rgba(128, 128, 128, 0.05);*/ /*padding: 20px 10px;*/ } .container { max-width: 960px; margin: 100px auto } .form-control { margin: 10px 10px 10px 13px; } button { border-radius: 3px; height: 22px; line-height: 1em; vertical-align: middle; margin-right: 2px; background: #e9f4ff; } button.json-editor-btn-collapse { border-radius: 10em; width: 22px; } .form-control label { font-weight: bold; display: inline-block; width: 200px; } p { font-weight: 300; font-size: 0.85em; width: 648px; margin: -20px 0 -28px 8px; padding: 0 0 28px 0px; } p.je-form-input-label, .errmsg { font-weight: 300; font-size: 0.85em; width: 400px; margin: 0 0 0 200px; border: none; padding: 5px 10px; } input, select, textarea { width: 400px; border: 1px #ccc solid; border-radius: 0.25em; padding: 5px 10px; font-size: 12pt; } input[readonly] { color: #888888; background: #f0f0f0; } .je-child-editor-holder > span, .je-indented-panel > span { margin: 10px 0 0 0; display: inline-block; } .property-selector label { font-weight: normal; font-size: 10pt; } textarea { font-family: monospace; font-size: 8pt; } ``` -------------------------------- ### Defining Channels in Fablo Source: https://github.com/hyperledger-labs/fablo/blob/main/README.md This snippet illustrates how to define channels in the Fablo configuration. It includes the channel name, an optional groupName for orderer association, and a list of organizations with their respective peers participating in the channel. The groupName defaults to the first orderer group found if not specified. ```json "channels": [ { "name": "my-channel1", "groupName": "group1", "orgs": [ { "name": "Org1", "peers": [ "peer0", "peer1" ] }, { "name": "Org2", "peers": [ "peer0" ] } ] }, ... ], ``` -------------------------------- ### Invoking a Chaincode Function with Fablo Source: https://github.com/hyperledger-labs/fablo/blob/main/README.md This command invokes a function on a specified chaincode with given parameters. It requires the target peers' domains, channel name, chaincode name, and the command (function and arguments) to be executed. ```Bash fablo chaincode invoke [transient] ``` === COMPLETE CONTENT === This response contains all available snippets from this library. No additional content exists. Do not make further requests.