Also install goimports globally to run the linting check rather than installing to each gomodule, which was causing dependency conflicts.
Signed-off-by: Mark S. Lewis <mark_lewis@uk.ibm.com>
The `-i` flag was originally added to support an
upgrade sample. Since that sample is no longer available
remove the `-i` flag to clean up the network.sh options
and avoid confusion as it's possible now to specify
an image version that is no longer backwards compatible
with the new test-network with osnadmin.
Signed-off-by: Brett Logan <lindluni@github.com>
* Fix creating channel when ${PWD} contains space.
If the path of the project contains spaces, the "test-network/scripts/envVar.sh" script sets the value of "$ORDERER_CA" to a value containg "${PWD}" which, in turn, contains space(s).
When the variable used in "test-network/scripts/createChannel.sh", The first part of the value (before the first space) is handled as the whole value for "--cafile". Other parts are considered to be part of the command!
I tried putting (escaped) quotes in the "test-network/scripts/envVar.sh" definition for the variable "$ORDERER_CA" to make the fix more general, but the quotation marks were sometime interpreted to be part of the path that consisted of concatenated parts somewhere and it did not work.
While this edit will fix this issue, I belive this is just a work around. I expect that there is a better way to solve the root cause of the problem instead of just fixing it in one place. Moreover, All variables/paths that may include spaces should be properly handled as well.
Thanks
Signed-off-by: Waleed Mortaja <waleedmortaja@protonmail.com>
* Double quote variables evaluations that depends on $PWD
I tried to handle most (if not all) of the variables evaluations in the project that depends on $PWD by wrapping them in double-quotations to avoid values that contains white spaces.
Some lines I was not sure if they are Okay or not but I left them as they are. Samples (not all lines) as follows:
- commercial-paper/network-clean.sh:15:DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
- commercial-paper/network-starter.sh:15:DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
- asset-transfer-basic/chaincode-javascript/node_modules/fabric-shim/coverage/fabric-shim/lib/chaincode.js.html:997: optsCpy.pem = fs.readFileSync(process.env.CORE_PEER_TLS_ROOTCERT_FILE).toString();
- commercial-paper/organization/digibank/digibank.sh:29:export PEER_PARMS="${PEER_CONN_PARMS##*( )}"
The next sample I was not really sure, but still edited it:
- test-network/addOrg3/fabric-ca/registerEnroll.sh:68: cp ${PWD}/../organizations/peerOrganizations/org3.example.com/peers/peer0.org3.example.com/tls/tlscacerts/* ${PWD}/../organizations/peerOrganizations/org3.example.com/peers/peer0.org3.example.com/tls/ca.crt
I deliberately ignored some lines because I think they are not problem. These lines include:
- `export` sentences
- assignment sentences like: test-network/scripts/createChannel.sh:48: FABRIC_CFG_PATH=$PWD/../config/
- gradlew files: the line SAVED="`pwd`"
- gradlew files: the line APP_HOME="`pwd -P`"
- gradlew files: the line CLASSPATH=$APP_HOME/gradle/wrapper/gradle-wrapper.jar
Signed-off-by: Waleed Mortaja <waleedmortaja@protonmail.com>
* remove unnecessary leading space trimming
Signed-off-by: Waleed Mortaja <waleedmortaja@protonmail.com>
* resolved conflict with master
Co-authored-by: Arnaud J Le Hors <lehors@us.ibm.com>
Instead of mounted the entire /var/run directory
explicitly mount the unix socket. Mounting the entire
directory causes issues with future versions of Docker
on some platforms.
Signed-off-by: Brett Logan <brett.t.logan@ibm.com>
In Fabric v2.2, the gossip defaults are changed to make
peers org leaders instead of using leader election.
This change removes the config from the samples, so that
the samples simply inherit the new peer defaults.
This will simplify the sample configuration.
Signed-off-by: David Enyeart <enyeart@us.ibm.com>
Description
The use of Orderer.Addresses in configtx.yaml is deprecated, and Organizations.<Org>.OrdererEndpoints should be used instead. Therefore, update all the fabric-samples configtx.yaml files.
Related issues
https://jira.hyperledger.org/browse/FAB-17504
Signed-off-by: xu wu <wuxu1103@163.com>
It includes two config changes in fabric recently:
* GenesisMethod --> BootstrapMethod
* GenesisFile --> BootstrapFile
Signed-off-by: Baohua Yang <yangbaohua@gmail.com>
Signed-off-by: Baohua Yang <baohua.yang@oracle.com>
Using V2_0_0 capabilities will turn on identification of admins
via node OU, and will fix the failing sample since cryptogen
is now setup to generate admins via node OU.
Change-Id: I30ff651a112bd88c93f6563f5e4414f8d2c6693e
Signed-off-by: David Enyeart <enyeart@us.ibm.com>
All samples that deploy Go chaincode must now vendor
their dependencies before deployment, due to changes
in FAB-5177 which stop the shim being available at
deployment time. This CR adds the command:
"GO111MODULE=on go mod vendor"
... to all scripts/readmes as appropriate.
Signed-off-by: Simon Stone <sstone1@uk.ibm.com>
Change-Id: If0a2cc3a20dc943917d8325a8905427a79eb2400
Update samples now that QueryApprovalStatus has been renamed
to SimulateCommitChaincodeDefinition.
FAB-15831 #done
Change-Id: I4e12ca2c8424bf8d6537e77e1a9de7fd3723636d
Signed-off-by: Will Lahti <wtlahti@us.ibm.com>
This CR removes the unused variable 'OS_ARCH' from byfn.sh,
eyfn.sh and interest swap in fabric-samples.
FAB-9329 #done
Change-Id: I0d1b87679d66bec1d9e4aaee9e770305f9c8f4b9
Signed-off-by: Yuki Kondo <yuki.kondo@hal.hitachi.com>
Fix misspellings of "Prerequesites" to "Prerequisites",
and "prinicpal" to "principal"
Change-Id: I1024cc0f720bedddee3286b2520ab3824d7a1d5b
Signed-off-by: Daisuke IIZUKA <daisuke.iizuka.ag@hitachi.com>
This is an example on how to represent and implement basic interest
rate swap handling using fabric. It demonstrates the
usage of state-based endorsement.
Change-Id: I04e631299d95262e54e1532489766aa20477064c
Signed-off-by: Matthias Neugschwandtner <eug@zurich.ibm.com>
Signed-off-by: Alessandro Sorniotti <ale.linux@sopit.net>
Signed-off-by: David Enyeart <enyeart@us.ibm.com>