v1alpha1

package
v0.3.8 Latest Latest
Warning

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

Go to latest
Published: Sep 13, 2024 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Overview

Package v1alpha1 contains API Schema definitions for the core v1alpha1 API group

Index

Constants

View Source
const (
	ProxyFinalizer = "proxy.core.apoxy.dev/finalizer"

	// DefaultDrainTimeout is the default duration to drain connections before terminating the proxy.
	// +kubebuilder:validation:Format=duration
	DefaultDrainTimeout = 30 * time.Second
)
View Source
const GroupName = "controllers.apoxy.dev"

GroupName specifies the group name used to register the objects.

Variables

View Source
var (
	// localSchemeBuilder and AddToScheme will stay in k8s.io/kubernetes.
	SchemeBuilder runtime.SchemeBuilder

	// Deprecated: use Install instead
	AddToScheme = localSchemeBuilder.AddToScheme
	Install     = localSchemeBuilder.AddToScheme
)
View Source
var GroupVersion = v1.GroupVersion{Group: GroupName, Version: "v1alpha1"}

GroupVersion specifies the group and the version used to register the objects.

View Source
var SchemeGroupVersion = schema.GroupVersion{Group: GroupName, Version: "v1alpha1"}

SchemeGroupVersion is group version used to register these objects Deprecated: use GroupVersion instead.

Functions

func Resource

func Resource(resource string) schema.GroupResource

Resource takes an unqualified resource and returns a Group qualified GroupResource

Types

type InfraProvider

type InfraProvider string

InfraProvider defines the infrastructure provider where the proxy will be deployed.

const (
	// InfraProviderCloud is the cloud provider.
	// This provider deploys proxies within Apoxy Edge.
	InfraProviderCloud InfraProvider = "cloud"
	// InfraProviderKubernetes is the kubernetes provider.
	// This provider is used to deploy the proxy as a kubernetes pod.
	InfraProviderKubernetes InfraProvider = "kubernetes"
	// InfraProviderUnmanaged is the unmanaged provider.
	// This provider is used for proxies that are deployed by users themselves and
	// are not managed by Apoxy Control Plane.
	InfraProviderUnmanaged InfraProvider = "unmanaged"
)

type Proxy

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

	Spec   ProxySpec   `json:"spec,omitempty"`
	Status ProxyStatus `json:"status,omitempty"`
}

func (*Proxy) DeepCopy

func (in *Proxy) DeepCopy() *Proxy

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

func (*Proxy) DeepCopyInto

func (in *Proxy) DeepCopyInto(out *Proxy)

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

func (*Proxy) DeepCopyObject

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

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

func (*Proxy) Default

func (r *Proxy) Default()

Default sets the default values for a Proxy.

func (*Proxy) GetGroupVersionResource

func (p *Proxy) GetGroupVersionResource() schema.GroupVersionResource

func (*Proxy) GetObjectMeta

func (p *Proxy) GetObjectMeta() *metav1.ObjectMeta

func (*Proxy) GetSingularName

func (p *Proxy) GetSingularName() string

func (*Proxy) GetStatus

func (p *Proxy) GetStatus() resource.StatusSubResource

func (*Proxy) IsStorageVersion

func (p *Proxy) IsStorageVersion() bool

func (*Proxy) NamespaceScoped

func (p *Proxy) NamespaceScoped() bool

func (*Proxy) New

func (p *Proxy) New() runtime.Object

func (*Proxy) NewList

func (p *Proxy) NewList() runtime.Object

func (*Proxy) SetupWebhookWithManager

func (r *Proxy) SetupWebhookWithManager(mgr ctrl.Manager) error

type ProxyList

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

ProxyList contains a list of Proxy objects.

func (*ProxyList) DeepCopy

func (in *ProxyList) DeepCopy() *ProxyList

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

func (*ProxyList) DeepCopyInto

func (in *ProxyList) DeepCopyInto(out *ProxyList)

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

func (*ProxyList) DeepCopyObject

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

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

func (*ProxyList) GetListMeta

func (pl *ProxyList) GetListMeta() *metav1.ListMeta

type ProxyListener

type ProxyListener struct {
	// Protocol is the protocol that the listener will accept traffic on.
	Protocol gwapiv1.ProtocolType `json:"protocol"`

	// Port is the port that the listener will accept traffic on.
	Port gwapiv1.PortNumber `json:"port"`
}

ProxyListener defines a logical endpoint that the Proxy will receive traffic on.

func (*ProxyListener) DeepCopy

func (in *ProxyListener) DeepCopy() *ProxyListener

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

func (*ProxyListener) DeepCopyInto

func (in *ProxyListener) DeepCopyInto(out *ProxyListener)

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

type ProxyPhase

type ProxyPhase string
const (
	ProxyPhasePending     ProxyPhase = "Pending"
	ProxyPhaseRunning     ProxyPhase = "Running"
	ProxyPhaseTerminating ProxyPhase = "Terminating"
	ProxyPhaseStopped     ProxyPhase = "Stopped"
	ProxyPhaseFailed      ProxyPhase = "Failed"
)

type ProxyReplicaPhase

type ProxyReplicaPhase string
const (
	ProxyReplicaPhasePending     ProxyReplicaPhase = "Pending"
	ProxyReplicaPhaseRunning     ProxyReplicaPhase = "Running"
	ProxyReplicaPhaseTerminating ProxyReplicaPhase = "Terminating"
	ProxyReplicaPhaseStopped     ProxyReplicaPhase = "Stopped"
	ProxyReplicaPhaseFailed      ProxyReplicaPhase = "Failed"
)

type ProxyReplicaStatus

type ProxyReplicaStatus struct {
	// Name of the replica.
	Name string `json:"name"`

	// Creation time of the replica.
	CreatedAt metav1.Time `json:"createdAt"`

	// Location of the replica.
	// Examples: "global", "europe", "us-west1", etc.
	// +optional
	Location string `json:"location"`

	// Phase of the replica.
	Phase ProxyReplicaPhase `json:"phase"`

	// Reason for the current phase.
	// +optional
	Reason string `json:"reason,omitempty"`
}

ProxyReplicaStatus defines the status of a proxy replica. This is used to track the status of individual proxy replicas.

func (*ProxyReplicaStatus) DeepCopy

func (in *ProxyReplicaStatus) DeepCopy() *ProxyReplicaStatus

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

func (*ProxyReplicaStatus) DeepCopyInto

func (in *ProxyReplicaStatus) DeepCopyInto(out *ProxyReplicaStatus)

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

type ProxySpec

type ProxySpec struct {
	// Provider is the infrastructure provider where the proxy will be deployed.
	// Defaults to "cloud" provider.
	Provider InfraProvider `json:"provider,omitempty"`

	// Locations is the list of locations where the proxy will be deployed:
	// * cloud provider:
	//  - global: Deploy the proxy in the global network.
	//  - <region>: Deploy the proxy in the specified region (e.g "europe")
	//  - <pop>: Deploy the proxy in the specified point of presence.
	// * kubernetes provider - The list of kubernetes clusters where the proxy will be deployed.
	// * unmanaged provider - Ignored.
	Locations []string `json:"locations,omitempty"`

	// Listeners is the list of logical endpoints that the Proxy will receive traffic on.
	// At least one listener MUST be specified.
	// If used with Gateway API, the listeners here must be a superset of the listeners
	// defined in the corresponding Gateway object.
	Listeners []ProxyListener `json:"listeners"`

	// How long to drain connections before terminating the proxy. Defaults to 30s.
	// For HTTP/1 Envoy will send a connection: close header to the client, for HTTP/2
	// Envoy will send a GOAWAY frame to the client.
	// +optional
	DrainTimeout *metav1.Duration `json:"drainTimeout,omitempty"`

	// Config is the Starlark configuration for the proxy in the txtar format.
	Config string `json:"config,omitempty"`
}

ProxySpec defines the desired specification of a Proxy.

func (*ProxySpec) DeepCopy

func (in *ProxySpec) DeepCopy() *ProxySpec

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

func (*ProxySpec) DeepCopyInto

func (in *ProxySpec) DeepCopyInto(out *ProxySpec)

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

type ProxyStatus

type ProxyStatus struct {
	// Phase of the proxy.
	// Examples: "Pending", "Running", "Failed", etc.
	Phase ProxyPhase `json:"phase,omitempty"`

	// Reason for the current phase.
	// +optional
	Reason string `json:"reason,omitempty"`

	// IPv4/v6 addresses of the proxy.
	// +optional
	IPs []string `json:"ips,omitempty"`

	// Replicas are statuses of the individual proxy replicas.
	Replicas []*ProxyReplicaStatus `json:"replicas,omitempty"`
}

ProxyStatus defines the observed state of Proxy.

func (*ProxyStatus) CopyTo

func (*ProxyStatus) DeepCopy

func (in *ProxyStatus) DeepCopy() *ProxyStatus

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

func (*ProxyStatus) DeepCopyInto

func (in *ProxyStatus) DeepCopyInto(out *ProxyStatus)

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

func (*ProxyStatus) SubResourceName

func (ps *ProxyStatus) SubResourceName() string

Jump to

Keyboard shortcuts

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