agentpools

package
v0.20230418.1121253 Latest Latest
Warning

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

Go to latest
Published: Apr 18, 2023 License: MPL-2.0 Imports: 9 Imported by: 1

README

github.com/hashicorp/go-azure-sdk/resource-manager/containerservice/2019-08-01/agentpools Documentation

The agentpools SDK allows for interaction with the Azure Resource Manager Service containerservice (API Version 2019-08-01).

This readme covers example usages, but further information on using this SDK can be found in the project root.

Import Path

import "github.com/hashicorp/go-azure-sdk/resource-manager/containerservice/2019-08-01/agentpools"

Client Initialization

client := agentpools.NewAgentPoolsClientWithBaseURI("https://management.azure.com")
client.Client.Authorizer = authorizer

Example Usage: AgentPoolsClient.CreateOrUpdate

ctx := context.TODO()
id := agentpools.NewAgentPoolID("12345678-1234-9876-4563-123456789012", "example-resource-group", "managedClusterValue", "agentPoolValue")

payload := agentpools.AgentPool{
	// ...
}


if err := client.CreateOrUpdateThenPoll(ctx, id, payload); err != nil {
	// handle the error
}

Example Usage: AgentPoolsClient.Delete

ctx := context.TODO()
id := agentpools.NewAgentPoolID("12345678-1234-9876-4563-123456789012", "example-resource-group", "managedClusterValue", "agentPoolValue")

if err := client.DeleteThenPoll(ctx, id); err != nil {
	// handle the error
}

Example Usage: AgentPoolsClient.Get

ctx := context.TODO()
id := agentpools.NewAgentPoolID("12345678-1234-9876-4563-123456789012", "example-resource-group", "managedClusterValue", "agentPoolValue")

read, err := client.Get(ctx, id)
if err != nil {
	// handle the error
}
if model := read.Model; model != nil {
	// do something with the model/response object
}

Example Usage: AgentPoolsClient.GetAvailableAgentPoolVersions

ctx := context.TODO()
id := agentpools.NewManagedClusterID("12345678-1234-9876-4563-123456789012", "example-resource-group", "managedClusterValue")

read, err := client.GetAvailableAgentPoolVersions(ctx, id)
if err != nil {
	// handle the error
}
if model := read.Model; model != nil {
	// do something with the model/response object
}

Example Usage: AgentPoolsClient.GetUpgradeProfile

ctx := context.TODO()
id := agentpools.NewAgentPoolID("12345678-1234-9876-4563-123456789012", "example-resource-group", "managedClusterValue", "agentPoolValue")

read, err := client.GetUpgradeProfile(ctx, id)
if err != nil {
	// handle the error
}
if model := read.Model; model != nil {
	// do something with the model/response object
}

Example Usage: AgentPoolsClient.List

ctx := context.TODO()
id := agentpools.NewManagedClusterID("12345678-1234-9876-4563-123456789012", "example-resource-group", "managedClusterValue")

// alternatively `client.List(ctx, id)` can be used to do batched pagination
items, err := client.ListComplete(ctx, id)
if err != nil {
	// handle the error
}
for _, item := range items {
	// do something
}

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func PossibleValuesForContainerServiceOSTypes

func PossibleValuesForContainerServiceOSTypes() []string

func ValidateAgentPoolID

func ValidateAgentPoolID(input interface{}, key string) (warnings []string, errors []error)

ValidateAgentPoolID checks that 'input' can be parsed as a Agent Pool ID

func ValidateManagedClusterID

func ValidateManagedClusterID(input interface{}, key string) (warnings []string, errors []error)

ValidateManagedClusterID checks that 'input' can be parsed as a Managed Cluster ID

Types

type AgentPool

type AgentPool struct {
	Id   *string `json:"id,omitempty"`
	Name *string `json:"name,omitempty"`
	Type *string `json:"type,omitempty"`
}

type AgentPoolAvailableVersions

type AgentPoolAvailableVersions struct {
	Id         *string                              `json:"id,omitempty"`
	Name       *string                              `json:"name,omitempty"`
	Properties AgentPoolAvailableVersionsProperties `json:"properties"`
	Type       *string                              `json:"type,omitempty"`
}

type AgentPoolAvailableVersionsProperties

type AgentPoolAvailableVersionsProperties struct {
	AgentPoolVersions *[]AgentPoolAvailableVersionsPropertiesAgentPoolVersionsInlined `json:"agentPoolVersions,omitempty"`
}

type AgentPoolAvailableVersionsPropertiesAgentPoolVersionsInlined

type AgentPoolAvailableVersionsPropertiesAgentPoolVersionsInlined struct {
	Default           *bool   `json:"default,omitempty"`
	IsPreview         *bool   `json:"isPreview,omitempty"`
	KubernetesVersion *string `json:"kubernetesVersion,omitempty"`
}

type AgentPoolId

type AgentPoolId struct {
	SubscriptionId     string
	ResourceGroupName  string
	ManagedClusterName string
	AgentPoolName      string
}

AgentPoolId is a struct representing the Resource ID for a Agent Pool

func NewAgentPoolID

func NewAgentPoolID(subscriptionId string, resourceGroupName string, managedClusterName string, agentPoolName string) AgentPoolId

NewAgentPoolID returns a new AgentPoolId struct

func ParseAgentPoolID

func ParseAgentPoolID(input string) (*AgentPoolId, error)

ParseAgentPoolID parses 'input' into a AgentPoolId

func ParseAgentPoolIDInsensitively

func ParseAgentPoolIDInsensitively(input string) (*AgentPoolId, error)

ParseAgentPoolIDInsensitively parses 'input' case-insensitively into a AgentPoolId note: this method should only be used for API response data and not user input

func (AgentPoolId) ID

func (id AgentPoolId) ID() string

ID returns the formatted Agent Pool ID

func (AgentPoolId) Segments

func (id AgentPoolId) Segments() []resourceids.Segment

Segments returns a slice of Resource ID Segments which comprise this Agent Pool ID

func (AgentPoolId) String

func (id AgentPoolId) String() string

String returns a human-readable description of this Agent Pool ID

type AgentPoolOperationPredicate

type AgentPoolOperationPredicate struct {
	Id   *string
	Name *string
	Type *string
}

func (AgentPoolOperationPredicate) Matches

func (p AgentPoolOperationPredicate) Matches(input AgentPool) bool

type AgentPoolUpgradeProfile

type AgentPoolUpgradeProfile struct {
	Id         *string                           `json:"id,omitempty"`
	Name       *string                           `json:"name,omitempty"`
	Properties AgentPoolUpgradeProfileProperties `json:"properties"`
	Type       *string                           `json:"type,omitempty"`
}

type AgentPoolUpgradeProfileProperties

type AgentPoolUpgradeProfileProperties struct {
	KubernetesVersion string                                              `json:"kubernetesVersion"`
	OsType            ContainerServiceOSTypes                             `json:"osType"`
	Upgrades          *[]AgentPoolUpgradeProfilePropertiesUpgradesInlined `json:"upgrades,omitempty"`
}

type AgentPoolUpgradeProfilePropertiesUpgradesInlined

type AgentPoolUpgradeProfilePropertiesUpgradesInlined struct {
	IsPreview         *bool   `json:"isPreview,omitempty"`
	KubernetesVersion *string `json:"kubernetesVersion,omitempty"`
}

type AgentPoolsClient

type AgentPoolsClient struct {
	Client autorest.Client
	// contains filtered or unexported fields
}

func NewAgentPoolsClientWithBaseURI

func NewAgentPoolsClientWithBaseURI(endpoint string) AgentPoolsClient

func (AgentPoolsClient) CreateOrUpdate

func (c AgentPoolsClient) CreateOrUpdate(ctx context.Context, id AgentPoolId, input AgentPool) (result CreateOrUpdateOperationResponse, err error)

CreateOrUpdate ...

func (AgentPoolsClient) CreateOrUpdateThenPoll

func (c AgentPoolsClient) CreateOrUpdateThenPoll(ctx context.Context, id AgentPoolId, input AgentPool) error

CreateOrUpdateThenPoll performs CreateOrUpdate then polls until it's completed

func (AgentPoolsClient) Delete

func (c AgentPoolsClient) Delete(ctx context.Context, id AgentPoolId) (result DeleteOperationResponse, err error)

Delete ...

func (AgentPoolsClient) DeleteThenPoll

func (c AgentPoolsClient) DeleteThenPoll(ctx context.Context, id AgentPoolId) error

DeleteThenPoll performs Delete then polls until it's completed

func (AgentPoolsClient) Get

Get ...

func (AgentPoolsClient) GetAvailableAgentPoolVersions

func (c AgentPoolsClient) GetAvailableAgentPoolVersions(ctx context.Context, id ManagedClusterId) (result GetAvailableAgentPoolVersionsOperationResponse, err error)

GetAvailableAgentPoolVersions ...

func (AgentPoolsClient) GetUpgradeProfile

func (c AgentPoolsClient) GetUpgradeProfile(ctx context.Context, id AgentPoolId) (result GetUpgradeProfileOperationResponse, err error)

GetUpgradeProfile ...

func (AgentPoolsClient) List

List ...

func (AgentPoolsClient) ListComplete

ListComplete retrieves all of the results into a single object

func (AgentPoolsClient) ListCompleteMatchingPredicate

func (c AgentPoolsClient) ListCompleteMatchingPredicate(ctx context.Context, id ManagedClusterId, predicate AgentPoolOperationPredicate) (resp ListCompleteResult, err error)

ListCompleteMatchingPredicate retrieves all of the results and then applied the predicate

type ContainerServiceOSTypes

type ContainerServiceOSTypes string
const (
	ContainerServiceOSTypesLinux   ContainerServiceOSTypes = "Linux"
	ContainerServiceOSTypesWindows ContainerServiceOSTypes = "Windows"
)

type CreateOrUpdateOperationResponse

type CreateOrUpdateOperationResponse struct {
	Poller       polling.LongRunningPoller
	HttpResponse *http.Response
}

type DeleteOperationResponse

type DeleteOperationResponse struct {
	Poller       polling.LongRunningPoller
	HttpResponse *http.Response
}

type GetAvailableAgentPoolVersionsOperationResponse

type GetAvailableAgentPoolVersionsOperationResponse struct {
	HttpResponse *http.Response
	Model        *AgentPoolAvailableVersions
}

type GetOperationResponse

type GetOperationResponse struct {
	HttpResponse *http.Response
	Model        *AgentPool
}

type GetUpgradeProfileOperationResponse

type GetUpgradeProfileOperationResponse struct {
	HttpResponse *http.Response
	Model        *AgentPoolUpgradeProfile
}

type ListCompleteResult

type ListCompleteResult struct {
	Items []AgentPool
}

type ListOperationResponse

type ListOperationResponse struct {
	HttpResponse *http.Response
	Model        *[]AgentPool
	// contains filtered or unexported fields
}

func (ListOperationResponse) HasMore

func (r ListOperationResponse) HasMore() bool

func (ListOperationResponse) LoadMore

func (r ListOperationResponse) LoadMore(ctx context.Context) (resp ListOperationResponse, err error)

type ManagedClusterId

type ManagedClusterId struct {
	SubscriptionId     string
	ResourceGroupName  string
	ManagedClusterName string
}

ManagedClusterId is a struct representing the Resource ID for a Managed Cluster

func NewManagedClusterID

func NewManagedClusterID(subscriptionId string, resourceGroupName string, managedClusterName string) ManagedClusterId

NewManagedClusterID returns a new ManagedClusterId struct

func ParseManagedClusterID

func ParseManagedClusterID(input string) (*ManagedClusterId, error)

ParseManagedClusterID parses 'input' into a ManagedClusterId

func ParseManagedClusterIDInsensitively

func ParseManagedClusterIDInsensitively(input string) (*ManagedClusterId, error)

ParseManagedClusterIDInsensitively parses 'input' case-insensitively into a ManagedClusterId note: this method should only be used for API response data and not user input

func (ManagedClusterId) ID

func (id ManagedClusterId) ID() string

ID returns the formatted Managed Cluster ID

func (ManagedClusterId) Segments

func (id ManagedClusterId) Segments() []resourceids.Segment

Segments returns a slice of Resource ID Segments which comprise this Managed Cluster ID

func (ManagedClusterId) String

func (id ManagedClusterId) String() string

String returns a human-readable description of this Managed Cluster ID

Jump to

Keyboard shortcuts

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