github.com/IBM-Blockchain/fabric-operator@v1.0.4/api/v1beta1/ibppeer_types.go (about) 1 /* 2 * Copyright contributors to the Hyperledger Fabric Operator project 3 * 4 * SPDX-License-Identifier: Apache-2.0 5 * 6 * Licensed under the Apache License, Version 2.0 (the "License"); 7 * you may not use this file except in compliance with the License. 8 * You may obtain a copy of the License at: 9 * 10 * http://www.apache.org/licenses/LICENSE-2.0 11 * 12 * Unless required by applicable law or agreed to in writing, software 13 * distributed under the License is distributed on an "AS IS" BASIS, 14 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 15 * See the License for the specific language governing permissions and 16 * limitations under the License. 17 */ 18 19 package v1beta1 20 21 import ( 22 corev1 "k8s.io/api/core/v1" 23 metav1 "k8s.io/apimachinery/pkg/apis/meta/v1" 24 "k8s.io/apimachinery/pkg/runtime" 25 ) 26 27 // NOTE: json tags are required. Any new fields you add must have json tags for the fields to be serialized. 28 29 // +k8s:openapi-gen=true 30 // +k8s:deepcopy-gen=true 31 // IBPPeerSpec defines the desired state of IBPPeer 32 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 33 type IBPPeerSpec struct { 34 // License should be accepted by the user to be able to setup Peer 35 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 36 License License `json:"license"` 37 38 /* generic configs - images/resources/storage/servicetype/version/replicas */ 39 40 // Images (Optional) lists the images to be used for peer's deployment 41 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 42 Images *PeerImages `json:"images,omitempty"` 43 44 // RegistryURL is registry url used to pull images 45 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 46 RegistryURL string `json:"registryURL,omitempty"` 47 48 // ImagePullSecrets (Optional) is the list of ImagePullSecrets to be used for peer's deployment 49 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 50 ImagePullSecrets []string `json:"imagePullSecrets,omitempty"` 51 52 // Replicas (Optional - default 1) is the number of peer replicas to be setup 53 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 54 Replicas *int32 `json:"replicas,omitempty"` 55 56 // Resources (Optional) is the amount of resources to be provided to peer deployment 57 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 58 Resources *PeerResources `json:"resources,omitempty"` 59 60 // Service (Optional) is the override object for peer's service 61 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 62 Service *Service `json:"service,omitempty"` 63 64 // Storage (Optional - uses default storageclass if not provided) is the override object for peer's PVC config 65 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 66 Storage *PeerStorages `json:"storage,omitempty"` 67 68 /* peer specific configs */ 69 // MSPID is the msp id of the peer 70 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 71 MSPID string `json:"mspID,omitempty"` 72 73 // StateDb (Optional) is the statedb used for peer, can be couchdb or leveldb 74 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 75 StateDb string `json:"stateDb,omitempty"` 76 77 // ConfigOverride (Optional) is the object to provide overrides to core yaml config 78 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 79 // +kubebuilder:validation:Type=object 80 // +kubebuilder:validation:Schemaless 81 // +kubebuilder:pruning:PreserveUnknownFields 82 ConfigOverride *runtime.RawExtension `json:"configoverride,omitempty"` 83 84 // HSM (Optional) is DEPRECATED 85 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 86 HSM *HSM `json:"hsm,omitempty"` 87 88 // DisableNodeOU (Optional) is used to switch nodeou on and off 89 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 90 DisableNodeOU *bool `json:"disablenodeou,omitempty"` 91 92 // CustomNames (Optional) is to use pre-configured resources for peer's deployment 93 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 94 CustomNames PeerCustomNames `json:"customNames,omitempty"` 95 96 // FabricVersion (Optional) is fabric version for the peer 97 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 98 FabricVersion string `json:"version"` 99 100 // NumSecondsWarningPeriod (Optional - default 30 days) is used to define certificate expiry warning period. 101 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 102 NumSecondsWarningPeriod int64 `json:"numSecondsWarningPeriod,omitempty"` 103 104 /* msp data can be passed in secret on in spec */ 105 // MSPSecret (Optional) is secret used to store msp crypto 106 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 107 MSPSecret string `json:"mspSecret,omitempty"` 108 109 // Secret is object for msp crypto 110 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 111 Secret *SecretSpec `json:"secret,omitempty"` 112 113 /* proxy ip passed if not OCP, domain for OCP */ 114 // Domain is the sub-domain used for peer's deployment 115 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 116 Domain string `json:"domain,omitempty"` 117 118 // Ingress (Optional) is ingress object for ingress overrides 119 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 120 Ingress Ingress `json:"ingress,omitempty"` 121 122 // PeerExternalEndpoint (Optional) is used to override peer external endpoint 123 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 124 PeerExternalEndpoint string `json:"peerExternalEndpoint,omitempty"` 125 126 /* cluster related configs */ 127 // Arch (Optional) is the architecture of the nodes where peer should be deployed 128 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 129 Arch []string `json:"arch,omitempty"` 130 131 // Region (Optional) is the region of the nodes where the peer should be deployed 132 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 133 Region string `json:"region,omitempty"` 134 135 // Zone (Optional) is the zone of the nodes where the peer should be deployed 136 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 137 Zone string `json:"zone,omitempty"` 138 139 /* advanced configs */ 140 // DindArgs (Optional) is used to override args passed to dind container 141 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 142 DindArgs []string `json:"dindArgs,omitempty"` 143 144 // Action (Optional) is object for peer actions 145 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 146 Action PeerAction `json:"action,omitempty"` 147 148 // ChaincodeBuilderConfig (Optional) is a k/v map providing a scope for template 149 // substitutions defined in chaincode-as-a-service package metadata files. 150 // The map will be serialized as JSON and set in the peer deployment 151 // CHAINCODE_AS_A_SERVICE_BUILDER_CONFIG env variable. 152 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 153 ChaincodeBuilderConfig ChaincodeBuilderConfig `json:"chaincodeBuilderConfig,omitempty"` 154 } 155 156 // +k8s:openapi-gen=true 157 // +k8s:deepcopy-gen=true 158 // IBPPeerStatus defines the observed state of IBPPeer 159 // +operator-sdk:gen-csv:customresourcedefinitions.statusDescriptors=true 160 type IBPPeerStatus struct { 161 CRStatus `json:",inline"` 162 } 163 164 // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object 165 // +k8s:openapi-gen=true 166 // +kubebuilder:storageversion 167 // +k8s:deepcopy-gen=true 168 // +kubebuilder:subresource:status 169 // IBPPeer is the Schema for the ibppeers API. 170 // Warning: Peer deployment using this tile is not supported. Please use the IBP Console to deploy a Peer. 171 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 172 // +operator-sdk:gen-csv:customresourcedefinitions.displayName="IBP Peer" 173 // +operator-sdk:gen-csv:customresourcedefinitions.resources=`Deployments,v1,""` 174 // +operator-sdk:gen-csv:customresourcedefinitions.resources=`Ingresses,v1beta1,""` 175 // +operator-sdk:gen-csv:customresourcedefinitions.resources=`PersistentVolumeClaim,v1,""` 176 // +operator-sdk:gen-csv:customresourcedefinitions.resources=`Role,v1,""` 177 // +operator-sdk:gen-csv:customresourcedefinitions.resources=`RoleBinding,v1,""` 178 // +operator-sdk:gen-csv:customresourcedefinitions.resources=`Route,v1,""` 179 // +operator-sdk:gen-csv:customresourcedefinitions.resources=`Services,v1,""` 180 // +operator-sdk:gen-csv:customresourcedefinitions.resources=`ServiceAccounts,v1,""` 181 // +operator-sdk:gen-csv:customresourcedefinitions.resources=`ConfigMaps,v1,""` 182 // +operator-sdk:gen-csv:customresourcedefinitions.resources=`Secrets,v1,""` 183 // +operator-sdk:gen-csv:customresourcedefinitions.resources=`Pods,v1,""` 184 // +operator-sdk:gen-csv:customresourcedefinitions.resources=`Replicasets,v1,""` 185 // +operator-sdk:gen-csv:customresourcedefinitions.resources=`IBPCA,v1beta1,""` 186 // +operator-sdk:gen-csv:customresourcedefinitions.resources=`IBPPeer,v1beta1,""` 187 // +operator-sdk:gen-csv:customresourcedefinitions.resources=`IBPOrderer,v1beta1,""` 188 // +operator-sdk:gen-csv:customresourcedefinitions.resources=`IBPConsole,v1beta1,""` 189 // +operator-sdk:gen-csv:customresourcedefinitions.resources=`clusterversions,v1,""` 190 type IBPPeer struct { 191 metav1.TypeMeta `json:",inline"` 192 metav1.ObjectMeta `json:"metadata,omitempty"` 193 194 Spec IBPPeerSpec `json:"spec"` 195 // +operator-sdk:gen-csv:customresourcedefinitions.statusDescriptors=true 196 Status IBPPeerStatus `json:"status,omitempty"` 197 } 198 199 // +k8s:deepcopy-gen:interfaces=k8s.io/apimachinery/pkg/runtime.Object 200 // +k8s:deepcopy-gen=true 201 // IBPPeerList contains a list of IBPPeer 202 type IBPPeerList struct { 203 metav1.TypeMeta `json:",inline"` 204 metav1.ListMeta `json:"metadata,omitempty"` 205 Items []IBPPeer `json:"items"` 206 } 207 208 // +k8s:deepcopy-gen=true 209 // PeerResources is the overrides to the resources of the peer 210 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 211 type PeerResources struct { 212 // Init (Optional) is the resources provided to the init container 213 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 214 Init *corev1.ResourceRequirements `json:"init,omitempty"` 215 216 /// Peer (Optional) is the resources provided to the peer container 217 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 218 Peer *corev1.ResourceRequirements `json:"peer,omitempty"` 219 220 // GRPCProxy (Optional) is the resources provided to the proxy container 221 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 222 GRPCProxy *corev1.ResourceRequirements `json:"proxy,omitempty"` 223 224 // FluentD (Optional) is the resources provided to the fluentd container 225 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 226 FluentD *corev1.ResourceRequirements `json:"fluentd,omitempty"` 227 228 // DinD (Optional) is the resources provided to the dind container 229 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 230 DinD *corev1.ResourceRequirements `json:"dind,omitempty"` 231 232 // CouchDB (Optional) is the resources provided to the couchdb container 233 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 234 CouchDB *corev1.ResourceRequirements `json:"couchdb,omitempty"` 235 236 // CCLauncher (Optional) is the resources provided to the cclauncher container 237 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 238 CCLauncher *corev1.ResourceRequirements `json:"chaincodelauncher,omitempty"` 239 240 // Enroller (Optional) is the resources provided to the enroller container 241 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 242 Enroller *corev1.ResourceRequirements `json:"enroller,omitempty"` 243 244 // HSMDaemon (Optional) is the resources provided to the HSM Daemon container 245 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 246 HSMDaemon *corev1.ResourceRequirements `json:"hsmdaemon,omitempty"` 247 } 248 249 // +k8s:deepcopy-gen=true 250 // PeerStorages is the overrides to the storage of the peer 251 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 252 type PeerStorages struct { 253 // StateDB (Optional) is the configuration of the storage of the statedb 254 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 255 StateDB *StorageSpec `json:"statedb,omitempty"` 256 257 // Peer (Optional) is the configuration of the storage of the peer 258 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 259 Peer *StorageSpec `json:"peer,omitempty"` 260 } 261 262 // PeerImages is the list of images to be used in peer deployment 263 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 264 type PeerImages struct { 265 // PeerInitImage is the name of the peer init image 266 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 267 PeerInitImage string `json:"peerInitImage,omitempty"` 268 269 // PeerInitTag is the tag of the peer init image 270 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 271 PeerInitTag string `json:"peerInitTag,omitempty"` 272 273 // PeerImage is the name of the peer image 274 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 275 PeerImage string `json:"peerImage,omitempty"` 276 277 // PeerTag is the tag of the peer image 278 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 279 PeerTag string `json:"peerTag,omitempty"` 280 281 // DindImage is the name of the dind image 282 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 283 DindImage string `json:"dindImage,omitempty"` 284 285 // DindTag is the tag of the dind image 286 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 287 DindTag string `json:"dindTag,omitempty"` 288 289 // GRPCWebImage is the name of the grpc web proxy image 290 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 291 GRPCWebImage string `json:"grpcwebImage,omitempty"` 292 293 // GRPCWebTag is the tag of the grpc web proxy image 294 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 295 GRPCWebTag string `json:"grpcwebTag,omitempty"` 296 297 // FluentdImage is the name of the fluentd logger image 298 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 299 FluentdImage string `json:"fluentdImage,omitempty"` 300 301 // FluentdTag is the tag of the fluentd logger image 302 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 303 FluentdTag string `json:"fluentdTag,omitempty"` 304 305 // CouchDBImage is the name of the couchdb image 306 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 307 CouchDBImage string `json:"couchdbImage,omitempty"` 308 309 // CouchDBTag is the tag of the couchdb image 310 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 311 CouchDBTag string `json:"couchdbTag,omitempty"` 312 313 // CCLauncherImage is the name of the chaincode launcher image 314 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 315 CCLauncherImage string `json:"chaincodeLauncherImage,omitempty"` 316 317 // CCLauncherTag is the tag of the chaincode launcher image 318 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 319 CCLauncherTag string `json:"chaincodeLauncherTag,omitempty"` 320 321 // FileTransferImage is the name of the file transfer image 322 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 323 FileTransferImage string `json:"fileTransferImage,omitempty"` 324 325 // FileTransferTag is the tag of the file transfer image 326 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 327 FileTransferTag string `json:"fileTransferTag,omitempty"` 328 329 // BuilderImage is the name of the builder image 330 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 331 BuilderImage string `json:"builderImage,omitempty"` 332 333 // BuilderTag is the tag of the builder image 334 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 335 BuilderTag string `json:"builderTag,omitempty"` 336 337 // GoEnvImage is the name of the goenv image 338 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 339 GoEnvImage string `json:"goEnvImage,omitempty"` 340 341 // GoEnvTag is the tag of the goenv image 342 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 343 GoEnvTag string `json:"goEnvTag,omitempty"` 344 345 // JavaEnvImage is the name of the javaenv image 346 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 347 JavaEnvImage string `json:"javaEnvImage,omitempty"` 348 349 // JavaEnvTag is the tag of the javaenv image 350 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 351 JavaEnvTag string `json:"javaEnvTag,omitempty"` 352 353 // NodeEnvImage is the name of the nodeenv image 354 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 355 NodeEnvImage string `json:"nodeEnvImage,omitempty"` 356 357 // NodeEnvTag is the tag of the nodeenv image 358 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 359 NodeEnvTag string `json:"nodeEnvTag,omitempty"` 360 361 // HSMImage is the name of the hsm image 362 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 363 HSMImage string `json:"hsmImage,omitempty"` 364 365 // HSMTag is the tag of the hsm image 366 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 367 HSMTag string `json:"hsmTag,omitempty"` 368 369 // EnrollerImage is the name of the init image for crypto generation 370 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 371 EnrollerImage string `json:"enrollerImage,omitempty"` 372 373 // EnrollerTag is the tag of the init image for crypto generation 374 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 375 EnrollerTag string `json:"enrollerTag,omitempty"` 376 } 377 378 // +k8s:deepcopy-gen=true 379 // PeerConnectionProfile provides necessary information to connect to the peer 380 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 381 type PeerConnectionProfile struct { 382 // Endpoints is list of endpoints to communicate with the peer 383 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 384 Endpoints PeerEndpoints `json:"endpoints"` 385 386 // TLS is object with tls crypto material for peer 387 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 388 TLS *MSP `json:"tls"` 389 390 // Component is object with ecert crypto material for peer 391 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 392 Component *MSP `json:"component"` 393 } 394 395 // PeerEndpoints is the list of endpoints to communicate with the peer 396 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 397 type PeerEndpoints struct { 398 // API is the endpoint to communicate with peer's API 399 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 400 API string `json:"api"` 401 402 // Operations is the endpoint to communicate with peer's Operations API 403 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 404 Operations string `json:"operations"` 405 406 // Grpcweb is the endpoint to communicate with peers's grpcweb proxy API 407 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 408 Grpcweb string `json:"grpcweb"` 409 } 410 411 // +k8s:deepcopy-gen=true 412 // PeerCustomNames is the list of preconfigured objects to be used for peer's deployment 413 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 414 type PeerCustomNames struct { 415 // PVC is the list of PVC Names to be used for peer's deployment 416 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 417 PVC PeerPVCNames `json:"pvc,omitempty"` 418 } 419 420 // PeerPVCNames is the list of PVC Names to be used for peer's deployment 421 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 422 type PeerPVCNames struct { 423 // Peer is the pvc to be used as peer's storage 424 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 425 Peer string `json:"peer,omitempty"` 426 427 // StateDB is the pvc to be used as statedb's storage 428 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 429 StateDB string `json:"statedb,omitempty"` 430 } 431 432 // Action contains actions that can be performed on peer 433 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 434 type PeerAction struct { 435 // Restart action is used to restart peer deployment 436 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 437 Restart bool `json:"restart,omitempty"` 438 439 // Reenroll contains actions for triggering crypto reenroll 440 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 441 Reenroll PeerReenrollAction `json:"reenroll,omitempty"` 442 443 // Enroll contains actions for triggering crypto enroll 444 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 445 Enroll PeerEnrollAction `json:"enroll,omitempty"` 446 447 // UpgradeDBs action is used to trigger peer node upgrade-dbs command 448 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 449 UpgradeDBs bool `json:"upgradedbs,omitempty"` 450 } 451 452 // PeerReenrollAction contains actions for reenrolling crypto 453 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 454 type PeerReenrollAction struct { 455 // Ecert is used to trigger reenroll for ecert 456 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 457 Ecert bool `json:"ecert,omitempty"` 458 459 // EcertNewKey is used to trigger reenroll for ecert and also generating 460 // a new private key 461 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 462 EcertNewKey bool `json:"ecertNewKey,omitempty"` 463 464 // TLSCert is used to trigger reenroll for tlscert 465 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 466 TLSCert bool `json:"tlscert,omitempty"` 467 468 // TLSCertNewKey is used to trigger reenroll for tlscert and also generating 469 // a new private key 470 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 471 TLSCertNewKey bool `json:"tlscertNewKey,omitempty"` 472 } 473 474 // PeerReenrollAction contains actions for enrolling crypto 475 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 476 type PeerEnrollAction struct { 477 // Ecert is used to trigger enroll for ecert 478 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 479 Ecert bool `json:"ecert,omitempty"` 480 481 // TLSCert is used to trigger enroll for tlscert 482 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 483 TLSCert bool `json:"tlscert,omitempty"` 484 } 485 486 // ChaincodeBuilderConfig defines a k/v mapping scope for template substitutions 487 // referenced within a chaincode package archive. The mapping is serialized as 488 // JSON and appended to the peer env as CHAINCODE_AS_A_SERVICE_BUILDER_CONFIG. 489 // +operator-sdk:gen-csv:customresourcedefinitions.specDescriptors=true 490 type ChaincodeBuilderConfig map[string]string