[FAB-16344] Upgrade scripts for v1.4.3

Signed-off-by: bharadwajambati1 <bharadwaj.ambati1@ibm.com>
Change-Id: Icd4eb98e7953288cc51577a7952b5680997934c7
This commit is contained in:
bharadwajambati1 2019-08-21 09:28:54 -04:00
parent fc5975b285
commit a4460a9947
4 changed files with 33 additions and 12 deletions

View file

@ -261,7 +261,7 @@ function upgradeNetwork() {
docker-compose $COMPOSE_FILES up -d --no-deps $PEER docker-compose $COMPOSE_FILES up -d --no-deps $PEER
done done
docker exec cli scripts/upgrade_to_v14.sh $CHANNEL_NAME $CLI_DELAY $LANGUAGE $CLI_TIMEOUT $VERBOSE docker exec cli sh -c "SYS_CHANNEL=$CH_NAME && scripts/upgrade_to_v14.sh $CHANNEL_NAME $CLI_DELAY $LANGUAGE $CLI_TIMEOUT $VERBOSE"
if [ $? -ne 0 ]; then if [ $? -ne 0 ]; then
echo "ERROR !!!! Test failed" echo "ERROR !!!! Test failed"
exit 1 exit 1

View file

@ -12,6 +12,7 @@ OrdererOrgs:
# --------------------------------------------------------------------------- # ---------------------------------------------------------------------------
- Name: Orderer - Name: Orderer
Domain: example.com Domain: example.com
EnableNodeOUs: true
# --------------------------------------------------------------------------- # ---------------------------------------------------------------------------
# "Specs" - See PeerOrgs below for complete description # "Specs" - See PeerOrgs below for complete description
# --------------------------------------------------------------------------- # ---------------------------------------------------------------------------

View file

@ -1,9 +1,29 @@
{ {
"mod_policy": "Admins", "channel": {
"value": { "mod_policy": "Admins",
"capabilities": { "value": {
"V1_4_2": {} "capabilities": {
} "V1_4_3": {}
}, }
"version": "0" },
"version": "0"
},
"orderer": {
"mod_policy": "Admins",
"value": {
"capabilities": {
"V1_4_2": {}
}
},
"version": "0"
},
"application": {
"mod_policy": "Admins",
"value": {
"capabilities": {
"V1_4_2": {}
}
},
"version": "0"
}
} }

View file

@ -49,11 +49,11 @@ addCapabilityToChannel() {
# Modify the correct section of the config based on capabilities group # Modify the correct section of the config based on capabilities group
if [ $GROUP == "orderer" ]; then if [ $GROUP == "orderer" ]; then
jq -s '.[0] * {"channel_group":{"groups":{"Orderer": {"values": {"Capabilities": .[1]}}}}}' config.json ./scripts/capabilities.json > modified_config.json jq -s '.[0] * {"channel_group":{"groups":{"Orderer": {"values": {"Capabilities": .[1].orderer}}}}}' config.json ./scripts/capabilities.json > modified_config.json
elif [ $GROUP == "channel" ]; then elif [ $GROUP == "channel" ]; then
jq -s '.[0] * {"channel_group":{"values": {"Capabilities": .[1]}}}' config.json ./scripts/capabilities.json > modified_config.json jq -s '.[0] * {"channel_group":{"values": {"Capabilities": .[1].channel}}}' config.json ./scripts/capabilities.json > modified_config.json
elif [ $GROUP == "application" ]; then elif [ $GROUP == "application" ]; then
jq -s '.[0] * {"channel_group":{"groups":{"Application": {"values": {"Capabilities": .[1]}}}}}' config.json ./scripts/capabilities.json > modified_config.json jq -s '.[0] * {"channel_group":{"groups":{"Application": {"values": {"Capabilities": .[1].application}}}}}' config.json ./scripts/capabilities.json > modified_config.json
fi fi
# Create a config updated for this channel based on the differences between config.json and modified_config.json # Create a config updated for this channel based on the differences between config.json and modified_config.json