Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func RunOnConfigChange ¶
func RunOnConfigChange(ctx context.Context, log *zap.SugaredLogger, path string, callbacks ...CallbackFn)
RunOnConfigChange - run callback functions when config is changed
Types ¶
type CallbackFn ¶
type CallbackFn func(Config)
type Config ¶
func LoadLogConfig ¶
LoadLogConfig - return cfg struct based on given path
type FunctionConfig ¶
type FunctionConfig struct {
MetricsPort string `yaml:"metricsPort"`
LeaderElectionEnabled bool `yaml:"leaderElectionEnabled"`
LeaderElectionID string `yaml:"leaderElectionID"`
SecretMutatingWebhookPort int `yaml:"secretMutatingWebhookPort"`
Healthz healthzConfig
Images ImagesConfig `yaml:"images"`
RequeueDuration time.Duration `yaml:"requeueDuration"`
FunctionReadyRequeueDuration time.Duration `yaml:"functionReadyRequeueDuration"`
PackageRegistryConfigSecretName string `yaml:"packageRegistryConfigSecretName"`
FunctionTraceCollectorEndpoint string `yaml:"functionTraceCollectorEndpoint"`
FunctionPublisherProxyAddress string `yaml:"functionPublisherProxyAddress"`
ResourceConfig ResourceConfig `yaml:"resourcesConfiguration"`
InternalEndpointPort string `yaml:"internalEndpointPort"`
}
func LoadFunctionConfig ¶
func LoadFunctionConfig(path string) (FunctionConfig, error)
type FunctionResourceConfig ¶
type FunctionResourceConfig struct {
Resources Resources `yaml:"resources"`
}
type ImagesConfig ¶
type Quantity ¶
func (*Quantity) UnmarshalYAML ¶
type Resource ¶
type Resource struct {
RequestCPU Quantity `yaml:"requestCpu"`
RequestMemory Quantity `yaml:"requestMemory"`
LimitCPU Quantity `yaml:"limitCpu"`
LimitMemory Quantity `yaml:"limitMemory"`
}
func (Resource) ToResourceRequirements ¶
func (r Resource) ToResourceRequirements() corev1.ResourceRequirements
type ResourceConfig ¶
type ResourceConfig struct {
Function FunctionResourceConfig `yaml:"function"`
}
func (*ResourceConfig) Unmarshal ¶
func (rc *ResourceConfig) Unmarshal(input string) error
Click to show internal directories.
Click to hide internal directories.