Documentation ¶
Index ¶
- Variables
- func GetInfrastructureProviderByName(ctx context.Context, c client.Client, name string) (*machinev1.InfrastructureProvider, error)
- func GetMachineByName(ctx context.Context, c client.Client, namespace, name string) (*machinev1.Machine, error)
- func GetOwnerInfrastructureProvider(ctx context.Context, c client.Client, obj metav1.ObjectMeta) (*machinev1.InfrastructureProvider, error)
- func GetOwnerMachine(ctx context.Context, c client.Client, obj metav1.ObjectMeta) (*machinev1.Machine, error)
- func MachineToInfrastructureMapFunc(gvk schema.GroupVersionKind) handler.ToRequestsFunc
- func UnstructuredUnmarshalField(obj *unstructured.Unstructured, v interface{}, fields ...string) error
Constants ¶
This section is empty.
Variables ¶
var (
ErrUnstructuredFieldNotFound = fmt.Errorf("field not found")
)
Functions ¶
func GetInfrastructureProviderByName ¶ added in v1.0.1
func GetInfrastructureProviderByName(ctx context.Context, c client.Client, name string) (*machinev1.InfrastructureProvider, error)
GetInfrastructureProviderByName finds and return a InfrastructureProvider object using the specified params.
func GetMachineByName ¶
func GetMachineByName(ctx context.Context, c client.Client, namespace, name string) (*machinev1.Machine, error)
GetMachineByName finds and return a Machine object using the specified params.
func GetOwnerInfrastructureProvider ¶ added in v1.0.1
func GetOwnerInfrastructureProvider(ctx context.Context, c client.Client, obj metav1.ObjectMeta) (*machinev1.InfrastructureProvider, error)
GetOwnerInfrastructureProvider returns the InfrastructureProvider object owning the current resource.
func GetOwnerMachine ¶
func GetOwnerMachine(ctx context.Context, c client.Client, obj metav1.ObjectMeta) (*machinev1.Machine, error)
GetOwnerMachine returns the Machine object owning the current resource.
func MachineToInfrastructureMapFunc ¶
func MachineToInfrastructureMapFunc(gvk schema.GroupVersionKind) handler.ToRequestsFunc
MachineToInfrastructureMapFunc returns a handler.ToRequestsFunc that watches for Machine events and returns reconciliation requests for an infrastructure provider object.
func UnstructuredUnmarshalField ¶
func UnstructuredUnmarshalField(obj *unstructured.Unstructured, v interface{}, fields ...string) error
UnstructuredUnmarshalField is a wrapper around json and unstructured objects to decode and copy a specific field value into an object.
Types ¶
This section is empty.