Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Upgrade Bevel Operator version #425

Open
wants to merge 9 commits into
base: main
Choose a base branch
from
Open
Changes from 1 commit
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
Prev Previous commit
Next Next commit
Update snapshots
Signed-off-by: dzikowski <[email protected]>
  • Loading branch information
dzikowski committed Dec 5, 2023

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature.
commit bc366a721c6ce629107f1e4057d61616cfba7465
12 changes: 6 additions & 6 deletions e2e/__snapshots__/extendConfig.test.ts.snap
Original file line number Diff line number Diff line change
@@ -4214,7 +4214,7 @@ Object {
},
"engine": "docker",
"fabricBaseosVersion": "0.4.9",
"fabricCaVersion": "1.5.5",
"fabricCaVersion": "1.5.6",
"fabricCcenvVersion": "1.4.11",
"fabricJavaenvVersion": "1.4",
"fabricNodeenvVersion": "1.4",
@@ -6849,7 +6849,7 @@ Object {
},
"engine": "docker",
"fabricBaseosVersion": "2.4.7",
"fabricCaVersion": "1.5.5",
"fabricCaVersion": "1.5.6",
"fabricCcenvVersion": "2.4.7",
"fabricJavaenvVersion": "2.4",
"fabricNodeenvVersion": "2.4",
@@ -7659,7 +7659,7 @@ Object {
},
"engine": "kubernetes",
"fabricBaseosVersion": "2.4.7",
"fabricCaVersion": "1.5.5",
"fabricCaVersion": "1.5.6",
"fabricCcenvVersion": "2.4.7",
"fabricJavaenvVersion": "2.4",
"fabricNodeenvVersion": "2.4",
@@ -8444,7 +8444,7 @@ Object {
},
"engine": "docker",
"fabricBaseosVersion": "2.3.3",
"fabricCaVersion": "1.5.5",
"fabricCaVersion": "1.5.6",
"fabricCcenvVersion": "2.3.3",
"fabricJavaenvVersion": "2.3",
"fabricNodeenvVersion": "2.3",
@@ -10604,7 +10604,7 @@ Object {
},
"engine": "docker",
"fabricBaseosVersion": "2.4.3",
"fabricCaVersion": "1.5.5",
"fabricCaVersion": "1.5.6",
"fabricCcenvVersion": "2.4.3",
"fabricJavaenvVersion": "2.4",
"fabricNodeenvVersion": "2.4",
@@ -13090,7 +13090,7 @@ Object {
},
"engine": "docker",
"fabricBaseosVersion": "2.3.2",
"fabricCaVersion": "1.5.5",
"fabricCaVersion": "1.5.6",
"fabricCcenvVersion": "2.3.2",
"fabricJavaenvVersion": "2.3",
"fabricNodeenvVersion": "2.3",
Original file line number Diff line number Diff line change
@@ -2108,7 +2108,7 @@ COMPOSE_PROJECT_NAME=<name with timestamp>
LOGGING_LEVEL=info

FABRIC_VERSION=1.4.11
FABRIC_CA_VERSION=1.5.5
FABRIC_CA_VERSION=1.5.6
FABRIC_CA_POSTGRES_VERSION=14
FABRIC_CCENV_VERSION=1.4.11
FABRIC_BASEOS_VERSION=0.4.9
Original file line number Diff line number Diff line change
@@ -27,11 +27,9 @@ BLUE=\\"$(printf '\\\\033[34m')\\"
networkUp() {
printHeadline \\"Checking dependencies...\\" \\"U1F984\\"
verifyKubernetesConnectivity
printHeadline \\"Starting Network...\\" \\"U1F984\\"
deployPeer
deployOrderer
installChannels
installChaincodes
startNetwork
# installChannels
# installChaincodes
printHeadline \\"Done! Enjoy your fresh network\\" \\"U1F984\\"
}

@@ -91,11 +89,10 @@ FABLO_BUILD=<date with git hash>
FABLO_CONFIG=<absolute path>
ORDERER_IMAGE=hyperledger/fabric-orderer
ORDERER_VERSION=2.4.7
PEER_IMAGE=quay.io/kfsoftware/fabric-peer
PEER_VERSION=2.4.1-v0.0.3
# PEER_VERSION=2.4.7
PEER_IMAGE=hyperledger/fabric-peer
PEER_VERSION=2.4.7
CA_IMAGE=hyperledger/fabric-ca
CA_VERSION=1.5.5
CA_VERSION=1.5.6
LOGGING_LEVEL=info

CHAINCODES_BASE_DIR=<absolute path>
@@ -117,59 +114,114 @@ exports[`samples/fablo-config-hlf2-1org-1chaincode-k8s.json should create proper

source \\"$FABLO_NETWORK_ROOT/fabric-k8s/scripts/util.sh\\"

deployPeer() {

printItalics \\"Deploying Org1 CA\\" \\"U1F984\\"
kubectl hlf ca create --image=\\"$CA_IMAGE\\" --version=\\"$CA_VERSION\\" --storage-class=\\"$STORAGE_CLASS\\" --capacity=2Gi --name=org1-ca --enroll-id=org1 --enroll-pw=\\"$ORG1_CA_ADMIN_PASSWORD\\"
sleep 3

while [[ $(kubectl get pods -l release=org1-ca -o 'jsonpath={..status.conditions[?(@.type==\\"Ready\\")].status}') != \\"True\\" ]]; do
sleep 5
inputLog \\"waiting for CA\\"
done

kubectl hlf ca register --name=org1-ca --user=peer --secret=\\"$ORG1_CA_ADMIN_PASSWORD\\" --type=peer --enroll-id org1 --enroll-secret=\\"$ORG1_CA_ADMIN_PASSWORD\\" --mspid Org1MSP
inputLog \\"registered Org1 -ca\\"

printItalics \\"Deploying Peers\\" \\"U1F984\\"
sleep 10
deployCA() {
local CA_HOST=\\"$1\\"
local MSPID=\\"$2\\"
local CA_NAME=\\"$(echo \\"$CA_HOST\\" | sed 's/\\\\./-/g')\\"

inputLog \\"Deploying $CA_ID ($CA_IMAGE:$CA_VERSION)\\"
kubectl hlf ca create \\\\
--image=\\"$CA_IMAGE\\" \\\\
--version=\\"$CA_VERSION\\" \\\\
--storage-class=\\"$STORAGE_CLASS\\" \\\\
--capacity=2Gi \\\\
--name=\\"$CA_NAME\\" \\\\
--hosts=\\"$CA_NAME.localho.st\\" \\\\
--enroll-id=enroll \\\\
--enroll-pw=enrollpw
}

kubectl hlf peer create --statedb=leveldb --version=\\"$PEER_VERSION\\" --storage-class=\\"$STORAGE_CLASS\\" --enroll-id=peer --mspid=Org1MSP \\\\
--enroll-pw=\\"$ORG1_CA_ADMIN_PASSWORD\\" --capacity=5Gi --name=peer0 --ca-name=\\"org1-ca.$NAMESPACE\\" --k8s-builder=true --external-service-builder=false
registerPeerUser() {
local CA_HOST=\\"$1\\"
local MSPID=\\"$2\\"
local CA_NAME=\\"$(echo \\"$CA_HOST\\" | sed 's/\\\\./-/g')\\"

inputLog \\"Registering peer user $PEER_USER on $CA_HOST\\"
kubectl hlf ca register \\\\
--name=\\"$CA_NAME\\" \\\\
--user=peer \\\\
--secret=peerpw \\\\
--type=peer \\\\
--enroll-id=enroll \\\\
--enroll-secret=enrollpw \\\\
--mspid=\\"$MSPID\\"
}

kubectl hlf peer create --statedb=leveldb --version=\\"$PEER_VERSION\\" --storage-class=\\"$STORAGE_CLASS\\" --enroll-id=peer --mspid=Org1MSP \\\\
--enroll-pw=\\"$ORG1_CA_ADMIN_PASSWORD\\" --capacity=5Gi --name=peer1 --ca-name=\\"org1-ca.$NAMESPACE\\" --k8s-builder=true --external-service-builder=false
deployPeer() {
local PEER_HOST=\\"$1\\"
local CA_HOST=\\"$2\\"
local MSPID=\\"$3\\"
local PEER_NAME=\\"$(echo \\"$PEER_HOST\\" | sed 's/\\\\./-/g')\\"
local CA_NAME=\\"$(echo \\"$CA_HOST\\" | sed 's/\\\\./-/g')\\"

inputLog \\"Deploying $PEER_HOST ($PEER_IMAGE:$PEER_VERSION)\\"
# TODO: make --statedb configurable
kubectl hlf peer create \\\\
--statedb=leveldb \\\\
--image=\\"$PEER_IMAGE\\" \\\\
--version=\\"$PEER_VERSION\\" \\\\
--storage-class=\\"$STORAGE_CLASS\\" \\\\
--capacity=5Gi \\\\
--enroll-id=peer \\\\
--enroll-pw=peerpw \\\\
--name=\\"$PEER_NAME\\" \\\\
--hosts=\\"$PEER_NAME.localho.st\\" \\\\
--ca-name=\\"$CA_NAME.$NAMESPACE\\" \\\\
--mspid=\\"$MSPID\\"
}

while [[ $(kubectl get pods -l app=hlf-peer --output=jsonpath='{.items[*].status.containerStatuses[0].ready}') != \\"true true\\" ]]; do
sleep 5
inputLog \\"waiting for peer nodes to be ready\\"
done
registerOrdererUser() {
local CA_HOST=\\"$1\\"
local MSPID=\\"$2\\"
local CA_NAME=\\"$(echo \\"$CA_HOST\\" | sed 's/\\\\./-/g')\\"

inputLog \\"Registering orderer user $ORDERER_USER on $CA_HOST\\"
kubectl hlf ca register \\\\
--name=\\"$CA_NAME\\" \\\\
--user=orderer \\\\
--secret=ordererpw \\\\
--type=orderer \\\\
--enroll-id=enroll \\\\
--enroll-secret=enrollpw \\\\
--mspid=\\"$MSPID\\"
}

deployOrderer() {
local ORDERER_HOST=\\"$1\\"
local CA_HOST=\\"$2\\"
local MSPID=\\"$3\\"
local CA_NAME=\\"$(echo \\"$CA_HOST\\" | sed 's/\\\\./-/g')\\"
local ORDERER_NAME=\\"$(echo \\"$ORDERER_HOST\\" | sed 's/\\\\./-/g')\\"

inputLog \\"Deploying $ORDERER_HOST ($ORDERER_IMAGE:$ORDERER_VERSION)\\"
kubectl hlf ordnode create \\\\
--image=\\"$ORDERER_IMAGE\\" \\\\
--version=\\"$ORDERER_VERSION\\" \\\\
--storage-class=\\"$STORAGE_CLASS\\" \\\\
--capacity=2Gi \\\\
--enroll-id=orderer \\\\
--enroll-pw=ordererpw \\\\
--name=\\"$ORDERER_NAME\\" \\\\
--hosts=\\"$ORDERER_NAME.localho.st\\" \\\\
--ca-name=\\"$CA_NAME.$NAMESPACE\\" \\\\
--mspid=\\"$MSPID\\"
}

printItalics \\"Deploying Orderers\\" \\"U1F984\\"

kubectl hlf ca create --storage-class=\\"$STORAGE_CLASS\\" --capacity=2Gi --name=orderer-ca --enroll-id=orderer --enroll-pw=\\"$ORDERER_CA_ADMIN_PASSWORD\\"
while [[ $(kubectl get pods -l release=orderer-ca -o 'jsonpath={..status.conditions[?(@.type==\\"Ready\\")].status}') != \\"True\\" ]]; do
sleep 5
inputLog \\"waiting for orderer-ca CA to be ready\\" \\"$RESETBG\\"
done
kubectl hlf ca register --name=orderer-ca --user=\\"$ORDERER_CA_ADMIN_NAME\\" --secret=\\"$ORDERER_CA_ADMIN_PASSWORD\\" --type=orderer --enroll-id=orderer --enroll-secret=\\"$ORDERER_CA_ADMIN_PASSWORD\\" --mspid OrdererMSP &&
inputLog \\"registered orderer-ca\\"
startNetwork() {
printHeadline \\"Starting network\\" \\"U1F680\\"

kubectl hlf ordnode create --version=\\"$ORDERER_VERSION\\" \\\\
--storage-class=\\"$STORAGE_CLASS\\" --enroll-id=\\"$ORDERER_CA_ADMIN_NAME\\" --mspid=OrdererMSP \\\\
--enroll-pw=\\"$ORDERER_CA_ADMIN_PASSWORD\\" --capacity=2Gi --name=orderer-node --ca-name=\\"orderer-ca.$NAMESPACE\\"
while [[ $(kubectl get pods -l app=hlf-ordnode -o 'jsonpath={..status.conditions[?(@.type==\\"Ready\\")].status}') != \\"True\\" ]]; do
sleep 5
inputLog \\"waiting for orderer Node to be ready\\"
done
deployCA \\"ca.orderer.example.com\\" \\"OrdererMSP\\"
deployCA \\"ca.org1.example.com\\" \\"Org1MSP\\"
kubectl wait --timeout=60s --for=condition=Running fabriccas.hlf.kungfusoftware.es --all

kubectl hlf inspect --output \\"$CONFIG_DIR/ordservice.yaml\\" -o OrdererMSP
kubectl hlf ca enroll --name=orderer-ca --user=\\"$ORDERER_CA_ADMIN_NAME\\" --secret=\\"$ORDERER_CA_ADMIN_PASSWORD\\" --mspid OrdererMSP --ca-name ca --output \\"$CONFIG_DIR/admin-ordservice.yaml\\" &&
kubectl hlf utils adduser --userPath=\\"$CONFIG_DIR/admin-ordservice.yaml\\" --config=\\"$CONFIG_DIR/ordservice.yaml\\" --username=\\"$ORDERER_CA_ADMIN_NAME\\" --mspid=OrdererMSP
registerOrdererUser \\"ca.orderer.example.com\\" \\"OrdererMSP\\"
deployOrderer \\"orderer0.group1.orderer.example.com\\" \\"ca.orderer.example.com\\" \\"OrdererMSP\\"
kubectl wait --timeout=180s --for=condition=Running fabricorderernodes.hlf.kungfusoftware.es --all

registerPeerUser \\"ca.org1.example.com\\" \\"Org1MSP\\"
deployPeer \\"peer0.org1.example.com\\" \\"ca.org1.example.com\\" \\"Org1MSP\\"
deployPeer \\"peer1.org1.example.com\\" \\"ca.org1.example.com\\" \\"Org1MSP\\"
kubectl wait --timeout=180s --for=condition=Running fabricpeers.hlf.kungfusoftware.es --all
}

installChannels() {
Original file line number Diff line number Diff line change
@@ -1539,7 +1539,7 @@ COMPOSE_PROJECT_NAME=<name with timestamp>
LOGGING_LEVEL=info

FABRIC_VERSION=2.3.3
FABRIC_CA_VERSION=1.5.5
FABRIC_CA_VERSION=1.5.6
FABRIC_CA_POSTGRES_VERSION=14
FABRIC_CCENV_VERSION=2.3.3
FABRIC_BASEOS_VERSION=2.3.3
Original file line number Diff line number Diff line change
@@ -1449,7 +1449,7 @@ COMPOSE_PROJECT_NAME=<name with timestamp>
LOGGING_LEVEL=info

FABRIC_VERSION=2.4.7
FABRIC_CA_VERSION=1.5.5
FABRIC_CA_VERSION=1.5.6
FABRIC_CA_POSTGRES_VERSION=14
FABRIC_CCENV_VERSION=2.4.7
FABRIC_BASEOS_VERSION=2.4.7
Original file line number Diff line number Diff line change
@@ -3036,7 +3036,7 @@ COMPOSE_PROJECT_NAME=<name with timestamp>
LOGGING_LEVEL=debug

FABRIC_VERSION=2.4.3
FABRIC_CA_VERSION=1.5.5
FABRIC_CA_VERSION=1.5.6
FABRIC_CA_POSTGRES_VERSION=14
FABRIC_CCENV_VERSION=2.4.3
FABRIC_BASEOS_VERSION=2.4.3
Original file line number Diff line number Diff line change
@@ -3331,7 +3331,7 @@ COMPOSE_PROJECT_NAME=<name with timestamp>
LOGGING_LEVEL=info

FABRIC_VERSION=2.3.2
FABRIC_CA_VERSION=1.5.5
FABRIC_CA_VERSION=1.5.6
FABRIC_CA_POSTGRES_VERSION=14
FABRIC_CCENV_VERSION=2.3.2
FABRIC_BASEOS_VERSION=2.3.2
4 changes: 2 additions & 2 deletions e2e/__snapshots__/fabloCommands.test.ts.snap
Original file line number Diff line number Diff line change
@@ -11,7 +11,7 @@ Validation warnings count: 0
\\"monitoring\\": {
\\"loglevel\\": \\"debug\\"
},
\\"fabricCaVersion\\": \\"1.5.5\\",
\\"fabricCaVersion\\": \\"1.5.6\\",
\\"fabricCcenvVersion\\": \\"2.4.3\\",
\\"fabricBaseosVersion\\": \\"2.4.3\\",
\\"fabricJavaenvVersion\\": \\"2.4\\",
@@ -2431,7 +2431,7 @@ Validation warnings count: 0
\\"tls\\": false,
\\"engine\\": \\"docker\\",
\\"peerDevMode\\": false,
\\"fabricCaVersion\\": \\"1.5.5\\",
\\"fabricCaVersion\\": \\"1.5.6\\",
\\"fabricCcenvVersion\\": \\"2.4.7\\",
\\"fabricBaseosVersion\\": \\"2.4.7\\",
\\"fabricJavaenvVersion\\": \\"2.4\\",