deployment

package
v1.7.2 Latest Latest
Warning

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

Go to latest
Published: Oct 16, 2023 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DefaultConfigMap

func DefaultConfigMap(id, name, namespace string) map[string]*ConfigMapConfig

func DefaultSecretConfig

func DefaultSecretConfig(id, name, namespace string) map[string]*SecretConfig

func DefaultServiceConfig

func DefaultServiceConfig(id, namespace, appName string) map[string]*ServiceConfig

Types

type Config

type Config struct {
	Id          string
	Name        string
	Namespace   string
	StatefulSet *StatefulSetConfig
	Services    map[string]*ServiceConfig
	ConfigMaps  map[string]*ConfigMapConfig
	Secrets     map[string]*SecretConfig
}

func DefaultKubeMQManifestConfig

func DefaultKubeMQManifestConfig(id, name, namespace string, standalone bool) *Config

func NewKubeMQManifestConfig

func NewKubeMQManifestConfig(id, name, namespace string) *Config

func (*Config) SetConfigMapDataValues

func (c *Config) SetConfigMapDataValues(cmName, key, value string)

func (*Config) SetConfigMapStringValues

func (c *Config) SetConfigMapStringValues(cmName, key, value string)

func (*Config) SetSecretDataValues

func (c *Config) SetSecretDataValues(secName, key, value string)

func (*Config) SetSecretStringValues

func (c *Config) SetSecretStringValues(secName, key, value string)

func (*Config) Spec

func (c *Config) Spec() ([]byte, error)

type ConfigMapConfig

type ConfigMapConfig struct {
	Id        string
	Name      string
	Namespace string
	Variables map[string]string
	// contains filtered or unexported fields
}

func (*ConfigMapConfig) Data

func (c *ConfigMapConfig) Data() map[string]string

func (*ConfigMapConfig) EqualConfigMap

func (c *ConfigMapConfig) EqualConfigMap(target *apiv1.ConfigMap) bool

func (*ConfigMapConfig) Get

func (c *ConfigMapConfig) Get() (*apiv1.ConfigMap, error)

func (*ConfigMapConfig) Set

func (*ConfigMapConfig) SetDataVariable

func (c *ConfigMapConfig) SetDataVariable(key, value string) *ConfigMapConfig

func (*ConfigMapConfig) SetStringVariable

func (c *ConfigMapConfig) SetStringVariable(key, value string) *ConfigMapConfig

func (*ConfigMapConfig) Spec

func (c *ConfigMapConfig) Spec() ([]byte, error)

type SecretConfig

type SecretConfig struct {
	Id              string
	Name            string
	Namespace       string
	DataVariables   map[string]string
	StringVariables map[string]string
	// contains filtered or unexported fields
}

func ImportSecret

func ImportSecret(spec []byte) (*SecretConfig, error)

func NewSecretConfig

func NewSecretConfig(id, name, namespace string) *SecretConfig

func (*SecretConfig) Data

func (s *SecretConfig) Data() map[string][]byte

func (*SecretConfig) Equal

func (s *SecretConfig) Equal(target *apiv1.Secret) bool

func (*SecretConfig) Get

func (s *SecretConfig) Get() (*apiv1.Secret, error)

func (*SecretConfig) Set

func (s *SecretConfig) Set(value *apiv1.Secret) *SecretConfig

func (*SecretConfig) SetDataVariable

func (s *SecretConfig) SetDataVariable(key, value string) *SecretConfig

func (*SecretConfig) SetStringVariable

func (s *SecretConfig) SetStringVariable(key, value string) *SecretConfig

func (*SecretConfig) Spec

func (s *SecretConfig) Spec() ([]byte, error)

func (*SecretConfig) StringData

func (s *SecretConfig) StringData() map[string]string

type ServiceConfig

type ServiceConfig struct {
	Id            string
	Name          string
	Namespace     string
	AppName       string
	Expose        string
	ContainerPort int32
	TargetPort    int32
	PortName      string
	NodePort      int32
	Headless      bool
	// contains filtered or unexported fields
}

func ImportServiceConfig

func ImportServiceConfig(spec []byte) (*ServiceConfig, error)

func NewServiceConfig

func NewServiceConfig(id, name, namespace, appName string) *ServiceConfig

func (*ServiceConfig) Get

func (s *ServiceConfig) Get() (*apiv1.Service, error)

func (*ServiceConfig) Set

func (s *ServiceConfig) Set(value *apiv1.Service) *ServiceConfig

func (*ServiceConfig) SetContainerPort

func (s *ServiceConfig) SetContainerPort(value int32) *ServiceConfig

func (*ServiceConfig) SetExpose

func (s *ServiceConfig) SetExpose(value string) *ServiceConfig

func (*ServiceConfig) SetHeadless

func (s *ServiceConfig) SetHeadless(value bool) *ServiceConfig

func (*ServiceConfig) SetNodePort

func (s *ServiceConfig) SetNodePort(value int32) *ServiceConfig

func (*ServiceConfig) SetPortName

func (s *ServiceConfig) SetPortName(value string) *ServiceConfig

func (*ServiceConfig) SetTargetPort

func (s *ServiceConfig) SetTargetPort(value int32) *ServiceConfig

func (*ServiceConfig) Spec

func (s *ServiceConfig) Spec() ([]byte, error)

type StatefulSetConfig

type StatefulSetConfig struct {
	Id              string
	Name            string
	Namespace       string
	ImagePullPolicy string
	Replicas        int
	Volume          string
	StorageClass    string

	Health                string
	Resources             string
	NodeSelectors         string
	Image                 string
	ServiceAccount        string
	ConfigCheckSum        string
	Standalone            bool
	StatefulSetConfigData string
	// contains filtered or unexported fields
}

func DefaultStatefulSetConfig

func DefaultStatefulSetConfig(id, name, namespace string) *StatefulSetConfig

func (*StatefulSetConfig) Get

func (sc *StatefulSetConfig) Get() (*appsv1.StatefulSet, error)

func (*StatefulSetConfig) Set

func (*StatefulSetConfig) SetConfigChecksum

func (sc *StatefulSetConfig) SetConfigChecksum(value string) *StatefulSetConfig

func (*StatefulSetConfig) SetHealthProbe

func (sc *StatefulSetConfig) SetHealthProbe(value string) *StatefulSetConfig

func (*StatefulSetConfig) SetImageName

func (sc *StatefulSetConfig) SetImageName(value string) *StatefulSetConfig

func (*StatefulSetConfig) SetImagePullPolicy

func (sc *StatefulSetConfig) SetImagePullPolicy(value string) *StatefulSetConfig

func (*StatefulSetConfig) SetNodeSelectors

func (sc *StatefulSetConfig) SetNodeSelectors(value string) *StatefulSetConfig

func (*StatefulSetConfig) SetReplicas

func (sc *StatefulSetConfig) SetReplicas(value int) *StatefulSetConfig

func (*StatefulSetConfig) SetResources

func (sc *StatefulSetConfig) SetResources(value string) *StatefulSetConfig

func (*StatefulSetConfig) SetServiceAccount

func (sc *StatefulSetConfig) SetServiceAccount(value string) *StatefulSetConfig

func (*StatefulSetConfig) SetStandalone

func (sc *StatefulSetConfig) SetStandalone(value bool) *StatefulSetConfig

func (*StatefulSetConfig) SetStatefulsetConfigData

func (sc *StatefulSetConfig) SetStatefulsetConfigData(value string) *StatefulSetConfig

func (*StatefulSetConfig) SetStorageClass

func (sc *StatefulSetConfig) SetStorageClass(value string) *StatefulSetConfig

func (*StatefulSetConfig) SetVolume

func (sc *StatefulSetConfig) SetVolume(value string) *StatefulSetConfig

func (*StatefulSetConfig) Spec

func (sc *StatefulSetConfig) Spec() ([]byte, error)

Jump to

Keyboard shortcuts

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