@@ -41,19 +41,19 @@ Usage of configtxgen:
41
41
### Output a genesis block
42
42
43
43
Write a genesis block to ` genesis_block.pb ` for channel ` orderer-system-channel `
44
- for profile ` SampleSingleMSPSolo ` .
44
+ for profile ` SampleSingleMSPSoloV1_1 ` .
45
45
46
46
```
47
- configtxgen -outputBlock genesis_block.pb -profile SampleSingleMSPSolo -channelID orderer-system-channel
47
+ configtxgen -outputBlock genesis_block.pb -profile SampleSingleMSPSoloV1_1 -channelID orderer-system-channel
48
48
```
49
49
50
50
### Output a channel creation tx
51
51
52
52
Write a channel creation transaction to ` create_chan_tx.pb ` for profile
53
- ` SampleSingleMSPChannel ` .
53
+ ` SampleSingleMSPChannelV1_1 ` .
54
54
55
55
```
56
- configtxgen -outputCreateChannelTx create_chan_tx.pb -profile SampleSingleMSPChannel -channelID application-channel-1
56
+ configtxgen -outputCreateChannelTx create_chan_tx.pb -profile SampleSingleMSPChannelV1_1 -channelID application-channel-1
57
57
```
58
58
59
59
### Inspect a genesis block
@@ -87,9 +87,40 @@ configtxgen -printOrg Org1
87
87
### Output anchor peer tx
88
88
89
89
Output a configuration update transaction to ` anchor_peer_tx.pb ` which sets the
90
- anchor peers for organization Org1 as defined in profile SampleSingleMSPChannel
91
- based on ` configtx.yaml ` .
90
+ anchor peers for organization Org1 as defined in profile
91
+ SampleSingleMSPChannelV1_1 based on ` configtx.yaml ` .
92
92
93
93
```
94
- configtxgen -outputAnchorPeersUpdate anchor_peer_tx.pb -profile SampleSingleMSPChannel -asOrg Org1
94
+ configtxgen -outputAnchorPeersUpdate anchor_peer_tx.pb -profile SampleSingleMSPChannelV1_1 -asOrg Org1
95
95
```
96
+
97
+ ## Configuration
98
+
99
+ The ` configtxgen ` tool's output is largely controlled by the content of
100
+ ` configtx.yaml ` . This file is searched for at ` FABRIC_CFG_PATH ` and must be
101
+ present for ` configtxgen ` to operate.
102
+
103
+ This configuration file may be edited, or, individual properties may be
104
+ overridden by setting environment variables, such as
105
+ ` CONFIGTX_ORDERER_ORDERERTYPE=kafka ` .
106
+
107
+ For many ` configtxgen ` operations, a profile name must be supplied. Profiles
108
+ are a way to express multiple similar configurations in a single file. For
109
+ instance, one profile might define a channel with 3 orgs, and another might
110
+ define one with 4 orgs. To accomplish this without the length of the file
111
+ becoming burdensome, ` configtx.yaml ` depends on the standard YAML feature of
112
+ anchors and references. Base parts of the configuration are tagged with an
113
+ anchor like ` &OrdererDefaults ` and then merged into a profile with a reference
114
+ like ` <<: *OrdererDefaults ` . Note, when ` configtxgen ` is operating under a
115
+ profile, environment variable overrides do not need to include the profile
116
+ prefix and may be referenced relative to the root element of the profile. For
117
+ instance, do not specify
118
+ ` CONFIGTX_PROFILE_SAMPLEINSECURESOLO_ORDERER_ORDERERTYPE ` ,
119
+ instead simply omit the profile specifics and use the ` CONFIGTX ` prefix
120
+ followed by the elements relative to the profile name such as
121
+ ` CONFIGTX_ORDERER_ORDERERTYPE ` .
122
+
123
+ Refer to the sample ` configtx.yaml ` shipped with Fabric for all possible
124
+ configuration options. You may find this file in the ` config ` directory of
125
+ the release artifacts tar, or you may find it under the ` sampleconfig ` folder
126
+ if you are building from source.
0 commit comments