ca

package
v0.0.0-...-fdd9b93 Latest Latest
Warning

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

Go to latest
Published: Aug 15, 2022 License: Apache-2.0 Imports: 15 Imported by: 0

Documentation

Index

Constants

View Source
const (
	PortNameOperations  = "operations"
	PortNameHttp        = "http"
	EndpointURLTemplate = "https://%s:%s"
)
View Source
const (
	ACTIONS   = "actions"
	RESOURCES = "resources"
	STORAGE   = "storage"
	STATUS    = "status"
	CONFIG    = "config"
	VERSION   = "version"
	ENDPOINTS = "endpoints"
	REPLICAS  = "replicas"
	HSM       = "hsm"
	CRYPTO    = "crypto"
	ALL       = "all"
)

Supported actions for CA

Variables

This section is empty.

Functions

This section is empty.

Types

type CA

type CA struct {
	Kube              Kube
	Logger            *zap.SugaredLogger
	IBPOperatorClient IBPOperatorClient
	Config            *config.DeployerSettingsConfig
}

func New

func New(logger *zap.Logger, k8sClient Kube, ibpClient IBPOperatorClient, config *config.DeployerSettingsConfig) *CA

func (*CA) CheckReplicas

func (ca *CA) CheckReplicas(replicas *int32, configOverride *current.ConfigOverride) error

func (*CA) CreateCR

func (ca *CA) CreateCR(domain, sID, compName, namespace string, body []byte) (*api.Response, int, error)

func (*CA) DeleteCR

func (ca *CA) DeleteCR(sID, compName, namespace string, body []byte) (*api.DeleteResponse, int, error)

func (*CA) GetAllCR

func (ca *CA) GetAllCR(sID, namespace string) ([]api.Response, int, error)

func (*CA) GetCANames

func (ca *CA) GetCANames(caSpec current.IBPCASpec) (string, string, error)

func (*CA) GetCR

func (ca *CA) GetCR(section, compName, namespace, sID string) (*api.Response, int, error)

func (*CA) GetCRResponse

func (ca *CA) GetCRResponse(section, compName, namespace, sID string) (*api.Response, int, error)

func (*CA) GetConfig

func (ca *CA) GetConfig(compName, namespace, caType string) (*ibpca.ServerConfig, error)

func (*CA) GetConnectionProfile

func (ca *CA) GetConnectionProfile(compName, namespace string) (*api.ConnectionProfile, error)

func (*CA) GetDefaultVersion

func (ca *CA) GetDefaultVersion() string

func (*CA) GetIndividualResources

func (ca *CA) GetIndividualResources(allResources *current.CAResources) *current.CAResources

func (*CA) GetResourceForResponse

func (ca *CA) GetResourceForResponse(resources *current.CAResources) (*util.ResourceReturn, *current.CAResources)

func (*CA) GetResources

func (ca *CA) GetResources(defaults *config.DeployerDefaults, override *current.CAResources) *current.CAResources

func (*CA) GetStorage

func (ca *CA) GetStorage(defaults *config.DeployerDefaults, override *current.CAStorages) *current.CAStorages

func (*CA) Images

func (ca *CA) Images(version string) *current.CAImages

func (*CA) PatchCR

func (ca *CA) PatchCR(section, compName, namespace, sID string, body []byte) (*api.Response, int, error)

func (*CA) UpdateCR

func (ca *CA) UpdateCR(section, compName, namespace, sID string, body []byte) (*api.Response, int, error)

type IBPOperatorClient

type IBPOperatorClient interface {
	GetCR(namespace string, kind string, name string, cr runtime.Object) error
	GetAllCR(namespace string, kind string, crlist 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)
	GetPort(namespace, name string) (int32, error)
	GetPorts(namespace, name string) ([]corev1.ServicePort, error)
}

Directories

Path Synopsis
Code generated by counterfeiter.
Code generated by counterfeiter.

Jump to

Keyboard shortcuts

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