Reputation: 13
It is possible to configure a single organization, to act both as peer and orderer organization, at the same time?
And also, if possible, can an example be provided? More specifically, using the first-network from fabric-samples as template, with both cryptogen and cryptotxgen cli, to generate all the certificates, and also using docker-compose to bring the network up.
I've tried it out, but had some trouble instantiating the code at the peer node.
Upvotes: 1
Views: 297
Reputation: 2200
Yes, it is possible, but not recommended. From https://hyperledger-fabric.readthedocs.io/en/release-1.4/Fabric-FAQ.html#ordering-service:
Question: Can I have an organization act both in an ordering and application role? Answer: Although this is possible, it is a highly discouraged configuration. By default the /Channel/Orderer/BlockValidation policy allows any valid certificate of the ordering organizations to sign blocks. If an organization is acting both in an ordering and application role, then this policy should be updated to restrict block signers to the subset of certificates authorized for ordering.
I have also experienced strange behaviours getting peers from those organizations join to channels they are not allowed to (although they are not able to synchronize with the channel later).
I have done using Fabric-CA. With cryptogen
you probably have to declare those organizations as if they were orderers, so that peers will also have their cryptographic material under ../ordererOrganizations/
.
Upvotes: 1