Documentation
¶
Index ¶
- Constants
- type AccessLog
- type AdditionalAddress
- type Address
- type AdminServer
- type BootstrapConfig
- type BootstrapConfigGenerator
- type Cluster
- type Clusters
- type ConfigGenerator
- type ContainerConstructor
- type DynamicValue
- type Endpoint
- type EnvoyInternalAddress
- type Filter
- type FilterChain
- type Filters
- type HTTPConnectionManager
- type HTTPFilter
- type HTTPFilterConfig
- type HTTPFilters
- type HealthCheckConfig
- type LbEndpoint
- type Listener
- type Listeners
- type LoadAssignment
- type Locality
- type LocalityLbEndpoints
- type Match
- type Pipe
- type Redirect
- type Route
- type RouteConfig
- type Routes
- type SingleRoute
- type SocketAddress
- type StaticResources
- type UpgradeConfig
- type VirtualHost
Constants ¶
View Source
const ( EnvoyProxyContainerName = "envoy-proxy" EnvoyProxyContainerImage = "envoyproxy/envoy:v1.31-latest" EnvoyProxyRunAsUser = 1337 ProxyInitContainerName = "proxy-init" ProxyInitContainerImage = "openpolicyagent/proxy_init:v8" BasicAuthContainerPort = 9001 )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AccessLog ¶
type AccessLog struct {
Name string `json:"name" yaml:"name"`
TypedConfig DynamicValue `json:"typed_config" yaml:"typed_config"`
}
type AdditionalAddress ¶
type AdditionalAddress struct {
Address Address `json:"address" yaml:"address"`
}
type Address ¶
type Address struct {
SocketAddress SocketAddress `json:"socket_address" yaml:"socket_address"`
Pipe Pipe `json:"pipe,omitempty" yaml:"pipe,omitempty"`
EnvoyInternalAddress EnvoyInternalAddress `json:"envoy_internal_address,omitempty" yaml:"envoy_internal_address,omitempty"`
}
type AdminServer ¶
type BootstrapConfig ¶
type BootstrapConfig struct {
Admin AdminServer `yaml:"admin"`
StaticResources StaticResources `yaml:"static_resources"`
}
BootstrapConfig represents the complete Envoy bootstrap configuration
type BootstrapConfigGenerator ¶
type BootstrapConfigGenerator struct {
// contains filtered or unexported fields
}
func NewBootstrapConfigGenerator ¶
func NewBootstrapConfigGenerator(log logr.Logger) *BootstrapConfigGenerator
func (*BootstrapConfigGenerator) GenerateEnvoyConfig ¶
func (g *BootstrapConfigGenerator) GenerateEnvoyConfig(config *common.KodeResourceConfig, useBasicAuth bool) (string, error)
type Cluster ¶
type Cluster struct {
Name string `json:"name" yaml:"name"`
ConnectTimeout string `json:"connect_timeout" yaml:"connect_timeout"`
Type string `json:"type" yaml:"type"`
LbPolicy string `json:"lb_policy" yaml:"lb_policy"`
TypedExtensionProtocolOptions DynamicValue `json:"typed_extension_protocol_options,omitempty" yaml:"typed_extension_protocol_options,omitempty"`
LoadAssignment LoadAssignment `json:"load_assignment" yaml:"load_assignment"`
}
type ConfigGenerator ¶
type ConfigGenerator interface {
GenerateEnvoyConfig(config *common.KodeResourceConfig, useBasicAuth bool) (string, error)
}
type ContainerConstructor ¶
type ContainerConstructor struct {
// contains filtered or unexported fields
}
func NewContainerConstructor ¶
func NewContainerConstructor(log logr.Logger, configGenerator ConfigGenerator) *ContainerConstructor
func (*ContainerConstructor) ConstructEnvoyContainers ¶
func (c *ContainerConstructor) ConstructEnvoyContainers(config *common.KodeResourceConfig) ([]corev1.Container, []corev1.Container, error)
type DynamicValue ¶
type DynamicValue struct {
Value interface{} `json:",inline" yaml:",inline"`
}
Add this type to replace runtime.RawExtension
func (DynamicValue) MarshalJSON ¶
func (d DynamicValue) MarshalJSON() ([]byte, error)
func (DynamicValue) MarshalYAML ¶
func (d DynamicValue) MarshalYAML() (interface{}, error)
func (*DynamicValue) UnmarshalJSON ¶
func (d *DynamicValue) UnmarshalJSON(data []byte) error
Add marshal/unmarshal methods for proper encoding
func (*DynamicValue) UnmarshalYAML ¶
func (d *DynamicValue) UnmarshalYAML(unmarshal func(interface{}) error) error
type Endpoint ¶
type Endpoint struct {
Address Address `json:"address" yaml:"address"`
HealthCheckConfig HealthCheckConfig `json:"health_check_config,omitempty" yaml:"health_check_config,omitempty"`
Hostname string `json:"hostname,omitempty" yaml:"hostname,omitempty"`
AdditionalAddresses []AdditionalAddress `json:"additional_addresses,omitempty" yaml:"additional_addresses,omitempty"`
}
type EnvoyInternalAddress ¶
type Filter ¶
type Filter struct {
Name string `json:"name" yaml:"name"`
TypedConfig DynamicValue `json:"typed_config" yaml:"typed_config"`
}
type FilterChain ¶
type FilterChain struct {
Filters []Filter `json:"filters" yaml:"filters"`
}
type HTTPConnectionManager ¶
type HTTPConnectionManager struct {
Type string `yaml:"@type"`
StatPrefix string `yaml:"stat_prefix"`
CodecType string `yaml:"codec_type"`
RouteConfig RouteConfig `yaml:"route_config"`
HTTPFilters []HTTPFilterConfig `yaml:"http_filters"`
}
type HTTPFilter ¶
type HTTPFilter struct {
Name string `json:"name" yaml:"name"`
TypedConfig DynamicValue `json:"typed_config" yaml:"typed_config"`
}
type HTTPFilterConfig ¶
type HTTPFilterConfig struct {
Name string `yaml:"name"`
TypedConfig DynamicValue `yaml:"typed_config,omitempty"`
}
type HTTPFilters ¶
type HTTPFilters []HTTPFilter
type HealthCheckConfig ¶
type HealthCheckConfig struct {
PortValue uint32 `json:"port_value" yaml:"port_value"`
Hostname string `json:"hostname" yaml:"hostname,omitempty"`
Address Address `json:"address" yaml:"address,omitempty"`
DisableActiveHealthCheck bool `json:"disable_active_health_check,omitempty" yaml:"disable_active_health_check,omitempty"`
}
type LbEndpoint ¶
type LbEndpoint struct {
Endpoint Endpoint `json:"endpoint" yaml:"endpoint"`
HealthStatus string `json:"health_status,omitempty" yaml:"health_status,omitempty"`
Metadata DynamicValue `json:"metadata,omitempty" yaml:"metadata,omitempty"`
LoadBalancingWeight uint32 `json:"load_balancing_weight,omitempty" yaml:"load_balancing_weight,omitempty"`
}
type Listener ¶
type Listener struct {
Name string `json:"name" yaml:"name"`
Address Address `json:"address" yaml:"address"`
FilterChains []FilterChain `json:"filter_chains" yaml:"filter_chains"`
}
type LoadAssignment ¶
type LoadAssignment struct {
ClusterName string `json:"cluster_name" yaml:"cluster_name"`
Endpoints []LocalityLbEndpoints `json:"endpoints" yaml:"endpoints"`
Policy DynamicValue `json:"policy,omitempty" yaml:"policy,omitempty"`
}
type LocalityLbEndpoints ¶
type LocalityLbEndpoints struct {
Locality Locality `json:"locality,omitempty" yaml:"locality,omitempty"`
Metadata DynamicValue `json:"metadata,omitempty" yaml:"metadata,omitempty"`
LbEndpoints []LbEndpoint `json:"lb_endpoints" yaml:"lb_endpoints"`
LoadBalancingWeight uint32 `json:"load_balancing_weight,omitempty" yaml:"load_balancing_weight,omitempty"`
Priority uint32 `json:"priority,omitempty" yaml:"priority,omitempty"`
}
type Redirect ¶
type Redirect struct {
HTTPSRedirect bool `json:"https_redirect" yaml:"https_redirect"`
}
type Route ¶
type Route struct {
Match Match `json:"match" yaml:"match"`
Route *SingleRoute `json:"route,omitempty" yaml:"route,omitempty"`
Redirect *Redirect `json:"redirect,omitempty" yaml:"redirect,omitempty"`
TypedPerFilterConfig DynamicValue `json:"typed_per_filter_config,omitempty" yaml:"typed_per_filter_config,omitempty"`
}
type RouteConfig ¶
type RouteConfig struct {
Name string `json:"name" yaml:"name"`
VirtualHosts []VirtualHost `json:"virtual_hosts" yaml:"virtual_hosts"`
}
type SingleRoute ¶
type SocketAddress ¶
type StaticResources ¶
type UpgradeConfig ¶
type UpgradeConfig struct {
UpgradeType string `json:"upgrade_type" yaml:"upgrade_type"`
}
type VirtualHost ¶
Click to show internal directories.
Click to hide internal directories.