scope

package
v0.7.1 Latest Latest
Warning

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

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

Documentation

Overview

Package scope provides utilities for determining Kubernetes resource scope compatibility, particularly for owner reference eligibility.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CanSetOwnerReference

func CanSetOwnerReference(
	owner, owned client.Object,
	scheme *runtime.Scheme,
	mapper meta.RESTMapper,
) (bool, error)

CanSetOwnerReference reports whether the owner can set an OwnerReference on the owned object. It returns false when the owned resource is cluster-scoped and the owner is namespace-scoped, which the Kubernetes API server rejects.

Returns an error if the provided RESTMapper is nil.

Types

This section is empty.

Jump to

Keyboard shortcuts

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