azureutil

package
v1.23.15 Latest Latest
Warning

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

Go to latest
Published: Apr 11, 2026 License: MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetCurrentPrincipalId

func GetCurrentPrincipalId(ctx context.Context, userProfile *azapi.UserProfileService, tenantId string) (string, error)

GetCurrentPrincipalId returns the object ID of the current principal authenticated with the CLI. It prefers the oid claim from an ARM access token, falling back to Graph /me when acquiring the token fails or when the token does not include a usable oid.

func PromptLocationWithFilter

func PromptLocationWithFilter(
	ctx context.Context,
	subscriptionId string,
	message string,
	help string,
	console input.Console,
	accountManager account.Manager,
	shouldDisplay func(account.Location) bool,
	defaultSelectedLocation *string,
) (string, error)

PromptLocation asks the user to select a location from a list of supported azure locations for a given subscription. shouldDisplay, when non-nil, filters the location being displayed.

func ResourceNotFound

func ResourceNotFound(err error) error

Types

type ResourceNotFoundError

type ResourceNotFoundError struct {
	// contains filtered or unexported fields
}

func (*ResourceNotFoundError) Error

func (e *ResourceNotFoundError) Error() string

Jump to

Keyboard shortcuts

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