v1beta1

package
v0.2.40 Latest Latest
Warning

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

Go to latest
Published: Apr 22, 2024 License: Apache-2.0 Imports: 8 Imported by: 1

Documentation

Overview

Package v1beta1 contains API Schema definitions for the core v1beta1 API group +kubebuilder:object:generate=true +groupName=core.openfeature.dev

Index

Constants

View Source
const (
	SidecarEnvVarPrefix              string = "SIDECAR_ENV_VAR_PREFIX"
	InputConfigurationEnvVarPrefix   string = "SIDECAR"
	SidecarMetricPortEnvVar          string = "MANAGEMENT_PORT"
	SidecarPortEnvVar                string = "PORT"
	SidecarSocketPathEnvVar          string = "SOCKET_PATH"
	SidecarEvaluatorEnvVar           string = "EVALUATOR"
	SidecarImageEnvVar               string = "IMAGE"
	SidecarVersionEnvVar             string = "TAG"
	SidecarProviderArgsEnvVar        string = "PROVIDER_ARGS"
	SidecarDefaultSyncProviderEnvVar string = "SYNC_PROVIDER"
	SidecarLogFormatEnvVar           string = "LOG_FORMAT"
	SidecarProbesEnabledVar          string = "PROBES_ENABLED"

	DefaultManagementPort int32 = 8014
)

Variables

View Source
var (
	// GroupVersion is group version used to register these objects
	GroupVersion = schema.GroupVersion{Group: "core.openfeature.dev", Version: "v1beta1"}

	// SchemeBuilder is used to add go types to the GroupVersionKind scheme
	SchemeBuilder = &scheme.Builder{GroupVersion: GroupVersion}

	// AddToScheme adds the types in this group-version to the given scheme.
	AddToScheme = SchemeBuilder.AddToScheme
)

Functions

This section is empty.

Types

type FeatureFlag

type FeatureFlag struct {
	metav1.TypeMeta   `json:",inline"`
	metav1.ObjectMeta `json:"metadata,omitempty"`

	Spec   FeatureFlagSpec   `json:"spec,omitempty"`
	Status FeatureFlagStatus `json:"status,omitempty"`
}

FeatureFlag is the Schema for the featureflags API

func (*FeatureFlag) DeepCopy

func (in *FeatureFlag) DeepCopy() *FeatureFlag

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new FeatureFlag.

func (*FeatureFlag) DeepCopyInto

func (in *FeatureFlag) DeepCopyInto(out *FeatureFlag)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*FeatureFlag) DeepCopyObject

func (in *FeatureFlag) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

func (*FeatureFlag) GenerateConfigMap added in v0.2.38

func (ff *FeatureFlag) GenerateConfigMap(name string, namespace string, references []metav1.OwnerReference) (*corev1.ConfigMap, error)

func (*FeatureFlag) GetReference added in v0.2.38

func (ff *FeatureFlag) GetReference() metav1.OwnerReference

type FeatureFlagList

type FeatureFlagList struct {
	metav1.TypeMeta `json:",inline"`
	metav1.ListMeta `json:"metadata,omitempty"`
	Items           []FeatureFlag `json:"items"`
}

FeatureFlagList contains a list of FeatureFlag

func (*FeatureFlagList) DeepCopy

func (in *FeatureFlagList) DeepCopy() *FeatureFlagList

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new FeatureFlagList.

func (*FeatureFlagList) DeepCopyInto

func (in *FeatureFlagList) DeepCopyInto(out *FeatureFlagList)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*FeatureFlagList) DeepCopyObject

func (in *FeatureFlagList) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type FeatureFlagSource

type FeatureFlagSource struct {
	metav1.TypeMeta   `json:",inline"`
	metav1.ObjectMeta `json:"metadata,omitempty"`

	Spec   FeatureFlagSourceSpec   `json:"spec,omitempty"`
	Status FeatureFlagSourceStatus `json:"status,omitempty"`
}

FeatureFlagSource is the Schema for the FeatureFlagSources API

func (*FeatureFlagSource) DeepCopy

func (in *FeatureFlagSource) DeepCopy() *FeatureFlagSource

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new FeatureFlagSource.

func (*FeatureFlagSource) DeepCopyInto

func (in *FeatureFlagSource) DeepCopyInto(out *FeatureFlagSource)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*FeatureFlagSource) DeepCopyObject

func (in *FeatureFlagSource) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type FeatureFlagSourceList

type FeatureFlagSourceList struct {
	metav1.TypeMeta `json:",inline"`
	metav1.ListMeta `json:"metadata,omitempty"`
	Items           []FeatureFlagSource `json:"items"`
}

FeatureFlagSourceList contains a list of FeatureFlagSource

func (*FeatureFlagSourceList) DeepCopy

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new FeatureFlagSourceList.

func (*FeatureFlagSourceList) DeepCopyInto

func (in *FeatureFlagSourceList) DeepCopyInto(out *FeatureFlagSourceList)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*FeatureFlagSourceList) DeepCopyObject

func (in *FeatureFlagSourceList) DeepCopyObject() runtime.Object

DeepCopyObject is an autogenerated deepcopy function, copying the receiver, creating a new runtime.Object.

type FeatureFlagSourceSpec

type FeatureFlagSourceSpec struct {
	// ManagemetPort defines the port to serve management on, defaults to 8014
	// +optional
	ManagementPort int32 `json:"managementPort"`

	// Port defines the port to listen on, defaults to 8013
	// +optional
	Port int32 `json:"port"`

	// SocketPath defines the unix socket path to listen on
	// +optional
	SocketPath string `json:"socketPath"`

	// Evaluator sets an evaluator, defaults to 'json'
	// +optional
	Evaluator string `json:"evaluator"`

	// SyncProviders define the syncProviders and associated configuration to be applied to the sidecar
	// +kubebuilder:validation:MinItems=1
	Sources []Source `json:"sources"`

	// EnvVars define the env vars to be applied to the sidecar, any env vars in FeatureFlag CRs
	// are added at the lowest index, all values will have the EnvVarPrefix applied, default FLAGD
	// +optional
	EnvVars []corev1.EnvVar `json:"envVars"`

	// SyncProviderArgs are string arguments passed to all sync providers, defined as key values separated by =
	// +optional
	SyncProviderArgs []string `json:"syncProviderArgs"`

	// DefaultSyncProvider defines the default sync provider
	// +optional
	DefaultSyncProvider common.SyncProviderType `json:"defaultSyncProvider"`

	// LogFormat allows for the sidecar log format to be overridden, defaults to 'json'
	// +optional
	LogFormat string `json:"logFormat"`

	// EnvVarPrefix defines the prefix to be applied to all environment variables applied to the sidecar, default FLAGD
	// +optional
	EnvVarPrefix string `json:"envVarPrefix"`

	// RolloutOnChange dictates whether annotated deployments will be restarted when configuration changes are
	// detected in this CR, defaults to false
	// +optional
	RolloutOnChange *bool `json:"rolloutOnChange"`

	// ProbesEnabled defines whether to enable liveness and readiness probes of flagd sidecar. Default true (enabled).
	// +optional
	ProbesEnabled *bool `json:"probesEnabled"`

	// DebugLogging defines whether to enable --debug flag of flagd sidecar. Default false (disabled).
	// +optional
	DebugLogging *bool `json:"debugLogging"`

	// OtelCollectorUri defines whether to enable --otel-collector-uri flag of flagd sidecar. Default false (disabled).
	// +optional
	OtelCollectorUri string `json:"otelCollectorUri"`

	// Resources defines flagd sidecar resources. Default to operator sidecar-cpu-* and sidecar-ram-* flags.
	// +optional
	Resources corev1.ResourceRequirements `json:"resources"`
}

FeatureFlagSourceSpec defines the desired state of FeatureFlagSource

func (*FeatureFlagSourceSpec) DeepCopy

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new FeatureFlagSourceSpec.

func (*FeatureFlagSourceSpec) DeepCopyInto

func (in *FeatureFlagSourceSpec) DeepCopyInto(out *FeatureFlagSourceSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

func (*FeatureFlagSourceSpec) Merge added in v0.2.38

func (*FeatureFlagSourceSpec) ToEnvVars added in v0.2.38

func (fc *FeatureFlagSourceSpec) ToEnvVars() []corev1.EnvVar

type FeatureFlagSourceStatus

type FeatureFlagSourceStatus struct {
}

FeatureFlagSourceStatus defines the observed state of FeatureFlagSource

func (*FeatureFlagSourceStatus) DeepCopy

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new FeatureFlagSourceStatus.

func (*FeatureFlagSourceStatus) DeepCopyInto

func (in *FeatureFlagSourceStatus) DeepCopyInto(out *FeatureFlagSourceStatus)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type FeatureFlagSpec

type FeatureFlagSpec struct {
	// FlagSpec is the structured representation of the feature flag specification
	FlagSpec FlagSpec `json:"flagSpec,omitempty"`
}

FeatureFlagSpec defines the desired state of FeatureFlag

func (*FeatureFlagSpec) DeepCopy

func (in *FeatureFlagSpec) DeepCopy() *FeatureFlagSpec

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new FeatureFlagSpec.

func (*FeatureFlagSpec) DeepCopyInto

func (in *FeatureFlagSpec) DeepCopyInto(out *FeatureFlagSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type FeatureFlagStatus

type FeatureFlagStatus struct {
}

FeatureFlagStatus defines the observed state of FeatureFlag

func (*FeatureFlagStatus) DeepCopy

func (in *FeatureFlagStatus) DeepCopy() *FeatureFlagStatus

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new FeatureFlagStatus.

func (*FeatureFlagStatus) DeepCopyInto

func (in *FeatureFlagStatus) DeepCopyInto(out *FeatureFlagStatus)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type Flag

type Flag struct {
	// +kubebuilder:validation:Enum=ENABLED;DISABLED
	State string `json:"state"`
	// +kubebuilder:validation:Schemaless
	// +kubebuilder:pruning:PreserveUnknownFields
	// +kubebuilder:validation:Type=object
	Variants       json.RawMessage `json:"variants"`
	DefaultVariant string          `json:"defaultVariant"`
	// +optional
	// +kubebuilder:validation:Schemaless
	// +kubebuilder:pruning:PreserveUnknownFields
	// +kubebuilder:validation:Type=object
	// Targeting is the json targeting rule
	Targeting json.RawMessage `json:"targeting,omitempty"`
}

func (*Flag) DeepCopy

func (in *Flag) DeepCopy() *Flag

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Flag.

func (*Flag) DeepCopyInto

func (in *Flag) DeepCopyInto(out *Flag)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type FlagSpec

type FlagSpec struct {
	Flags map[string]Flag `json:"flags"`
	// +optional
	// +kubebuilder:validation:Schemaless
	// +kubebuilder:pruning:PreserveUnknownFields
	// +kubebuilder:validation:Type=object
	Evaluators json.RawMessage `json:"$evaluators,omitempty"`
}

func (*FlagSpec) DeepCopy

func (in *FlagSpec) DeepCopy() *FlagSpec

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new FlagSpec.

func (*FlagSpec) DeepCopyInto

func (in *FlagSpec) DeepCopyInto(out *FlagSpec)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

type Source

type Source struct {
	// Source is a URI of the flag sources
	Source string `json:"source"`

	// Provider type - kubernetes, http(s), grpc(s) or file
	// +optional
	Provider common.SyncProviderType `json:"provider"`

	// HttpSyncBearerToken is a bearer token. Used by http(s) sync provider only
	// +optional
	HttpSyncBearerToken string `json:"httpSyncBearerToken"`

	// TLS - Enable/Disable secure TLS connectivity. Currently used only by GRPC sync
	// +optional
	TLS bool `json:"tls"`

	// CertPath is a path of a certificate to be used by grpc TLS connection
	// +optional
	CertPath string `json:"certPath"`

	// ProviderID is an identifier to be used in grpc provider
	// +optional
	ProviderID string `json:"providerID"`

	// Selector is a flag configuration selector used by grpc provider
	// +optional
	Selector string `json:"selector,omitempty"`

	// Interval is a flag configuration interval in seconds used by http provider
	// +optional
	Interval uint32 `json:"interval,omitempty"`
}

func (*Source) DeepCopy

func (in *Source) DeepCopy() *Source

DeepCopy is an autogenerated deepcopy function, copying the receiver, creating a new Source.

func (*Source) DeepCopyInto

func (in *Source) DeepCopyInto(out *Source)

DeepCopyInto is an autogenerated deepcopy function, copying the receiver, writing into out. in must be non-nil.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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