utils

package
v0.1.1 Latest Latest
Warning

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

Go to latest
Published: Oct 29, 2025 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

View Source
const (

	// LabelComponentName is the label used to identify components added by the Service Provider in an MCP.
	LabelComponentName = "services.openmcp.cloud/component"
)
View Source
const OCIPrefix = "oci://"

OCIPrefix is the standard prefix for OCI URLs.

Variables

This section is empty.

Functions

func AddOCIPrefix added in v0.1.1

func AddOCIPrefix(ociURL string) string

AddOCIPrefix adds the "oci://" prefix to the given URL if it doesn't already have it. It returns the URL unchanged if it already starts with "oci://" (case-sensitive). If the input is empty, it returns an empty string.

func HasComponentLabel

func HasComponentLabel() client.ListOption

HasComponentLabel returns a client.ListOption that matches objects with the component label.

func IsManaged

func IsManaged() client.MatchingLabels

IsManaged returns a client.MatchingLabels that matches objects managed by this Service Provider.

func SetLabel

func SetLabel(obj v1.Object, label string, value string)

SetLabel sets a label on the given object.

func SetManagedBy

func SetManagedBy(obj v1.Object)

SetManagedBy sets the "app.kubernetes.io/managed-by" label on the given object.

Types

This section is empty.

Jump to

Keyboard shortcuts

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