peer

package
v1.0.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 19, 2020 License: Apache-2.0 Imports: 35 Imported by: 0

Documentation

Index

Constants

View Source
const ChaincodePortName = "chaincode"
View Source
const EventPortName = "event"
View Source
const OperationsPortName = "operations"
View Source
const PeerPortName = "peer"

Variables

This section is empty.

Functions

func CreateSignCryptoMaterial

func CreateSignCryptoMaterial(conf *hlfv1alpha1.FabricPeer, caName string, caurl string, enrollID string, enrollSecret string, tlsCertString string) (*x509.Certificate, *ecdsa.PrivateKey, *x509.Certificate, error)

func CreateTLSCryptoMaterial

func CreateTLSCryptoMaterial(conf *hlfv1alpha1.FabricPeer, caName string, caurl string, enrollID string, enrollSecret string, tlsCertString string, hosts []string) (*x509.Certificate, *ecdsa.PrivateKey, *x509.Certificate, error)

func CreateTLSOPSCryptoMaterial

func CreateTLSOPSCryptoMaterial(conf *hlfv1alpha1.FabricPeer, caName string, caurl string, enrollID string, enrollSecret string, tlsCertString string, hosts []string) (*x509.Certificate, *ecdsa.PrivateKey, *x509.Certificate, error)

Types

type Affinity

type Affinity struct {
}

type Annotations

type Annotations struct {
}

type Client

type Client struct {
	Enabled bool `json:"enabled"`
}

type FabricPeerChart

type FabricPeerChart struct {
	ExternalChaincodeBuilder bool            `json:"externalChaincodeBuilder"`
	CouchdbUsername          string          `json:"couchdbUsername"`
	CouchdbPassword          string          `json:"couchdbPassword"`
	Image                    Image           `json:"image"`
	Rbac                     RBAC            `json:"rbac"`
	DockerSocketPath         string          `json:"dockerSocketPath"`
	Ingress                  Ingress         `json:"ingress"`
	Peer                     Peer            `json:"peer"`
	Cert                     string          `json:"cert"`
	Key                      string          `json:"key"`
	Hosts                    []string        `json:"hosts"`
	OperationHosts           []string        `json:"operationHosts"`
	TLS                      TLS             `json:"tls"`
	OPSTLS                   TLS             `json:"opsTLS"`
	Cacert                   string          `json:"cacert"`
	Tlsrootcert              string          `json:"tlsrootcert"`
	Resources                Resources       `json:"resources,omitempty"`
	NodeSelector             NodeSelector    `json:"nodeSelector,omitempty"`
	Tolerations              []interface{}   `json:"tolerations"`
	Affinity                 Affinity        `json:"affinity,omitempty"`
	ExternalHost             string          `json:"externalHost"`
	FullnameOverride         string          `json:"fullnameOverride"`
	HostAliases              []HostAliases   `json:"hostAliases"`
	Service                  Service         `json:"service"`
	Persistence              PeerPersistence `json:"persistence"`
	Logging                  Logging         `json:"logging"`
}

func GetConfig

func GetConfig(conf *hlfv1alpha1.FabricPeer, client *kubernetes.Clientset, chartName string, namespace string, svc *corev1.Service) (*FabricPeerChart, error)

type FabricPeerReconciler

type FabricPeerReconciler struct {
	client.Client
	ChartPath string
	Log       logr.Logger
	Scheme    *runtime.Scheme
	Config    *rest.Config
}

FabricPeerReconciler reconciles a FabricPeer object

func (*FabricPeerReconciler) Reconcile

func (r *FabricPeerReconciler) Reconcile(req ctrl.Request) (ctrl.Result, error)

func (*FabricPeerReconciler) SetupWithManager

func (r *FabricPeerReconciler) SetupWithManager(mgr ctrl.Manager) error

type Gossip

type Gossip struct {
	Bootstrap         string `json:"bootstrap"`
	Endpoint          string `json:"endpoint"`
	ExternalEndpoint  string `json:"externalEndpoint"`
	OrgLeader         bool   `json:"orgLeader"`
	UseLeaderElection bool   `json:"useLeaderElection"`
}

type HostAliases

type HostAliases struct {
	IP        string   `json:"ip"`
	Hostnames []string `json:"hostnames"`
}

type Image

type Image struct {
	Repository string `json:"repository"`
	Tag        string `json:"tag"`
	PullPolicy string `json:"pullPolicy"`
}

type Ingress

type Ingress struct {
	Enabled     bool          `json:"enabled"`
	Annotations Annotations   `json:"annotations"`
	Path        string        `json:"path"`
	Hosts       []string      `json:"hosts"`
	TLS         []interface{} `json:"tls"`
}

type Limits

type Limits struct {
	CPU    string `json:"cpu"`
	Memory string `json:"memory"`
}

type Logging

type Logging struct {
	Level    string `json:"level"`
	Peer     string `json:"peer"`
	Cauthdsl string `json:"cauthdsl"`
	Gossip   string `json:"gossip"`
	Grpc     string `json:"grpc"`
	Ledger   string `json:"ledger"`
	Msp      string `json:"msp"`
	Policies string `json:"policies"`
}

type NodeSelector

type NodeSelector struct {
}

type Peer

type Peer struct {
	DatabaseType    string  `json:"databaseType"`
	CouchdbInstance string  `json:"couchdbInstance"`
	MspID           string  `json:"mspID"`
	Gossip          Gossip  `json:"gossip"`
	TLS             TLSAuth `json:"tls"`
}

type PeerPersistence

type PeerPersistence struct {
	Peer      Persistence `json:"peer"`
	CouchDB   Persistence `json:"couchdb"`
	Chaincode Persistence `json:"chaincode"`
}

type Persistence

type Persistence struct {
	Enabled      bool        `json:"enabled"`
	Annotations  Annotations `json:"annotations"`
	StorageClass string      `json:"storageClass"`
	AccessMode   string      `json:"accessMode"`
	Size         string      `json:"size"`
}

type RBAC

type RBAC struct {
	Ns string `json:"ns"`
}

type Requests

type Requests struct {
	CPU    string `json:"cpu"`
	Memory string `json:"memory"`
}

type Resources

type Resources struct {
	Limits   Limits   `json:"limits"`
	Requests Requests `json:"requests"`
}

type Server

type Server struct {
	Enabled bool `json:"enabled"`
}

type Service

type Service struct {
	Type               string `json:"type"`
	PortRequest        int    `json:"portRequest"`
	PortEvent          int    `json:"portEvent"`
	PortOperations     int    `json:"portOperations"`
	NodePortOperations int    `json:"nodePortOperations,omitempty"`
	NodePortEvent      int    `json:"nodePortEvent,omitempty"`
	NodePortRequest    int    `json:"nodePortRequest,omitempty"`
}

type Status

type Status struct {
	URL     string
	Status  hlfv1alpha1.DeploymentStatus
	TLSCert string
}

func GetPeerState

func GetPeerState(peer *hlfv1alpha1.FabricPeer, conf *action.Configuration, config *rest.Config, releaseName string, ns string, svc *corev1.Service) (*Status, error)

type TLS

type TLS struct {
	Cert string `json:"cert"`
	Key  string `json:"key"`
}

type TLSAuth

type TLSAuth struct {
	Server Server `json:"server"`
	Client Client `json:"client"`
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL