Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
231 changes: 76 additions & 155 deletions CHANGELOG.md

Large diffs are not rendered by default.

8 changes: 4 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,13 +25,13 @@ You can keep the script in the root directory of your project or install it glob
To get a copy of Fablo for a single project, run this command in your project root:

```bash
curl -Lf https://github.com/hyperledger-labs/fablo/releases/download/2.4.1/fablo.sh -o ./fablo && chmod +x ./fablo
curl -Lf https://github.com/hyperledger-labs/fablo/releases/download/2.4.2/fablo.sh -o ./fablo && chmod +x ./fablo
```

To install it globally, run:

```bash
sudo curl -Lf https://github.com/hyperledger-labs/fablo/releases/download/2.4.1/fablo.sh -o /usr/local/bin/fablo && sudo chmod +x /usr/local/bin/fablo
sudo curl -Lf https://github.com/hyperledger-labs/fablo/releases/download/2.4.2/fablo.sh -o /usr/local/bin/fablo && sudo chmod +x /usr/local/bin/fablo
```

## Getting started
Expand Down Expand Up @@ -441,7 +441,7 @@ The basic structure of Fablo config file is as follows:

```json
{
"$schema": "https://github.com/hyperledger-labs/fablo/releases/download/2.4.1/schema.json",
"$schema": "https://github.com/hyperledger-labs/fablo/releases/download/2.4.2/schema.json",
"global": { ... },
"orgs": [ ... ],
"channels": [ ... ],
Expand Down Expand Up @@ -618,7 +618,7 @@ Generated hooks are saved in `fablo-target/hooks`.

```yaml
---
"$schema": https://github.com/hyperledger-labs/fablo/releases/download/2.4.1/schema.json
"$schema": https://github.com/hyperledger-labs/fablo/releases/download/2.4.2/schema.json
global:
fabricVersion: 2.4.2
tls: false
Expand Down
2 changes: 1 addition & 1 deletion docs/sample.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"$schema": "https://github.com/hyperledger-labs/fablo/releases/download/2.4.1/schema.json",
"$schema": "https://github.com/hyperledger-labs/fablo/releases/download/2.4.2/schema.json",
"global": {
"fabricVersion": "2.3.2",
"tls": false,
Expand Down
2 changes: 1 addition & 1 deletion docs/schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
],
"properties": {
"$schema": {
"const": "https://github.com/hyperledger-labs/fablo/releases/download/2.4.1/schema.json"
"const": "https://github.com/hyperledger-labs/fablo/releases/download/2.4.2/schema.json"
},
"global": {
"$id": "#/properties/global",
Expand Down
5 changes: 1 addition & 4 deletions e2e-network/docker/test-01-v3-simple.sh
Original file line number Diff line number Diff line change
Expand Up @@ -124,7 +124,4 @@ expectInvoke "peer0.org1.example.com" "my-channel1" "chaincode1" \
# Test export-network-topology to Mermaid
cp -f "$FABLO_HOME/samples/fablo-config-hlf2-1org-1chaincode.json" "$TEST_TMP/simple-config.json"
(cd "$TEST_TMP" && "$FABLO_HOME/fablo.sh" export-network-topology simple-config.json simple-network-topology.mmd)
expectCommand "head -n 1 \"$TEST_TMP/simple-network-topology.mmd\"" "graph TD"
expectCommand "cat \"$TEST_TMP/simple-network-topology.mmd\"" "Org_Orderer"
expectCommand "cat \"$TEST_TMP/simple-network-topology.mmd\"" "Org_Org1"
expectCommand "cat \"$TEST_TMP/simple-network-topology.mmd\"" "Channel_my_channel1"
expectCommand "cat \"$TEST_TMP/simple-network-topology.mmd\"" "graph LR"
2 changes: 1 addition & 1 deletion e2e-network/docker/test-04-v3-snapshot-ccaas.sh
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,7 @@ hook_command="perl -i -pe 's/FABRIC_VERSION=2\.3\.3/FABRIC_VERSION=2\.4\.2/g' ./

waitForChaincode "peer0.org1.example.com" "my-channel1" "chaincode1" "0.0.1"

sleep 5
sleep 10

user_token_response="$(expectCARest "$fablo_rest_org1/user/enroll" '' '{"id": "gordon", "secret": "gordonpw"}' 'token')"
echo "$user_token_response"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

exports[`samples/fablo-config-hlf2-1org-1chaincode-k8s.json should create proper e2e/__tmp__/samples/fablo-config-hlf2-1org-1chaincode-k8s.json.tmpdir/fablo-target/fablo-config.json from samples/fablo-config-hlf2-1org-1chaincode-k8s.json 1`] = `
"{
"$schema": "https://github.com/hyperledger-labs/fablo/releases/download/2.4.1/schema.json",
"$schema": "https://github.com/hyperledger-labs/fablo/releases/download/2.4.2/schema.json",
"global": {
"fabricVersion": "2.4.7",
"tls": false,
Expand Down Expand Up @@ -146,7 +146,7 @@ exports[`samples/fablo-config-hlf2-1org-1chaincode-k8s.json should create proper
REPOSITORY="https://kfsoftware.github.io/hlf-helm-charts"
STORAGE_CLASS=$(kubectl describe sc | grep Name | tr -s ' ' | cut -d ':' -f 2 | cut -d ' ' -f 2)

FABLO_VERSION=2.4.1
FABLO_VERSION=2.4.2
FABLO_BUILD=<date with git hash>
FABLO_CONFIG=<absolute path>
ORDERER_IMAGE=hyperledger/fabric-orderer
Expand Down Expand Up @@ -556,28 +556,46 @@ echo "Executing post-start hook"
`;

exports[`samples/fablo-config-hlf2-1org-1chaincode-k8s.json should create proper e2e/__tmp__/samples/fablo-config-hlf2-1org-1chaincode-k8s.json.tmpdir/fablo-target/network-topology.mmd from samples/fablo-config-hlf2-1org-1chaincode-k8s.json 1`] = `
"graph TD

subgraph Org_Orderer [Org: Orderer]
CA_ca_Orderer[CA: ca_Orderer - sqlite]
"graph LR

classDef subgraph_padding fill:none,stroke:none

subgraph orderer_example_com [Organization: Orderer<br>orderer.example.com]
subgraph orderer_example_com_padding [ ]
direction RL
subgraph ord_group_group1_orderer0_group1_orderer_example_com [Orderer Group: group1<br>solo]
subgraph ord_group_group1_orderer0_group1_orderer_example_com_padding [ ]
direction RL
orderer0_group1_orderer_example_com[orderer0.group1.orderer.example.com]
end
class ord_group_group1_orderer0_group1_orderer_example_com_padding subgraph_padding
end
ca_orderer_example_com([ca.orderer.example.com<br>sqlite])
end
class orderer_example_com_padding subgraph_padding
end

subgraph Org_Org1 [Org: Org1]
CA_ca_Org1[CA: ca_Org1 - sqlite]
Org1_peer0[Peer: peer0]
Org1_peer1[Peer: peer1]
subgraph org1_example_com [Organization: Org1<br>org1.example.com]
subgraph org1_example_com_padding [ ]
direction RL
ca_org1_example_com([ca.org1.example.com<br>sqlite])
peer0_org1_example_com[peer0.org1.example.com<br>LevelDb]
peer1_org1_example_com[peer1.org1.example.com<br>LevelDb]
end
class org1_example_com_padding subgraph_padding
end

subgraph Channel_my_channel1 [Channel: my-channel1]
Chaincode_chaincode1[Chaincode: chaincode1]
subgraph channel_my_channel1 [Channel: my-channel1]
subgraph channel_my_channel1_padding [ ]
chaincode_chaincode1[[Chaincode: chaincode1]]
end
class channel_my_channel1_padding subgraph_padding
end

%% Connections
Org_Orderer --> Channel_my_channel1
Org_Org1 -.-> Channel_my_channel1
Org1_peer0 --> Channel_my_channel1
Org1_peer1 --> Channel_my_channel1
"
peer0_org1_example_com --> channel_my_channel1
peer1_org1_example_com --> channel_my_channel1
channel_my_channel1 --> ord_group_group1_orderer0_group1_orderer_example_com"
`;

exports[`samples/fablo-config-hlf2-1org-1chaincode-k8s.json should create proper files from samples/fablo-config-hlf2-1org-1chaincode-k8s.json 1`] = `
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

exports[`samples/fablo-config-hlf2-1org-1chaincode-peer-dev-mode.json should create proper e2e/__tmp__/samples/fablo-config-hlf2-1org-1chaincode-peer-dev-mode.json.tmpdir/fablo-target/fablo-config.json from samples/fablo-config-hlf2-1org-1chaincode-peer-dev-mode.json 1`] = `
"{
"$schema": "https://github.com/hyperledger-labs/fablo/releases/download/2.4.1/schema.json",
"$schema": "https://github.com/hyperledger-labs/fablo/releases/download/2.4.2/schema.json",
"global": {
"fabricVersion": "2.5.12",
"tls": false,
Expand Down Expand Up @@ -1513,7 +1513,7 @@ fi
`;

exports[`samples/fablo-config-hlf2-1org-1chaincode-peer-dev-mode.json should create proper e2e/__tmp__/samples/fablo-config-hlf2-1org-1chaincode-peer-dev-mode.json.tmpdir/fablo-target/fabric-docker/.env from samples/fablo-config-hlf2-1org-1chaincode-peer-dev-mode.json 1`] = `
"FABLO_VERSION=2.4.1
"FABLO_VERSION=2.4.2
FABLO_BUILD=<date with git hash>
FABLO_REST_VERSION=0.1.2
HYPERLEDGER_EXPLORER_VERSION=2.0.0
Expand Down Expand Up @@ -3537,26 +3537,44 @@ echo "Executing post-start hook"
`;

exports[`samples/fablo-config-hlf2-1org-1chaincode-peer-dev-mode.json should create proper e2e/__tmp__/samples/fablo-config-hlf2-1org-1chaincode-peer-dev-mode.json.tmpdir/fablo-target/network-topology.mmd from samples/fablo-config-hlf2-1org-1chaincode-peer-dev-mode.json 1`] = `
"graph TD

subgraph Org_Orderer [Org: Orderer]
CA_ca_Orderer[CA: ca_Orderer - sqlite]
"graph LR

classDef subgraph_padding fill:none,stroke:none

subgraph orderer_example_com [Organization: Orderer<br>orderer.example.com]
subgraph orderer_example_com_padding [ ]
direction RL
subgraph ord_group_group1_orderer0_group1_orderer_example_com [Orderer Group: group1<br>solo]
subgraph ord_group_group1_orderer0_group1_orderer_example_com_padding [ ]
direction RL
orderer0_group1_orderer_example_com[orderer0.group1.orderer.example.com]
end
class ord_group_group1_orderer0_group1_orderer_example_com_padding subgraph_padding
end
ca_orderer_example_com([ca.orderer.example.com<br>sqlite])
end
class orderer_example_com_padding subgraph_padding
end

subgraph Org_Org1 [Org: Org1]
CA_ca_Org1[CA: ca_Org1 - postgres]
Org1_peer0[Peer: peer0]
subgraph org1_example_com [Organization: Org1<br>org1.example.com]
subgraph org1_example_com_padding [ ]
direction RL
ca_org1_example_com([ca.org1.example.com<br>postgres])
peer0_org1_example_com[peer0.org1.example.com<br>CouchDb]
end
class org1_example_com_padding subgraph_padding
end

subgraph Channel_my_channel1 [Channel: my-channel1]
Chaincode_chaincode1[Chaincode: chaincode1]
subgraph channel_my_channel1 [Channel: my-channel1]
subgraph channel_my_channel1_padding [ ]
chaincode_chaincode1[[Chaincode: chaincode1]]
end
class channel_my_channel1_padding subgraph_padding
end

%% Connections
Org_Orderer --> Channel_my_channel1
Org_Org1 -.-> Channel_my_channel1
Org1_peer0 --> Channel_my_channel1
"
peer0_org1_example_com --> channel_my_channel1
channel_my_channel1 --> ord_group_group1_orderer0_group1_orderer_example_com"
`;

exports[`samples/fablo-config-hlf2-1org-1chaincode-peer-dev-mode.json should create proper files from samples/fablo-config-hlf2-1org-1chaincode-peer-dev-mode.json 1`] = `
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

exports[`samples/fablo-config-hlf2-1org-1chaincode.json should create proper e2e/__tmp__/samples/fablo-config-hlf2-1org-1chaincode.json.tmpdir/fablo-target/fablo-config.json from samples/fablo-config-hlf2-1org-1chaincode.json 1`] = `
"{
"$schema": "https://github.com/hyperledger-labs/fablo/releases/download/2.4.1/schema.json",
"$schema": "https://github.com/hyperledger-labs/fablo/releases/download/2.4.2/schema.json",
"global": {
"fabricVersion": "2.5.9",
"tls": false
Expand Down Expand Up @@ -1520,7 +1520,7 @@ fi
`;

exports[`samples/fablo-config-hlf2-1org-1chaincode.json should create proper e2e/__tmp__/samples/fablo-config-hlf2-1org-1chaincode.json.tmpdir/fablo-target/fabric-docker/.env from samples/fablo-config-hlf2-1org-1chaincode.json 1`] = `
"FABLO_VERSION=2.4.1
"FABLO_VERSION=2.4.2
FABLO_BUILD=<date with git hash>
FABLO_REST_VERSION=0.1.2
HYPERLEDGER_EXPLORER_VERSION=2.0.0
Expand Down Expand Up @@ -3598,28 +3598,46 @@ echo "Executing post-start hook"
`;

exports[`samples/fablo-config-hlf2-1org-1chaincode.json should create proper e2e/__tmp__/samples/fablo-config-hlf2-1org-1chaincode.json.tmpdir/fablo-target/network-topology.mmd from samples/fablo-config-hlf2-1org-1chaincode.json 1`] = `
"graph TD

subgraph Org_Orderer [Org: Orderer]
CA_ca_Orderer[CA: ca_Orderer - sqlite]
"graph LR

classDef subgraph_padding fill:none,stroke:none

subgraph orderer_example_com [Organization: Orderer<br>orderer.example.com]
subgraph orderer_example_com_padding [ ]
direction RL
subgraph ord_group_group1_orderer0_group1_orderer_example_com [Orderer Group: group1<br>solo]
subgraph ord_group_group1_orderer0_group1_orderer_example_com_padding [ ]
direction RL
orderer0_group1_orderer_example_com[orderer0.group1.orderer.example.com]
end
class ord_group_group1_orderer0_group1_orderer_example_com_padding subgraph_padding
end
ca_orderer_example_com([ca.orderer.example.com<br>sqlite])
end
class orderer_example_com_padding subgraph_padding
end

subgraph Org_Org1 [Org: Org1]
CA_ca_Org1[CA: ca_Org1 - sqlite]
Org1_peer0[Peer: peer0]
Org1_peer1[Peer: peer1]
subgraph org1_example_com [Organization: Org1<br>org1.example.com]
subgraph org1_example_com_padding [ ]
direction RL
ca_org1_example_com([ca.org1.example.com<br>sqlite])
peer0_org1_example_com[peer0.org1.example.com<br>LevelDb]
peer1_org1_example_com[peer1.org1.example.com<br>LevelDb]
end
class org1_example_com_padding subgraph_padding
end

subgraph Channel_my_channel1 [Channel: my-channel1]
Chaincode_chaincode1[Chaincode: chaincode1]
subgraph channel_my_channel1 [Channel: my-channel1]
subgraph channel_my_channel1_padding [ ]
chaincode_chaincode1[[Chaincode: chaincode1]]
end
class channel_my_channel1_padding subgraph_padding
end

%% Connections
Org_Orderer --> Channel_my_channel1
Org_Org1 -.-> Channel_my_channel1
Org1_peer0 --> Channel_my_channel1
Org1_peer1 --> Channel_my_channel1
"
peer0_org1_example_com --> channel_my_channel1
peer1_org1_example_com --> channel_my_channel1
channel_my_channel1 --> ord_group_group1_orderer0_group1_orderer_example_com"
`;

exports[`samples/fablo-config-hlf2-1org-1chaincode.json should create proper files from samples/fablo-config-hlf2-1org-1chaincode.json 1`] = `
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

exports[`samples/fablo-config-hlf3-1org-2chaincode-raft-ccaas.json should create proper e2e/__tmp__/samples/fablo-config-hlf3-1org-2chaincode-raft-ccaas.json.tmpdir/fablo-target/fablo-config.json from samples/fablo-config-hlf3-1org-2chaincode-raft-ccaas.json 1`] = `
"{
"$schema": "https://github.com/hyperledger-labs/fablo/releases/download/2.4.1/schema.json",
"$schema": "https://github.com/hyperledger-labs/fablo/releases/download/2.4.2/schema.json",
"global": {
"fabricVersion": "3.1.0",
"tls": true
Expand Down Expand Up @@ -1598,7 +1598,7 @@ fi
`;

exports[`samples/fablo-config-hlf3-1org-2chaincode-raft-ccaas.json should create proper e2e/__tmp__/samples/fablo-config-hlf3-1org-2chaincode-raft-ccaas.json.tmpdir/fablo-target/fabric-docker/.env from samples/fablo-config-hlf3-1org-2chaincode-raft-ccaas.json 1`] = `
"FABLO_VERSION=2.4.1
"FABLO_VERSION=2.4.2
FABLO_BUILD=<date with git hash>
FABLO_REST_VERSION=0.1.2
HYPERLEDGER_EXPLORER_VERSION=2.0.0
Expand Down Expand Up @@ -3783,33 +3783,53 @@ echo "Executing post-start hook"
`;

exports[`samples/fablo-config-hlf3-1org-2chaincode-raft-ccaas.json should create proper e2e/__tmp__/samples/fablo-config-hlf3-1org-2chaincode-raft-ccaas.json.tmpdir/fablo-target/network-topology.mmd from samples/fablo-config-hlf3-1org-2chaincode-raft-ccaas.json 1`] = `
"graph TD

subgraph Org_Orderer [Org: Orderer]
CA_ca_Orderer[CA: ca_Orderer - sqlite]
"graph LR

classDef subgraph_padding fill:none,stroke:none

subgraph orderer_example_com [Organization: Orderer<br>orderer.example.com]
subgraph orderer_example_com_padding [ ]
direction RL
subgraph ord_group_group1_orderer0_group1_orderer_example_com [Orderer Group: group1<br>etcdraft]
subgraph ord_group_group1_orderer0_group1_orderer_example_com_padding [ ]
direction RL
orderer0_group1_orderer_example_com[orderer0.group1.orderer.example.com]
end
class ord_group_group1_orderer0_group1_orderer_example_com_padding subgraph_padding
end
ca_orderer_example_com([ca.orderer.example.com<br>sqlite])
end
class orderer_example_com_padding subgraph_padding
end

subgraph Org_Org1 [Org: Org1]
CA_ca_Org1[CA: ca_Org1 - postgres]
Org1_peer0[Peer: peer0]
subgraph org1_example_com [Organization: Org1<br>org1.example.com]
subgraph org1_example_com_padding [ ]
direction RL
ca_org1_example_com([ca.org1.example.com<br>postgres])
peer0_org1_example_com[peer0.org1.example.com<br>CouchDb]
end
class org1_example_com_padding subgraph_padding
end

subgraph Channel_my_channel1 [Channel: my-channel1]
Chaincode_chaincode1[Chaincode: chaincode1]
subgraph channel_my_channel1 [Channel: my-channel1]
subgraph channel_my_channel1_padding [ ]
chaincode_chaincode1[[Chaincode: chaincode1]]
end
class channel_my_channel1_padding subgraph_padding
end

subgraph Channel_my_channel2 [Channel: my-channel2]
Chaincode_chaincode1[Chaincode: chaincode1]
subgraph channel_my_channel2 [Channel: my-channel2]
subgraph channel_my_channel2_padding [ ]
chaincode_chaincode1[[Chaincode: chaincode1]]
end
class channel_my_channel2_padding subgraph_padding
end

%% Connections
Org_Orderer --> Channel_my_channel1
Org_Orderer --> Channel_my_channel2
Org_Org1 -.-> Channel_my_channel1
Org1_peer0 --> Channel_my_channel1
Org_Org1 -.-> Channel_my_channel2
Org1_peer0 --> Channel_my_channel2
"
peer0_org1_example_com --> channel_my_channel1
peer0_org1_example_com --> channel_my_channel2
channel_my_channel1 --> ord_group_group1_orderer0_group1_orderer_example_com
channel_my_channel2 --> ord_group_group1_orderer0_group1_orderer_example_com"
`;

exports[`samples/fablo-config-hlf3-1org-2chaincode-raft-ccaas.json should create proper files from samples/fablo-config-hlf3-1org-2chaincode-raft-ccaas.json 1`] = `
Expand Down
Loading
Loading