@@ -85,7 +85,7 @@ prompt. Respond with a ``y`` to execute the described action.
85
85
Generating certs and genesis block for with channel ' mychannel' and CLI timeout of ' 10000'
86
86
Continue (y/n)? y
87
87
proceeding ...
88
- /Users/xxx/dev/byfn /bin/cryptogen
88
+ /Users/xxx/dev/fabric-samples /bin/cryptogen
89
89
90
90
# #########################################################
91
91
# #### Generate certificates using cryptogen tool #########
@@ -94,7 +94,7 @@ prompt. Respond with a ``y`` to execute the described action.
94
94
2017-06-12 21:01:37.334 EDT [bccsp] GetDefault -> WARN 001 Before using BCCSP, please call InitFactories (). Falling back to bootBCCSP.
95
95
...
96
96
97
- /Users/xxx/dev/byfn /bin/configtxgen
97
+ /Users/xxx/dev/fabric-samples /bin/configtxgen
98
98
# #########################################################
99
99
# ######## Generating Orderer Genesis block ##############
100
100
# #########################################################
@@ -143,7 +143,7 @@ will be prompted as to whether you wish to continue or abort. Respond with a
143
143
Starting with channel ' mychannel' and CLI timeout of ' 10000'
144
144
Continue (y/n)? y
145
145
proceeding ...
146
- Creating network " byfntest_default " with the default driver
146
+ Creating network " net_byfn " with the default driver
147
147
Creating peer0.org1.example.com
148
148
Creating peer1.org1.example.com
149
149
Creating peer0.org2.example.com
@@ -204,7 +204,7 @@ Once again, you will be prompted to continue, respond with a ``y``:
204
204
proceeding ...
205
205
WARNING: The CHANNEL_NAME variable is not set. Defaulting to a blank string.
206
206
WARNING: The TIMEOUT variable is not set. Defaulting to a blank string.
207
- Removing network byfn_default
207
+ Removing network net_byfn
208
208
468aaa6201ed
209
209
...
210
210
Untagged: dev-peer1.org2.example.com-mycc-1.0:latest
@@ -344,7 +344,7 @@ directory, so we need to provide the relative path to where the tool resides.
344
344
345
345
.. code :: bash
346
346
347
- ./bin/cryptogen generate --config=./crypto-config.yaml
347
+ .. /bin/cryptogen generate --config=./crypto-config.yaml
348
348
349
349
You will likely see the following warning. It's innocuous, ignore it:
350
350
@@ -363,7 +363,7 @@ should look for the configtx.yaml configuration file. Then, we'll invoke the
363
363
.. code :: bash
364
364
365
365
export FABRIC_CFG_PATH=$PWD
366
- ./bin/configtxgen -profile TwoOrgsOrdererGenesis -outputBlock ./channel-artifacts/genesis.block
366
+ .. /bin/configtxgen -profile TwoOrgsOrdererGenesis -outputBlock ./channel-artifacts/genesis.block
367
367
368
368
You can ignore the log warnings regarding intermediate certificates, certificate
369
369
revocation lists (crls) and MSP configurations. We are not using any of those
@@ -381,21 +381,21 @@ Next, we need to create the channel transaction artifact. Be sure to set the
381
381
.. code :: bash
382
382
383
383
# this file contains the definitions for our sample channel
384
- ./bin/configtxgen -profile TwoOrgsChannel -outputCreateChannelTx ./channel-artifacts/channel.tx -channelID < channel-ID>
384
+ .. /bin/configtxgen -profile TwoOrgsChannel -outputCreateChannelTx ./channel-artifacts/channel.tx -channelID < channel-ID>
385
385
386
386
Next, we will define the anchor peer for Org1 on the channel that we are
387
387
constructing. Again, be sure to set the <channel-ID> parameter as appropriate
388
388
for the following commands:
389
389
390
390
.. code :: bash
391
391
392
- ./bin/configtxgen -profile TwoOrgsChannel -outputAnchorPeersUpdate ./channel-artifacts/Org1MSPanchors.tx -channelID < channel-ID> -asOrg Org1MSP
392
+ .. /bin/configtxgen -profile TwoOrgsChannel -outputAnchorPeersUpdate ./channel-artifacts/Org1MSPanchors.tx -channelID < channel-ID> -asOrg Org1MSP
393
393
394
394
Now, we will define the anchor peer for Org2 on the same channel:
395
395
396
396
.. code :: bash
397
397
398
- ./bin/configtxgen -profile TwoOrgsChannel -outputAnchorPeersUpdate ./channel-artifacts/Org2MSPanchors.tx -channelID < channel-ID> -asOrg Org2MSP
398
+ .. /bin/configtxgen -profile TwoOrgsChannel -outputAnchorPeersUpdate ./channel-artifacts/Org2MSPanchors.tx -channelID < channel-ID> -asOrg Org2MSP
399
399
400
400
Start the network
401
401
-----------------
@@ -451,8 +451,10 @@ paths:
451
451
CORE_PEER_LOCALMSPID=" Org1MSP"
452
452
CORE_PEER_TLS_ROOTCERT_FILE=/opt/gopath/src/github.com/hyperledger/fabric/peer/crypto/peerOrganizations/org1.example.com/peers/peer0.org1.example.com/tls/ca.crt
453
453
454
+ .. _createandjoin :
455
+
454
456
Create & Join Channel
455
- ^^^^^^^^^^^^^^^^^^^^
457
+ ^^^^^^^^^^^^^^^^^^^^^
456
458
457
459
We will enter the CLI container using the ``docker exec `` command:
458
460
@@ -539,7 +541,7 @@ If we changed the syntax to ``AND`` then we would need two endorsements.
539
541
# be sure to replace the $CHANNEL_NAME environment variable
540
542
# if you did not install your chaincode with a name of mycc, then modify that argument as well
541
543
542
- peer chaincode instantiate -o orderer.example.com:7050 --tls $CORE_PEER_TLS_ENABLED --cafile /opt/gopath/src/github.com/hyperledger/fabric/peer/crypto/ordererOrganizations/example.com/orderers/orderer.example.com/msp/cacerts/ca.example.com-cert.pem -C $CHANNEL_NAME -n mycc -v 1.0 -p github.com/hyperledger/fabric/examples/chaincode/go/chaincode_example02 - c ' {"Args":["init","a", "100", "b","200"]}' -P " OR ('Org1MSP.member','Org2MSP.member')"
544
+ peer chaincode instantiate -o orderer.example.com:7050 --tls $CORE_PEER_TLS_ENABLED --cafile /opt/gopath/src/github.com/hyperledger/fabric/peer/crypto/ordererOrganizations/example.com/orderers/orderer.example.com/msp/cacerts/ca.example.com-cert.pem -C $CHANNEL_NAME -n mycc -v 1.0 -c ' {"Args":["init","a", "100", "b","200"]}' -P " OR ('Org1MSP.member','Org2MSP.member')"
543
545
544
546
See the `endorsement
545
547
policies <http://hyperledger-fabric.readthedocs.io/en/latest/endorsement-policies.html> `__
@@ -740,9 +742,8 @@ Understanding the docker-compose topology
740
742
The BYFN sample offers us two flavors of docker-compose files, both of which
741
743
are extended from the ``docker-compose-base.yaml `` (located in the ``base ``
742
744
folder). Our first flavor, ``docker-compose-cli.yaml ``, provides us with a
743
- CLI container, along with an orderer, four peers, and the optional couchDB
744
- containers. We use this docker-compose for the entirety of the instructions
745
- on this page.
745
+ CLI container, along with an orderer, four peers. We use this docker-compose
746
+ for the entirety of the instructions on this page.
746
747
747
748
.. note :: the remainder of this section covers a docker-compose file designed for the
748
749
SDK. Refer to the `Node.js SDK <https://github.com/hyperledger/fabric-sdk-node >`__
@@ -754,7 +755,7 @@ is that there are containers for the fabric-ca servers. As a result, we are abl
754
755
to send REST calls to the organizational CAs for user registration and enrollment.
755
756
756
757
If you want to use the ``docker-compose-e2e.yaml `` without first running the
757
- ** All in one ** script, then we will need to make four slight modifications.
758
+ byfn.sh script, then we will need to make four slight modifications.
758
759
We need to point to the private keys for our Organization's CA's. You can locate
759
760
these values in your crypto-config folder. For example, to locate the private
760
761
key for Org1 we would follow this path - ``crypto-config/peerOrganizations/org1.example.com/ca/ ``.
@@ -799,9 +800,8 @@ capabilities you will need to use a chaincode that has data modeled as JSON,
799
800
``fabric/examples/chaincode/go `` directory.
800
801
801
802
We will follow the same process to create and join the channel as outlined in the
802
- **Manually exercise the commands ** section above. Once you have joined your
803
- peer(s) to the channel, use the following steps to interact with the **marbles02 **
804
- chaincode:
803
+ :ref: `createandjoin ` section above. Once you have joined your peer(s) to the
804
+ channel, use the following steps to interact with the **marbles02 ** chaincode:
805
805
806
806
- Install and instantiate the chaincode on ``peer0.org1.example.com ``:
807
807
@@ -810,7 +810,7 @@ chaincode:
810
810
# be sure to modify the $CHANNEL_NAME variable accordingly for the instantiate command
811
811
812
812
peer chaincode install -o orderer.example.com:7050 -n marbles -v 1.0 -p github.com/hyperledger/fabric/examples/chaincode/go/marbles02
813
- peer chaincode instantiate -o orderer.example.com:7050 --tls $CORE_PEER_TLS_ENABLED --cafile /opt/gopath/src/github.com/hyperledger/fabric/peer/crypto/ordererOrganizations/example.com/orderers/orderer.example.com/msp/cacerts/ca.example.com-cert.pem -C $CHANNEL_NAME -n marbles -v 1.0 -p github.com/hyperledger/fabric/examples/chaincode/go/marbles02 - c ' {"Args":["init"]}' -P " OR ('Org0MSP.member','Org1MSP.member')"
813
+ peer chaincode instantiate -o orderer.example.com:7050 --tls $CORE_PEER_TLS_ENABLED --cafile /opt/gopath/src/github.com/hyperledger/fabric/peer/crypto/ordererOrganizations/example.com/orderers/orderer.example.com/msp/cacerts/ca.example.com-cert.pem -C $CHANNEL_NAME -n marbles -v 1.0 -c ' {"Args":["init"]}' -P " OR ('Org0MSP.member','Org1MSP.member')"
814
814
815
815
- Create some marbles and move them around:
816
816
0 commit comments