azureClientWrapper

package
v0.4.6 Latest Latest
Warning

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

Go to latest
Published: Sep 3, 2024 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrClientCreationFailure = errors.New("failed to create client")
	ErrPageAdvanceFailure    = errors.New("failed to advance page")
)

Functions

This section is empty.

Types

type AzClientWrapper

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

func NewAzureClientWrapper

func NewAzureClientWrapper(logger *slog.Logger, subscriptionId string, credentials *azidentity.DefaultAzureCredential) (*AzClientWrapper, error)

func (*AzClientWrapper) ListClustersInSubscription

func (a *AzClientWrapper) ListClustersInSubscription(ctx context.Context) ([]*armcontainerservice.ManagedCluster, error)

func (*AzClientWrapper) ListMachineTypesByLocation

func (a *AzClientWrapper) ListMachineTypesByLocation(ctx context.Context, region string) ([]*armcompute.VirtualMachineSize, error)

func (*AzClientWrapper) ListPrices

func (*AzClientWrapper) ListVirtualMachineScaleSetsFromResourceGroup

func (a *AzClientWrapper) ListVirtualMachineScaleSetsFromResourceGroup(ctx context.Context, rgName string) ([]*armcompute.VirtualMachineScaleSet, error)

func (*AzClientWrapper) ListVirtualMachineScaleSetsOwnedVms

func (a *AzClientWrapper) ListVirtualMachineScaleSetsOwnedVms(ctx context.Context, rgName, vmssName string) ([]*armcompute.VirtualMachineScaleSetVM, error)

type AzureClient

type AzureClient interface {
	// Machine Store
	ListClustersInSubscription(context.Context) ([]*armcontainerservice.ManagedCluster, error)
	ListVirtualMachineScaleSetsOwnedVms(context.Context, string, string) ([]*armcompute.VirtualMachineScaleSetVM, error)
	ListVirtualMachineScaleSetsFromResourceGroup(context.Context, string) ([]*armcompute.VirtualMachineScaleSet, error)
	ListMachineTypesByLocation(context.Context, string) ([]*armcompute.VirtualMachineSize, error)

	// Price Store
	ListPrices(context.Context, *retailPriceSdk.RetailPricesClientListOptions) ([]*retailPriceSdk.ResourceSKU, error)
}

Jump to

Keyboard shortcuts

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