Categorygithub.com/Azure/azure-sdk-for-go/sdk/resourcemanager/containerinstance/armcontainerinstance/v2
modulepackage
2.5.0-beta.1
Repository: https://github.com/azure/azure-sdk-for-go.git
Documentation: pkg.go.dev

# README

Azure Container Instance Module for Go

PkgGoDev

The armcontainerinstance module provides operations for working with Azure Container Instance.

Source code

Getting started

Prerequisites

  • an Azure subscription
  • Go 1.18 or above (You could download and install the latest version of Go from here. It will replace the existing Go on your machine. If you want to install multiple Go versions on the same machine, you could refer this doc.)

Install the package

This project uses Go modules for versioning and dependency management.

Install the Azure Container Instance module:

go get github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/containerinstance/armcontainerinstance/v2

Authorization

When creating a client, you will need to provide a credential for authenticating with Azure Container Instance. The azidentity module provides facilities for various ways of authenticating with Azure including client/secret, certificate, managed identity, and more.

cred, err := azidentity.NewDefaultAzureCredential(nil)

For more information on authentication, please see the documentation for azidentity at pkg.go.dev/github.com/Azure/azure-sdk-for-go/sdk/azidentity.

Client Factory

Azure Container Instance module consists of one or more clients. We provide a client factory which could be used to create any client in this module.

clientFactory, err := armcontainerinstance.NewClientFactory(<subscription ID>, cred, nil)

You can use ClientOptions in package github.com/Azure/azure-sdk-for-go/sdk/azcore/arm to set endpoint to connect with public and sovereign clouds as well as Azure Stack. For more information, please see the documentation for azcore at pkg.go.dev/github.com/Azure/azure-sdk-for-go/sdk/azcore.

options := arm.ClientOptions {
    ClientOptions: azcore.ClientOptions {
        Cloud: cloud.AzureChina,
    },
}
clientFactory, err := armcontainerinstance.NewClientFactory(<subscription ID>, cred, &options)

Clients

A client groups a set of related APIs, providing access to its functionality. Create one or more clients to access the APIs you require using client factory.

client := clientFactory.NewContainerGroupProfileClient()

Fakes

The fake package contains types used for constructing in-memory fake servers used in unit tests. This allows writing tests to cover various success/error conditions without the need for connecting to a live service.

Please see https://github.com/Azure/azure-sdk-for-go/tree/main/sdk/samples/fakes for details and examples on how to use fakes.

Provide Feedback

If you encounter bugs or have suggestions, please open an issue and assign the Container Instance label.

Contributing

This project welcomes contributions and suggestions. Most contributions require you to agree to a Contributor License Agreement (CLA) declaring that you have the right to, and actually do, grant us the rights to use your contribution. For details, visit https://cla.microsoft.com.

When you submit a pull request, a CLA-bot will automatically determine whether you need to provide a CLA and decorate the PR appropriately (e.g., label, comment). Simply follow the instructions provided by the bot. You will only need to do this once across all repos using our CLA.

This project has adopted the Microsoft Open Source Code of Conduct. For more information, see the Code of Conduct FAQ or contact [email protected] with any additional questions or comments.

# Packages

No description provided by the author

# Functions

NewClientFactory creates a new instance of ClientFactory with the specified values.
NewContainerGroupProfileClient creates a new instance of ContainerGroupProfileClient with the specified values.
NewContainerGroupProfilesClient creates a new instance of ContainerGroupProfilesClient with the specified values.
NewContainerGroupsClient creates a new instance of ContainerGroupsClient with the specified values.
NewContainersClient creates a new instance of ContainersClient with the specified values.
NewLocationClient creates a new instance of LocationClient with the specified values.
NewOperationsClient creates a new instance of OperationsClient with the specified values.
NewSubnetServiceAssociationLinkClient creates a new instance of SubnetServiceAssociationLinkClient with the specified values.
PossibleContainerGroupIPAddressTypeValues returns the possible values for the ContainerGroupIPAddressType const type.
PossibleContainerGroupNetworkProtocolValues returns the possible values for the ContainerGroupNetworkProtocol const type.
PossibleContainerGroupPriorityValues returns the possible values for the ContainerGroupPriority const type.
PossibleContainerGroupRestartPolicyValues returns the possible values for the ContainerGroupRestartPolicy const type.
PossibleContainerGroupSKUValues returns the possible values for the ContainerGroupSKU const type.
PossibleContainerInstanceOperationsOriginValues returns the possible values for the ContainerInstanceOperationsOrigin const type.
PossibleContainerNetworkProtocolValues returns the possible values for the ContainerNetworkProtocol const type.
PossibleDNSNameLabelReusePolicyValues returns the possible values for the DNSNameLabelReusePolicy const type.
PossibleGpuSKUValues returns the possible values for the GpuSKU const type.
PossibleLogAnalyticsLogTypeValues returns the possible values for the LogAnalyticsLogType const type.
PossibleOperatingSystemTypesValues returns the possible values for the OperatingSystemTypes const type.
PossibleResourceIdentityTypeValues returns the possible values for the ResourceIdentityType const type.
PossibleSchemeValues returns the possible values for the Scheme const type.

# Constants

No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author

# Structs

AzureFileVolume - The properties of the Azure File volume.
CachedImages - The cached image and OS type.
CachedImagesListResult - The response containing cached images.
Capabilities - The regional capabilities.
CapabilitiesCapabilities - The supported capabilities.
CapabilitiesListResult - The response containing list of capabilities.
ClientFactory is a client factory used to create any client in this module.
ConfidentialComputeProperties - The properties for confidential container group.
ConfigMap - The container config map.
Container - A container instance.
ContainerAttachResponse - The information for the output stream from container attach.
ContainerExec - The container execution command, for liveness or readiness probe.
ContainerExecRequest - The container exec request.
ContainerExecRequestTerminalSize - The size of the terminal.
ContainerExecResponse - The information for the container exec command.
ContainerGroup - A container group.
ContainerGroupDiagnostics - Container group diagnostic information.
ContainerGroupIdentity - Identity for the container group.
ContainerGroupListResult - The container group list response that contains the container group properties.
ContainerGroupProfile - A container group profile.
ContainerGroupProfileClient contains the methods for the ContainerGroupProfile group.
ContainerGroupProfileClientGetByRevisionNumberOptions contains the optional parameters for the ContainerGroupProfileClient.GetByRevisionNumber method.
ContainerGroupProfileClientGetByRevisionNumberResponse contains the response from method ContainerGroupProfileClient.GetByRevisionNumber.
ContainerGroupProfileClientListAllRevisionsOptions contains the optional parameters for the ContainerGroupProfileClient.NewListAllRevisionsPager method.
ContainerGroupProfileClientListAllRevisionsResponse contains the response from method ContainerGroupProfileClient.NewListAllRevisionsPager.
ContainerGroupProfileListResult - The container group profile list response that contains the container group profile properties.
ContainerGroupProfilePatch - Properties of container group profile that need to be patched.
ContainerGroupProfileProperties - The container group profile properties.
ContainerGroupProfilePropertiesProperties - The container group profile properties.
ContainerGroupProfileReferenceDefinition - The container group profile reference.
ContainerGroupProfilesClient contains the methods for the ContainerGroupProfiles group.
ContainerGroupProfilesClientCreateOrUpdateOptions contains the optional parameters for the ContainerGroupProfilesClient.CreateOrUpdate method.
ContainerGroupProfilesClientCreateOrUpdateResponse contains the response from method ContainerGroupProfilesClient.CreateOrUpdate.
ContainerGroupProfilesClientDeleteOptions contains the optional parameters for the ContainerGroupProfilesClient.Delete method.
ContainerGroupProfilesClientDeleteResponse contains the response from method ContainerGroupProfilesClient.Delete.
ContainerGroupProfilesClientGetOptions contains the optional parameters for the ContainerGroupProfilesClient.Get method.
ContainerGroupProfilesClientGetResponse contains the response from method ContainerGroupProfilesClient.Get.
ContainerGroupProfilesClientListByResourceGroupOptions contains the optional parameters for the ContainerGroupProfilesClient.NewListByResourceGroupPager method.
ContainerGroupProfilesClientListByResourceGroupResponse contains the response from method ContainerGroupProfilesClient.NewListByResourceGroupPager.
ContainerGroupProfilesClientListOptions contains the optional parameters for the ContainerGroupProfilesClient.NewListPager method.
ContainerGroupProfilesClientListResponse contains the response from method ContainerGroupProfilesClient.NewListPager.
ContainerGroupProfilesClientPatchOptions contains the optional parameters for the ContainerGroupProfilesClient.Patch method.
ContainerGroupProfilesClientPatchResponse contains the response from method ContainerGroupProfilesClient.Patch.
ContainerGroupProperties - The container group properties.
ContainerGroupPropertiesInstanceView - The instance view of the container group.
ContainerGroupPropertiesProperties - The container group properties.
ContainerGroupsClient contains the methods for the ContainerGroups group.
ContainerGroupsClientBeginCreateOrUpdateOptions contains the optional parameters for the ContainerGroupsClient.BeginCreateOrUpdate method.
ContainerGroupsClientBeginDeleteOptions contains the optional parameters for the ContainerGroupsClient.BeginDelete method.
ContainerGroupsClientBeginRestartOptions contains the optional parameters for the ContainerGroupsClient.BeginRestart method.
ContainerGroupsClientBeginStartOptions contains the optional parameters for the ContainerGroupsClient.BeginStart method.
ContainerGroupsClientCreateOrUpdateResponse contains the response from method ContainerGroupsClient.BeginCreateOrUpdate.
ContainerGroupsClientDeleteResponse contains the response from method ContainerGroupsClient.BeginDelete.
ContainerGroupsClientGetOptions contains the optional parameters for the ContainerGroupsClient.Get method.
ContainerGroupsClientGetOutboundNetworkDependenciesEndpointsOptions contains the optional parameters for the ContainerGroupsClient.GetOutboundNetworkDependenciesEndpoints method.
ContainerGroupsClientGetOutboundNetworkDependenciesEndpointsResponse contains the response from method ContainerGroupsClient.GetOutboundNetworkDependenciesEndpoints.
ContainerGroupsClientGetResponse contains the response from method ContainerGroupsClient.Get.
ContainerGroupsClientListByResourceGroupOptions contains the optional parameters for the ContainerGroupsClient.NewListByResourceGroupPager method.
ContainerGroupsClientListByResourceGroupResponse contains the response from method ContainerGroupsClient.NewListByResourceGroupPager.
ContainerGroupsClientListOptions contains the optional parameters for the ContainerGroupsClient.NewListPager method.
ContainerGroupsClientListResponse contains the response from method ContainerGroupsClient.NewListPager.
ContainerGroupsClientRestartResponse contains the response from method ContainerGroupsClient.BeginRestart.
ContainerGroupsClientStartResponse contains the response from method ContainerGroupsClient.BeginStart.
ContainerGroupsClientStopOptions contains the optional parameters for the ContainerGroupsClient.Stop method.
ContainerGroupsClientStopResponse contains the response from method ContainerGroupsClient.Stop.
ContainerGroupsClientUpdateOptions contains the optional parameters for the ContainerGroupsClient.Update method.
ContainerGroupsClientUpdateResponse contains the response from method ContainerGroupsClient.Update.
ContainerGroupSubnetID - Container group subnet information.
ContainerHTTPGet - The container Http Get settings, for liveness or readiness probe.
ContainerPort - The port exposed on the container instance.
ContainerProbe - The container probe, for liveness or readiness.
ContainerProperties - The container instance properties.
ContainerPropertiesInstanceView - The instance view of the container instance.
ContainersClient contains the methods for the Containers group.
ContainersClientAttachOptions contains the optional parameters for the ContainersClient.Attach method.
ContainersClientAttachResponse contains the response from method ContainersClient.Attach.
ContainersClientExecuteCommandOptions contains the optional parameters for the ContainersClient.ExecuteCommand method.
ContainersClientExecuteCommandResponse contains the response from method ContainersClient.ExecuteCommand.
ContainersClientListLogsOptions contains the optional parameters for the ContainersClient.ListLogs method.
ContainersClientListLogsResponse contains the response from method ContainersClient.ListLogs.
ContainerState - The container instance state.
DeploymentExtensionSpec - Extension sidecars to be added to the deployment.
DeploymentExtensionSpecProperties - Extension specific properties.
DNSConfiguration - DNS configuration for the container group.
EncryptionProperties - The container group encryption properties.
EnvironmentVariable - The environment variable to set within the container instance.
Event - A container group or container instance event.
GitRepoVolume - Represents a volume that is populated with the contents of a git repository.
GpuResource - The GPU resource.
HTTPHeader - The HTTP header.
ImageRegistryCredential - Image registry credential.
InitContainerDefinition - The init container definition.
InitContainerPropertiesDefinition - The init container definition properties.
InitContainerPropertiesDefinitionInstanceView - The instance view of the init container.
IPAddress - IP address for the container group.
LocationClient contains the methods for the Location group.
LocationClientListCachedImagesOptions contains the optional parameters for the LocationClient.NewListCachedImagesPager method.
LocationClientListCachedImagesResponse contains the response from method LocationClient.NewListCachedImagesPager.
LocationClientListCapabilitiesOptions contains the optional parameters for the LocationClient.NewListCapabilitiesPager method.
LocationClientListCapabilitiesResponse contains the response from method LocationClient.NewListCapabilitiesPager.
LocationClientListUsageOptions contains the optional parameters for the LocationClient.NewListUsagePager method.
LocationClientListUsageResponse contains the response from method LocationClient.NewListUsagePager.
LogAnalytics - Container group log analytics information.
Logs - The logs.
Operation - An operation for Azure Container Instance service.
OperationDisplay - The display information of the operation.
OperationListResult - The operation list response that contains all operations for Azure Container Instance service.
OperationsClient contains the methods for the Operations group.
OperationsClientListOptions contains the optional parameters for the OperationsClient.NewListPager method.
OperationsClientListResponse contains the response from method OperationsClient.NewListPager.
Port - The port exposed on the container group.
Resource - The Resource model definition.
ResourceLimits - The resource limits.
ResourceRequests - The resource requests.
ResourceRequirements - The resource requirements.
SecurityContextCapabilitiesDefinition - The capabilities to add or drop from a container.
SecurityContextDefinition - The security context for the container.
StandbyPoolProfileDefinition - The standby pool profile reference.
SubnetServiceAssociationLinkClient contains the methods for the SubnetServiceAssociationLink group.
SubnetServiceAssociationLinkClientBeginDeleteOptions contains the optional parameters for the SubnetServiceAssociationLinkClient.BeginDelete method.
SubnetServiceAssociationLinkClientDeleteResponse contains the response from method SubnetServiceAssociationLinkClient.BeginDelete.
Usage - A single usage result.
UsageListResult - The response containing the usage data.
UsageName - The name object of the resource.
UserAssignedIdentities - The list of user identities associated with the container group.
Volume - The properties of the volume.
VolumeMount - The properties of the volume mount.

# Type aliases

ContainerGroupIPAddressType - Specifies if the IP is exposed to the public internet or private VNET.
ContainerGroupNetworkProtocol - The protocol associated with the port.
ContainerGroupPriority - The priority of the container group.
ContainerGroupRestartPolicy - Restart policy for all containers within the container group.
ContainerGroupSKU - The container group SKU.
ContainerInstanceOperationsOrigin - The intended executor of the operation.
ContainerNetworkProtocol - The protocol associated with the port.
DNSNameLabelReusePolicy - The value representing the security enum.
GpuSKU - The SKU of the GPU resource.
LogAnalyticsLogType - The log type to be used.
OperatingSystemTypes - The operating system type required by the containers in the container group.
ResourceIdentityType - The type of identity used for the container group.
Scheme - The scheme.