k8s

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Sep 28, 2021 License: MIT Imports: 11 Imported by: 0

Documentation

Overview

Package k8s is a generated GoMock package.

Index

Constants

View Source
const (
	// Mutual TLS auth client key and cert paths in the chaincode container.
	TLSClientKeyPath      string = "/etc/hyperledger/fabric/client.key"
	TLSClientCertPath     string = "/etc/hyperledger/fabric/client.crt"
	TLSClientRootCertPath string = "/etc/hyperledger/fabric/peer.crt"

	TLSClientKeyFile      string = "/etc/hyperledger/fabric/client_pem.key"
	TLSClientCertFile     string = "/etc/hyperledger/fabric/client_pem.crt"
	TLSClientRootCertFile string = "/etc/hyperledger/fabric/peer.crt"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type K8sClient

type K8sClient struct {
	// contains filtered or unexported fields
}

func (*K8sClient) CreateChaincodeDeployment

func (k8s *K8sClient) CreateChaincodeDeployment(
	ctx context.Context,
	name string,
	image string,
	env []string,
	cmd []string,
) error

func (*K8sClient) CreateConfigMap

func (k8s *K8sClient) CreateConfigMap(ctx context.Context, name string, data map[string]string) error

func (*K8sClient) DeleteChaincodeDeployment

func (k8s *K8sClient) DeleteChaincodeDeployment(ctx context.Context, name string) error

func (*K8sClient) DeleteConfigMapDeployment

func (k8s *K8sClient) DeleteConfigMapDeployment(ctx context.Context, name string) error

func (*K8sClient) QueryDeploymentStatus

func (k8s *K8sClient) QueryDeploymentStatus(ctx context.Context, name string) (bool, error)

func (*K8sClient) UpdateDeployment

func (k8s *K8sClient) UpdateDeployment(ctx context.Context, name string) error

type K8sService

type K8sService interface {
	CreateChaincodeDeployment(ctx context.Context, name string, image string, env []string, cmd []string) error
	UpdateDeployment(ctx context.Context, name string) error
	CreateConfigMap(ctx context.Context, name string, data map[string]string) error
	DeleteChaincodeDeployment(ctx context.Context, name string) error
	DeleteConfigMapDeployment(ctx context.Context, name string) error
	QueryDeploymentStatus(ctx context.Context, name string) (bool, error)
}

func NewK8sService

func NewK8sService(opt *options.K8sOption) (K8sService, error)

NewK8sService.

type MockK8sService

type MockK8sService struct {
	// contains filtered or unexported fields
}

MockK8sService is a mock of K8sService interface.

func NewMockK8sService

func NewMockK8sService(ctrl *gomock.Controller) *MockK8sService

NewMockK8sService creates a new mock instance.

func (*MockK8sService) CreateChaincodeDeployment

func (m *MockK8sService) CreateChaincodeDeployment(arg0 context.Context, arg1, arg2 string, arg3, arg4 []string) error

CreateChaincodeDeployment mocks base method.

func (*MockK8sService) CreateConfigMap

func (m *MockK8sService) CreateConfigMap(arg0 context.Context, arg1 string, arg2 map[string]string) error

CreateConfigMap mocks base method.

func (*MockK8sService) DeleteChaincodeDeployment

func (m *MockK8sService) DeleteChaincodeDeployment(arg0 context.Context, arg1 string) error

DeleteChaincodeDeployment mocks base method.

func (*MockK8sService) DeleteConfigMapDeployment

func (m *MockK8sService) DeleteConfigMapDeployment(arg0 context.Context, arg1 string) error

DeleteConfigMapDeployment mocks base method.

func (*MockK8sService) EXPECT

EXPECT returns an object that allows the caller to indicate expected use.

func (*MockK8sService) QueryDeploymentStatus

func (m *MockK8sService) QueryDeploymentStatus(arg0 context.Context, arg1 string) (bool, error)

QueryDeploymentStatus mocks base method.

func (*MockK8sService) UpdateDeployment

func (m *MockK8sService) UpdateDeployment(arg0 context.Context, arg1 string) error

UpdateDeployment mocks base method.

type MockK8sServiceMockRecorder

type MockK8sServiceMockRecorder struct {
	// contains filtered or unexported fields
}

MockK8sServiceMockRecorder is the mock recorder for MockK8sService.

func (*MockK8sServiceMockRecorder) CreateChaincodeDeployment

func (mr *MockK8sServiceMockRecorder) CreateChaincodeDeployment(arg0, arg1, arg2, arg3, arg4 interface{}) *gomock.Call

CreateChaincodeDeployment indicates an expected call of CreateChaincodeDeployment.

func (*MockK8sServiceMockRecorder) CreateConfigMap

func (mr *MockK8sServiceMockRecorder) CreateConfigMap(arg0, arg1, arg2 interface{}) *gomock.Call

CreateConfigMap indicates an expected call of CreateConfigMap.

func (*MockK8sServiceMockRecorder) DeleteChaincodeDeployment

func (mr *MockK8sServiceMockRecorder) DeleteChaincodeDeployment(arg0, arg1 interface{}) *gomock.Call

DeleteChaincodeDeployment indicates an expected call of DeleteChaincodeDeployment.

func (*MockK8sServiceMockRecorder) DeleteConfigMapDeployment

func (mr *MockK8sServiceMockRecorder) DeleteConfigMapDeployment(arg0, arg1 interface{}) *gomock.Call

DeleteConfigMapDeployment indicates an expected call of DeleteConfigMapDeployment.

func (*MockK8sServiceMockRecorder) QueryDeploymentStatus

func (mr *MockK8sServiceMockRecorder) QueryDeploymentStatus(arg0, arg1 interface{}) *gomock.Call

QueryDeploymentStatus indicates an expected call of QueryDeploymentStatus.

func (*MockK8sServiceMockRecorder) UpdateDeployment

func (mr *MockK8sServiceMockRecorder) UpdateDeployment(arg0, arg1 interface{}) *gomock.Call

UpdateDeployment indicates an expected call of UpdateDeployment.

Jump to

Keyboard shortcuts

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