Skip to content

Commit 3692f55

Browse files
committed
fix-update snapshots
Signed-off-by: Pereowei Daniel <[email protected]>
1 parent 9dba750 commit 3692f55

File tree

4 files changed

+222
-3
lines changed

4 files changed

+222
-3
lines changed

e2e/__snapshots__/extendConfig.test.ts.snap

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5884,7 +5884,12 @@ exports[`extend config samples/fablo-config-hlf2-2orgs-2chaincodes-raft.yaml 1`]
58845884
"fabloConfig": "<absolute path>",
58855885
},
58865886
"tls": true,
5887-
"tools": {},
5887+
"tools": {
5888+
"explorer": {
5889+
"address": "explorer.example.com",
5890+
"port": 7010,
5891+
},
5892+
},
58885893
},
58895894
"hooks": {
58905895
"postGenerate": "perl -i -pe 's/MaxMessageCount: 10/MaxMessageCount: 1/g' "./fablo-target/fabric-config/configtx.yaml"",

e2e/__snapshots__/fablo-config-hlf2-2orgs-2chaincodes-raft.yaml.test.ts.snap

Lines changed: 207 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1249,6 +1249,164 @@ exports[`samples/fablo-config-hlf2-2orgs-2chaincodes-raft.yaml should create pro
12491249
"
12501250
`;
12511251
1252+
exports[`samples/fablo-config-hlf2-2orgs-2chaincodes-raft.yaml should create proper e2e/__tmp__/samples/fablo-config-hlf2-2orgs-2chaincodes-raft.yaml.tmpdir/fablo-target/fabric-config/explorer/config-org1.json from samples/fablo-config-hlf2-2orgs-2chaincodes-raft.yaml 1`] = `
1253+
"{
1254+
"network-configs": {
1255+
"network-org1": {
1256+
"name": "Network of Org1",
1257+
"profile": "/opt/explorer/app/platform/fabric/connection-profile/connection-profile-org1.json"
1258+
}
1259+
},
1260+
"license": "Apache-2.0"
1261+
}
1262+
"
1263+
`;
1264+
1265+
exports[`samples/fablo-config-hlf2-2orgs-2chaincodes-raft.yaml should create proper e2e/__tmp__/samples/fablo-config-hlf2-2orgs-2chaincodes-raft.yaml.tmpdir/fablo-target/fabric-config/explorer/config-org2.json from samples/fablo-config-hlf2-2orgs-2chaincodes-raft.yaml 1`] = `
1266+
"{
1267+
"network-configs": {
1268+
"network-org2": {
1269+
"name": "Network of Org2",
1270+
"profile": "/opt/explorer/app/platform/fabric/connection-profile/connection-profile-org2.json"
1271+
}
1272+
},
1273+
"license": "Apache-2.0"
1274+
}
1275+
"
1276+
`;
1277+
1278+
exports[`samples/fablo-config-hlf2-2orgs-2chaincodes-raft.yaml should create proper e2e/__tmp__/samples/fablo-config-hlf2-2orgs-2chaincodes-raft.yaml.tmpdir/fablo-target/fabric-config/explorer/connection-profile-org1.json from samples/fablo-config-hlf2-2orgs-2chaincodes-raft.yaml 1`] = `
1279+
"{
1280+
"name": "fablo-test-network-org1",
1281+
"description": "Connection profile for Hyperledger Explorer in Fablo network",
1282+
"version": "1.0.0",
1283+
"client": {
1284+
"organization": "Org1",
1285+
"tlsEnable": true,
1286+
"enableAuthentication": true,
1287+
"adminCredential": {
1288+
"id": "admin",
1289+
"password": "adminpw"
1290+
},
1291+
"connection": {
1292+
"timeout": {
1293+
"peer": {
1294+
"endorser": "300"
1295+
},
1296+
"orderer": "300"
1297+
}
1298+
}
1299+
},
1300+
"organizations": {
1301+
"Org1": {
1302+
"mspid": "Org1MSP",
1303+
"adminPrivateKey": {
1304+
"path": "/tmp/crypto/peerOrganizations/org1.example.com/users/[email protected]/msp/keystore/priv-key.pem"
1305+
},
1306+
"peers": [
1307+
"peer0.org1.example.com",
1308+
"peer1.org1.example.com"
1309+
],
1310+
"signedCert": {
1311+
"path": "/tmp/crypto/peerOrganizations/org1.example.com/users/[email protected]/msp/signcerts/[email protected]"
1312+
}
1313+
}
1314+
},
1315+
"peers": {
1316+
"peer0.org1.example.com": {
1317+
"url": "grpcs://peer0.org1.example.com:7061",
1318+
"tlsCACerts": {
1319+
"path": "/tmp/crypto/peerOrganizations/org1.example.com/msp/tlscacerts/tlsca.org1.example.com-cert.pem"
1320+
}
1321+
},
1322+
"peer1.org1.example.com": {
1323+
"url": "grpcs://peer1.org1.example.com:7062",
1324+
"tlsCACerts": {
1325+
"path": "/tmp/crypto/peerOrganizations/org1.example.com/msp/tlscacerts/tlsca.org1.example.com-cert.pem"
1326+
}
1327+
}
1328+
},
1329+
"channels": {
1330+
"my-channel1": {
1331+
"peers": {}
1332+
},
1333+
"my-channel2": {
1334+
"peers": {}
1335+
},
1336+
"my-channel3": {
1337+
"peers": {}
1338+
}
1339+
}
1340+
}
1341+
"
1342+
`;
1343+
1344+
exports[`samples/fablo-config-hlf2-2orgs-2chaincodes-raft.yaml should create proper e2e/__tmp__/samples/fablo-config-hlf2-2orgs-2chaincodes-raft.yaml.tmpdir/fablo-target/fabric-config/explorer/connection-profile-org2.json from samples/fablo-config-hlf2-2orgs-2chaincodes-raft.yaml 1`] = `
1345+
"{
1346+
"name": "fablo-test-network-org2",
1347+
"description": "Connection profile for Hyperledger Explorer in Fablo network",
1348+
"version": "1.0.0",
1349+
"client": {
1350+
"organization": "Org2",
1351+
"tlsEnable": true,
1352+
"enableAuthentication": true,
1353+
"adminCredential": {
1354+
"id": "admin",
1355+
"password": "adminpw"
1356+
},
1357+
"connection": {
1358+
"timeout": {
1359+
"peer": {
1360+
"endorser": "300"
1361+
},
1362+
"orderer": "300"
1363+
}
1364+
}
1365+
},
1366+
"organizations": {
1367+
"Org2": {
1368+
"mspid": "Org2MSP",
1369+
"adminPrivateKey": {
1370+
"path": "/tmp/crypto/peerOrganizations/org2.example.com/users/[email protected]/msp/keystore/priv-key.pem"
1371+
},
1372+
"peers": [
1373+
"peer0.org2.example.com",
1374+
"peer1.org2.example.com"
1375+
],
1376+
"signedCert": {
1377+
"path": "/tmp/crypto/peerOrganizations/org2.example.com/users/[email protected]/msp/signcerts/[email protected]"
1378+
}
1379+
}
1380+
},
1381+
"peers": {
1382+
"peer0.org2.example.com": {
1383+
"url": "grpcs://peer0.org2.example.com:7081",
1384+
"tlsCACerts": {
1385+
"path": "/tmp/crypto/peerOrganizations/org2.example.com/msp/tlscacerts/tlsca.org2.example.com-cert.pem"
1386+
}
1387+
},
1388+
"peer1.org2.example.com": {
1389+
"url": "grpcs://peer1.org2.example.com:7082",
1390+
"tlsCACerts": {
1391+
"path": "/tmp/crypto/peerOrganizations/org2.example.com/msp/tlscacerts/tlsca.org2.example.com-cert.pem"
1392+
}
1393+
}
1394+
},
1395+
"channels": {
1396+
"my-channel1": {
1397+
"peers": {}
1398+
},
1399+
"my-channel2": {
1400+
"peers": {}
1401+
},
1402+
"my-channel3": {
1403+
"peers": {}
1404+
}
1405+
}
1406+
}
1407+
"
1408+
`;
1409+
12521410
exports[`samples/fablo-config-hlf2-2orgs-2chaincodes-raft.yaml should create proper e2e/__tmp__/samples/fablo-config-hlf2-2orgs-2chaincodes-raft.yaml.tmpdir/fablo-target/fabric-config/fabric-ca-server-config/orderer1.com/fabric-ca-server-config.yaml from samples/fablo-config-hlf2-2orgs-2chaincodes-raft.yaml 1`] = `
12531411
"#############################################################################
12541412
# This is a configuration file for the fabric-ca-server command.
@@ -3815,6 +3973,8 @@ installChannels() {
38153973
printItalics "Joining 'my-channel3' on Org2/peer1" "U1F638"
38163974
docker exec -i cli.org2.example.com bash -c "source scripts/channel_fns.sh; fetchChannelAndJoinTls 'my-channel3' 'Org2MSP' 'peer1.org2.example.com:7082' 'crypto/users/[email protected]/msp' 'crypto/users/[email protected]/tls' 'crypto-orderer/tlsca.orderer2.com-cert.pem' 'orderer0.group2.orderer2.com:7050';"
38173975
3976+
echo "Restarting global Explorer: explorer.example.com"
3977+
docker restart explorer.example.com || true
38183978
}
38193979
38203980
installChaincodes() {
@@ -4708,6 +4868,49 @@ services:
47084868
- ../fabric-config/config:/etc/hyperledger/fabric/config
47094869
networks:
47104870
- basic
4871+
4872+
db.explorer.example.com:
4873+
image: ghcr.io/hyperledger-labs/explorer-db:\${HYPERLEDGER_EXPLORER_VERSION}
4874+
container_name: db.explorer.example.com
4875+
environment:
4876+
- DATABASE_DATABASE=fabricexplorer
4877+
- DATABASE_USERNAME=hppoc
4878+
- DATABASE_PASSWORD=password
4879+
healthcheck:
4880+
test: "pg_isready -h localhost -p 5432 -q -U hppoc -d fabricexplorer"
4881+
interval: 5s
4882+
timeout: 10s
4883+
retries: 7
4884+
volumes:
4885+
- /var/lib/postgresql/data
4886+
networks:
4887+
- basic
4888+
4889+
explorer.example.com:
4890+
image: ghcr.io/hyperledger-labs/explorer:\${HYPERLEDGER_EXPLORER_VERSION}
4891+
restart: on-failure:8
4892+
container_name: explorer.example.com
4893+
environment:
4894+
- DATABASE_HOST=db.explorer.example.com
4895+
- DATABASE_DATABASE=fabricexplorer
4896+
- DATABASE_USERNAME=hppoc
4897+
- DATABASE_PASSWD=password
4898+
- LOG_LEVEL_APP=debug
4899+
- LOG_LEVEL_DB=debug
4900+
- LOG_LEVEL_CONSOLE=info
4901+
- LOG_CONSOLE_STDOUT=true
4902+
- DISCOVERY_AS_LOCALHOST=false
4903+
volumes:
4904+
- ../fabric-config/explorer/config-global.json:/opt/explorer/app/platform/fabric/config.json
4905+
- ../fabric-config/explorer:/opt/explorer/app/platform/fabric/connection-profile
4906+
- ../fabric-config/crypto-config:/tmp/crypto
4907+
ports:
4908+
- "7010:8080"
4909+
depends_on:
4910+
db.explorer.example.com:
4911+
condition: service_healthy
4912+
networks:
4913+
- basic
47114914
"
47124915
`;
47134916
@@ -6202,6 +6405,10 @@ exports[`samples/fablo-config-hlf2-2orgs-2chaincodes-raft.yaml should create pro
62026405
"e2e/__tmp__/samples/fablo-config-hlf2-2orgs-2chaincodes-raft.yaml.tmpdir/fablo-target/fabric-config/crypto-config-org1.yaml",
62036406
"e2e/__tmp__/samples/fablo-config-hlf2-2orgs-2chaincodes-raft.yaml.tmpdir/fablo-target/fabric-config/crypto-config-org2.yaml",
62046407
"e2e/__tmp__/samples/fablo-config-hlf2-2orgs-2chaincodes-raft.yaml.tmpdir/fablo-target/fabric-config/explorer/config-global.json",
6408+
"e2e/__tmp__/samples/fablo-config-hlf2-2orgs-2chaincodes-raft.yaml.tmpdir/fablo-target/fabric-config/explorer/config-org1.json",
6409+
"e2e/__tmp__/samples/fablo-config-hlf2-2orgs-2chaincodes-raft.yaml.tmpdir/fablo-target/fabric-config/explorer/config-org2.json",
6410+
"e2e/__tmp__/samples/fablo-config-hlf2-2orgs-2chaincodes-raft.yaml.tmpdir/fablo-target/fabric-config/explorer/connection-profile-org1.json",
6411+
"e2e/__tmp__/samples/fablo-config-hlf2-2orgs-2chaincodes-raft.yaml.tmpdir/fablo-target/fabric-config/explorer/connection-profile-org2.json",
62056412
"e2e/__tmp__/samples/fablo-config-hlf2-2orgs-2chaincodes-raft.yaml.tmpdir/fablo-target/fabric-config/fabric-ca-server-config/orderer1.com/fabric-ca-server-config.yaml",
62066413
"e2e/__tmp__/samples/fablo-config-hlf2-2orgs-2chaincodes-raft.yaml.tmpdir/fablo-target/fabric-config/fabric-ca-server-config/orderer2.com/fabric-ca-server-config.yaml",
62076414
"e2e/__tmp__/samples/fablo-config-hlf2-2orgs-2chaincodes-raft.yaml.tmpdir/fablo-target/fabric-config/fabric-ca-server-config/org1.example.com/fabric-ca-server-config.yaml",

e2e/__snapshots__/fabloCommands.test.ts.snap

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,12 @@ Validation warnings count: 0
88
"global": {
99
"fabricVersion": "2.5.12",
1010
"tls": true,
11+
"tools": {
12+
"explorer": {
13+
"address": "explorer.example.com",
14+
"port": 7010
15+
}
16+
},
1117
"fabricToolsVersion": "2.5.12",
1218
"fabricCaVersion": "1.5.5",
1319
"fabricCcenvVersion": "2.5.12",
@@ -29,8 +35,7 @@ Validation warnings count: 0
2935
"application": "V2_5",
3036
"isV2": true,
3137
"isV3": false
32-
},
33-
"tools": {}
38+
}
3439
},
3540
"ordererGroups": [
3641
{

samples/fablo-config-hlf2-2orgs-2chaincodes-raft.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,8 @@
33
global:
44
fabricVersion: 2.5.12
55
tls: true
6+
tools:
7+
explorer: true
68
orgs:
79
- organization:
810
name: Orderer1

0 commit comments

Comments
 (0)