util

package
v0.33.0 Latest Latest
Warning

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

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

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func FetchApplication

func FetchApplication(ctx context.Context, application string, ucpOptions *arm.ClientOptions) (*v20231001preview.ApplicationResource, error)

FetchApplication fetches an application resource from the Azure Resource Manager using the given application ID and client options, and returns the application resource or an error if one occurs.

func FetchEnvironment

func FetchEnvironment(ctx context.Context, environmentID string, ucpOptions *arm.ClientOptions) (*v20231001preview.EnvironmentResource, error)

FetchEnvironment fetches an environment resource using the provided environmentID and ClientOptions, and returns the EnvironmentResource or an error.

func FetchScopeResource

func FetchScopeResource(ctx context.Context, sp dataprovider.DataStorageProvider, scopeID string, resource v1.DataModelInterface) error

FetchScopeResource checks if the given scopeID is a valid resource ID for the given resource type, fetches the resource from the storage client and returns an error if the resource does not exist.

func ReadFromRegistry

func ReadFromRegistry(ctx context.Context, definition recipes.EnvironmentDefinition, data *map[string]any, client remote.Client) error

ReadFromRegistry reads data from an OCI compliant registry and stores it in a map. It returns an error if the path is invalid, if the client to the registry fails to be created, if the manifest fails to be fetched, if the bytes fail to be fetched, or if the data fails to be unmarshalled.

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