github.com/yimialmonte/fabric@v2.1.1+incompatible/discovery/test/testdata/configtx.yaml (about)

     1  # Copyright IBM Corp. All Rights Reserved.
     2  #
     3  # SPDX-License-Identifier: Apache-2.0
     4  #
     5  
     6  ---
     7  ################################################################################
     8  #
     9  #   Section: Organizations
    10  #
    11  #   - This section defines the different organizational identities which will
    12  #   be referenced later in the configuration.
    13  #
    14  ################################################################################
    15  Organizations:
    16      # SampleOrg defines an MSP using the sampleconfig.  It should never be used
    17      # in production but may be used as a template for other definitions
    18      - &OrdererOrg
    19          # DefaultOrg defines the organization which is used in the sampleconfig
    20          # of the fabric.git development environment
    21          Name: OrdererOrg
    22  
    23          # ID to load the MSP definition as
    24          ID: OrdererMSP
    25  
    26          # MSPDir is the filesystem path which contains the MSP configuration
    27          MSPDir: crypto-config/ordererOrganizations/example.com/msp
    28  
    29          # Policies defines the set of policies at this level of the config tree
    30          # For organization policies, their canonical path is usually
    31          #   /Channel/<Application|Orderer>/<OrgName>/<PolicyName>
    32          Policies:
    33              Readers:
    34                  Type: Signature
    35                  Rule: "OR('OrdererMSP.member')"
    36              Writers:
    37                  Type: Signature
    38                  Rule: "OR('OrdererMSP.member')"
    39              Admins:
    40                  Type: Signature
    41                  Rule: "OR('OrdererMSP.admin')"
    42  
    43      - &Org1
    44          # DefaultOrg defines the organization which is used in the sampleconfig
    45          # of the fabric.git development environment
    46          Name: Org1MSP
    47  
    48          # ID to load the MSP definition as
    49          ID: Org1MSP
    50  
    51          MSPDir: crypto-config/peerOrganizations/org1.example.com/msp
    52  
    53          # Policies defines the set of policies at this level of the config tree
    54          # For organization policies, their canonical path is usually
    55          #   /Channel/<Application|Orderer>/<OrgName>/<PolicyName>
    56          Policies:
    57              Readers:
    58                  Type: Signature
    59                  Rule: "OR('Org1MSP.admin', 'Org1MSP.peer', 'Org1MSP.client')"
    60              Writers:
    61                  Type: Signature
    62                  Rule: "OR('Org1MSP.admin', 'Org1MSP.client')"
    63              Admins:
    64                  Type: Signature
    65                  Rule: "OR('Org1MSP.admin')"
    66              Endorsement:
    67                  Type: Signature
    68                  Rule: "OR('Org1MSP.peer')"
    69  
    70          # leave this flag set to true.
    71          AnchorPeers:
    72              # AnchorPeers defines the location of peers which can be used
    73              # for cross org gossip communication.  Note, this value is only
    74              # encoded in the genesis block in the Application section context
    75              - Host: peer0.org1.example.com
    76                Port: 7051
    77  
    78      - &Org2
    79          # DefaultOrg defines the organization which is used in the sampleconfig
    80          # of the fabric.git development environment
    81          Name: Org2MSP
    82  
    83          # ID to load the MSP definition as
    84          ID: Org2MSP
    85  
    86          MSPDir: crypto-config/peerOrganizations/org2.example.com/msp
    87  
    88          # Policies defines the set of policies at this level of the config tree
    89          # For organization policies, their canonical path is usually
    90          #   /Channel/<Application|Orderer>/<OrgName>/<PolicyName>
    91          Policies:
    92              Readers:
    93                  Type: Signature
    94                  Rule: "OR('Org2MSP.admin', 'Org2MSP.peer', 'Org2MSP.client')"
    95              Writers:
    96                  Type: Signature
    97                  Rule: "OR('Org2MSP.admin', 'Org2MSP.client')"
    98              Admins:
    99                  Type: Signature
   100                  Rule: "OR('Org2MSP.admin')"
   101              Endorsement:
   102                  Type: Signature
   103                  Rule: "OR('Org2MSP.peer')"
   104  
   105          AnchorPeers:
   106              # AnchorPeers defines the location of peers which can be used
   107              # for cross org gossip communication.  Note, this value is only
   108              # encoded in the genesis block in the Application section context
   109              - Host: peer0.org2.example.com
   110                Port: 9051
   111  
   112  ################################################################################
   113  #
   114  #   SECTION: Capabilities
   115  #
   116  #   - This section defines the capabilities of fabric network. This is a new
   117  #   concept as of v1.1.0 and should not be utilized in mixed networks with
   118  #   v1.0.x peers and orderers.  Capabilities define features which must be
   119  #   present in a fabric binary for that binary to safely participate in the
   120  #   fabric network.  For instance, if a new MSP type is added, newer binaries
   121  #   might recognize and validate the signatures from this type, while older
   122  #   binaries without this support would be unable to validate those
   123  #   transactions.  This could lead to different versions of the fabric binaries
   124  #   having different world states.  Instead, defining a capability for a channel
   125  #   informs those binaries without this capability that they must cease
   126  #   processing transactions until they have been upgraded.  For v1.0.x if any
   127  #   capabilities are defined (including a map with all capabilities turned off)
   128  #   then the v1.0.x peer will deliberately crash.
   129  #
   130  ################################################################################
   131  Capabilities:
   132      # Channel capabilities apply to both the orderers and the peers and must be
   133      # supported by both.
   134      # Set the value of the capability to true to require it.
   135      Channel: &ChannelCapabilities
   136          # V1.3 for Channel is a catchall flag for behavior which has been
   137          # determined to be desired for all orderers and peers running at the v1.3.x
   138          # level, but which would be incompatible with orderers and peers from
   139          # prior releases.
   140          # Prior to enabling V1.3 channel capabilities, ensure that all
   141          # orderers and peers on a channel are at v1.3.0 or later.
   142          V1_3: true
   143  
   144      # Orderer capabilities apply only to the orderers, and may be safely
   145      # used with prior release peers.
   146      # Set the value of the capability to true to require it.
   147      Orderer: &OrdererCapabilities
   148          # V1.1 for Orderer is a catchall flag for behavior which has been
   149          # determined to be desired for all orderers running at the v1.1.x
   150          # level, but which would be incompatible with orderers from prior releases.
   151          # Prior to enabling V1.1 orderer capabilities, ensure that all
   152          # orderers on a channel are at v1.1.0 or later.
   153          V1_1: true
   154  
   155      # Application capabilities apply only to the peer network, and may be safely
   156      # used with prior release orderers.
   157      # Set the value of the capability to true to require it.
   158      Application: &ApplicationCapabilities
   159          # V2.0 for Application enables the new non-backwards compatible
   160          # features and fixes of fabric v2.0.
   161          V2_0: true
   162          # V1.3 for Application enables the new non-backwards compatible
   163          # features and fixes of fabric v1.3 (note, this need not be set if
   164          # later version capabilities are set)
   165          V1_3: false
   166          # V1.2 for Application enables the new non-backwards compatible
   167          # features and fixes of fabric v1.2 (note, this need not be set if
   168          # later version capabilities are set)
   169          V1_2: false
   170          # V1.1 for Application enables the new non-backwards compatible
   171          # features and fixes of fabric v1.1 (note, this need not be set if
   172          # later version capabilities are set).
   173          V1_1: false
   174  
   175  ################################################################################
   176  #
   177  #   SECTION: Application
   178  #
   179  #   - This section defines the values to encode into a config transaction or
   180  #   genesis block for application related parameters
   181  #
   182  ################################################################################
   183  Application: &ApplicationDefaults
   184      # Organizations is the list of orgs which are defined as participants on
   185      # the application side of the network
   186      Organizations:
   187  
   188      # Policies defines the set of policies at this level of the config tree
   189      # For Application policies, their canonical path is
   190      #   /Channel/Application/<PolicyName>
   191      Policies:
   192          Readers:
   193              Type: ImplicitMeta
   194              Rule: "ANY Readers"
   195          Writers:
   196              Type: ImplicitMeta
   197              Rule: "ANY Writers"
   198          Admins:
   199              Type: ImplicitMeta
   200              Rule: "MAJORITY Admins"
   201          LifecycleEndorsement:
   202              Type: ImplicitMeta
   203              Rule: "MAJORITY Endorsement"
   204          Endorsement:
   205              Type: ImplicitMeta
   206              Rule: "MAJORITY Endorsement"
   207  
   208      Capabilities:
   209          <<: *ApplicationCapabilities
   210  
   211  ################################################################################
   212  #
   213  #   SECTION: Orderer
   214  #
   215  #   - This section defines the values to encode into a config transaction or
   216  #   genesis block for orderer related parameters
   217  #
   218  ################################################################################
   219  Orderer: &OrdererDefaults
   220      # Orderer Type: The orderer implementation to start
   221      # Available types are "solo" and "kafka"
   222      OrdererType: solo
   223  
   224      Addresses:
   225          - orderer.example.com:7050
   226  
   227      # Batch Timeout: The amount of time to wait before creating a batch
   228      BatchTimeout: 2s
   229  
   230      # Batch Size: Controls the number of messages batched into a block
   231      BatchSize:
   232  
   233          # Max Message Count: The maximum number of messages to permit in a batch
   234          MaxMessageCount: 10
   235  
   236          # Absolute Max Bytes: The absolute maximum number of bytes allowed for
   237          # the serialized messages in a batch.
   238          AbsoluteMaxBytes: 99 MB
   239  
   240          # Preferred Max Bytes: The preferred maximum number of bytes allowed for
   241          # the serialized messages in a batch. A message larger than the preferred
   242          # max bytes will result in a batch larger than preferred max bytes.
   243          PreferredMaxBytes: 512 KB
   244  
   245      Kafka:
   246          # Brokers: A list of Kafka brokers to which the orderer connects
   247          # NOTE: Use IP:port notation
   248          Brokers:
   249              - 127.0.0.1:9092
   250  
   251      # Organizations is the list of orgs which are defined as participants on
   252      # the orderer side of the network
   253      Organizations:
   254  
   255      # Policies defines the set of policies at this level of the config tree
   256      # For Orderer policies, their canonical path is
   257      #   /Channel/Orderer/<PolicyName>
   258      Policies:
   259          Readers:
   260              Type: ImplicitMeta
   261              Rule: "ANY Readers"
   262          Writers:
   263              Type: ImplicitMeta
   264              Rule: "ANY Writers"
   265          Admins:
   266              Type: ImplicitMeta
   267              Rule: "MAJORITY Admins"
   268          # BlockValidation specifies what signatures must be included in the block
   269          # from the orderer for the peer to validate it.
   270          BlockValidation:
   271              Type: ImplicitMeta
   272              Rule: "ANY Writers"
   273  
   274  ################################################################################
   275  #
   276  #   CHANNEL
   277  #
   278  #   This section defines the values to encode into a config transaction or
   279  #   genesis block for channel related parameters.
   280  #
   281  ################################################################################
   282  Channel: &ChannelDefaults
   283      # Policies defines the set of policies at this level of the config tree
   284      # For Channel policies, their canonical path is
   285      #   /Channel/<PolicyName>
   286      Policies:
   287          # Who may invoke the 'Deliver' API
   288          Readers:
   289              Type: ImplicitMeta
   290              Rule: "ANY Readers"
   291          # Who may invoke the 'Broadcast' API
   292          Writers:
   293              Type: ImplicitMeta
   294              Rule: "ANY Writers"
   295          # By default, who may modify elements at this config level
   296          Admins:
   297              Type: ImplicitMeta
   298              Rule: "MAJORITY Admins"
   299  
   300      # Capabilities describes the channel level capabilities, see the
   301      # dedicated Capabilities section elsewhere in this file for a full
   302      # description
   303      Capabilities:
   304          <<: *ChannelCapabilities
   305  
   306  ################################################################################
   307  #
   308  #   Profile
   309  #
   310  #   - Different configuration profiles may be encoded here to be specified
   311  #   as parameters to the configtxgen tool
   312  #
   313  ################################################################################
   314  Profiles:
   315      TwoOrgsOrdererGenesis:
   316          <<: *ChannelDefaults
   317          Orderer:
   318              <<: *OrdererDefaults
   319              Organizations:
   320                  - *OrdererOrg
   321              Capabilities:
   322                  <<: *OrdererCapabilities
   323          Consortiums:
   324              SampleConsortium:
   325                  Organizations:
   326                      - *Org1
   327                      - *Org2
   328      TwoOrgsChannel:
   329          Consortium: SampleConsortium
   330          <<: *ChannelDefaults
   331          Application:
   332              <<: *ApplicationDefaults
   333              Organizations:
   334                  - *Org1
   335                  - *Org2
   336              Capabilities:
   337                  <<: *ApplicationCapabilities