Documentation ¶
Index ¶
- Constants
- type IBPOperatorClient
- type Kube
- type Peer
- func (peer *Peer) CreateCR(domain, sID, compName, namespace string, body []byte) (*api.Response, int, error)
- func (peer *Peer) DeleteCR(sID, compName, namespace string, body []byte) (*api.DeleteResponse, int, error)
- func (peer *Peer) GetAllCR(sID, namespace string) ([]api.Response, int, error)
- func (peer *Peer) GetCR(section, compName, namespace, sID string) (*api.Response, int, error)
- func (peer *Peer) GetCRResponse(section, compName, namespace, sID string) (*api.Response, int, error)
- func (peer *Peer) GetConfig(compName, namespace string, fabricVersion string) (interface{}, error)
- func (peer *Peer) GetConnectionProfile(compName, namespace string) (*common.ConnectionProfile, error)
- func (peer *Peer) GetIndividualResources(individualResources string, allResources *current.PeerResources, ...) *current.PeerResources
- func (peer *Peer) GetResources(defaults current.PeerResources, override *current.PeerResources, ...) *current.PeerResources
- func (peer *Peer) GetStorage(defaults *dconfig.DeployerDefaults, override *current.PeerStorages) *current.PeerStorages
- func (peer *Peer) GetUpdateResources(current, override *current.PeerResources) (*current.PeerResources, error)
- func (peer *Peer) Images(version string) *current.PeerImages
- func (p *Peer) PatchCR(section, compName, namespace, sID string, body []byte) (*api.Response, int, error)
- func (p *Peer) UpdateCR(section, compName, namespace, sID string, body []byte) (*api.Response, int, error)
Constants ¶
View Source
const ( PortNameOperations = "operations" PortNamePeerGrpc = "peer-api" PortNameGrpcWeb = "grpcweb" EndpointHttpURLTemplate = "https://%s:%s" EndpointGrpcURLTemplate = "grpcs://%s:%s" )
View Source
const ( ACTIONS = "actions" RESOURCES = "resources" CONFIG = "config" CRYPTO = "crypto" ADMINCERTS = "admincerts" NODEOU = "nodeou" VERSION = "version" STORAGE = "storage" STATUS = "status" ENDPOINTS = "endpoints" REPLICAS = "replicas" HSM = "hsm" ALL = "all" )
Supported actions for Peer
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type IBPOperatorClient ¶
type IBPOperatorClient interface { GetCR(namespace string, kind string, name string, cr runtime.Object) error GetAllCR(namespace string, kind string, cr runtime.Object) error CreateCR(namespace string, kind string, cr interface{}) error DeleteCR(namespace string, kind string, name string) error UpdateCR(namespace string, kind string, name string, bytes []byte) error PatchCR(namespace string, kind string, name string, bytes []byte) error }
type Kube ¶
type Kube interface { GetService(namespace, name string) (*corev1.Service, error) GetConfigMap(namespace, name string) (*corev1.ConfigMap, error) DeleteAndCreateSecret(namespace string, secret *corev1.Secret) (*corev1.Secret, error) DeleteSecret(namespace string, name string) error GetPort(namespace, name string) (int32, error) GetPorts(namespace, name string) ([]corev1.ServicePort, error) CreateSecret(namespace string, secret *corev1.Secret) (*corev1.Secret, error) }
type Peer ¶
type Peer struct { Kube Kube Logger *zap.SugaredLogger IBPOperatorClient IBPOperatorClient Config *dconfig.DeployerSettingsConfig }
func New ¶
func New(logger *zap.Logger, k8sClient Kube, ibpClient IBPOperatorClient, config *dconfig.DeployerSettingsConfig) *Peer
func (*Peer) GetCRResponse ¶
func (*Peer) GetConnectionProfile ¶
func (peer *Peer) GetConnectionProfile(compName, namespace string) (*common.ConnectionProfile, error)
func (*Peer) GetIndividualResources ¶
func (peer *Peer) GetIndividualResources(individualResources string, allResources *current.PeerResources, fabricVersion, statedb string) *current.PeerResources
func (*Peer) GetResources ¶
func (peer *Peer) GetResources(defaults current.PeerResources, override *current.PeerResources, statedb, fabricVersion string) *current.PeerResources
func (*Peer) GetStorage ¶
func (peer *Peer) GetStorage(defaults *dconfig.DeployerDefaults, override *current.PeerStorages) *current.PeerStorages
func (*Peer) GetUpdateResources ¶
func (peer *Peer) GetUpdateResources(current, override *current.PeerResources) (*current.PeerResources, error)
Click to show internal directories.
Click to hide internal directories.