agent

package
v0.5.2 Latest Latest
Warning

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

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

README

internal/agent

This package contains the logic for the threeport agent. It is a Kubernetes controller, AKA Kubernetes operator. It's purpose is to consume ThreeportAgent custom resources and use those to determine which Kubernetes resources constitute a threeport workload instance so that those resources may be watched. Kubernetes Events for those resources are also captured and sent to the Threeport API for use by Threeport controllers and end-users.

The following diagram illustrates the functionality that belongs in each source file along with the interactions with the external APIs. The blue function boxes that aren't inside a black source file box belong to imported libraries.

threeport-agent-architecture

Documentation

Index

Constants

View Source
const (
	// The Kubernetes finalizer applied to ThreeportWorkload resources
	ThreeportWorkloadFinalizer = "control-plane.threeport.io/threeport-workload-finalizer"

	// The workload type applied to the `.spec.workloadType` field in a
	// `ThreeportWorkload` kubernetes resource to indicate to the Threeport
	// Agent what Threeport type is managing workload resources in Kubernetes.
	WorkloadInstanceType     = "WorkloadInstance"
	HelmWorkloadInstanceType = "HelmWorkloadInstance"

	// The label keys applied to workloads managed by Threeport
	WorkloadInstanceLabelKey     = "control-plane.threeport.io/workload-instance"
	HelmWorkloadInstanceLabelKey = "control-plane.threeport.io/helm-workload-instance"
)

Variables

This section is empty.

Functions

func ThreeportWorkloadName

func ThreeportWorkloadName(
	workloadInstanceID uint,
	workloadType string,
) (string, error)

ThreeportWorkloadName returns a standardized name for a ThreeportWorkload Kubernetes custom resource based on the workload instance ID.

Types

This section is empty.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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