Freigeben über


ContainerGroup Interface

Implements

public interface ContainerGroup
extends GroupableResource<ContainerInstanceManager,ContainerGroupInner>, Refreshable<ContainerGroup>, Updatable<Update>

An immutable client-side representation of an Azure Container Group.

Method Summary

Modifier and Type Method and Description
abstract ContainerAttachResult attachOutputStream(Container container)

Attaches to the output stream of a specific container instance in a specified container group.

abstract ContainerAttachResult attachOutputStream(String containerName)

Attaches to the output stream of a specific container instance in a specified container group.

abstract Mono<ContainerAttachResult> attachOutputStreamAsync(Container container)

Attaches to the output stream of a specific container instance in a specified container group.

abstract Mono<ContainerAttachResult> attachOutputStreamAsync(String containerName)

Attaches to the output stream of a specific container instance in a specified container group.

abstract DnsNameLabelReusePolicy autoGeneratedDomainNameLabelScope()

Gets the reuse policy of DNS name label for the container group.

abstract Map<String,Container> containers()
abstract DnsConfiguration dnsConfig()
abstract String dnsPrefix()
abstract Set<Event> events()
abstract ContainerExecResponse executeCommand(String containerName, String command, int row, int column)

Starts the exec command for a specific container instance.

abstract Mono<ContainerExecResponse> executeCommandAsync(String containerName, String command, int row, int column)

Starts the exec command for a specific container instance within the container group.

abstract Set<Port> externalPorts()
abstract int[] externalTcpPorts()
abstract int[] externalUdpPorts()
abstract String fqdn()
abstract String getLogContent(String containerName)

Get the log content for the specified container instance within the container group.

abstract String getLogContent(String containerName, int tailLineCount)

Get the log content for the specified container instance within the container group.

abstract Mono<String> getLogContentAsync(String containerName)

Get the log content for the specified container instance within the container group.

abstract Mono<String> getLogContentAsync(String containerName, int tailLineCount)

Get the log content for the specified container instance within the container group.

abstract Collection<String> imageRegistryServers()
abstract String ipAddress()
abstract boolean isIPAddressPrivate()
abstract boolean isIPAddressPublic()
abstract boolean isManagedServiceIdentityEnabled()
abstract LogAnalytics logAnalytics()
abstract ResourceIdentityType managedServiceIdentityType()
abstract OperatingSystemTypes osType()
abstract String provisioningState()
abstract void restart()

Restarts all containers in a container group in place.

abstract Mono<Void> restartAsync()

Restarts all containers in a container group in place asynchronously.

abstract ContainerGroupRestartPolicy restartPolicy()
abstract String state()
abstract void stop()

Stops all containers in a container group.

abstract Mono<Void> stopAsync()

Stops all containers in a container group asynchronously.

abstract List<ContainerGroupSubnetId> subnetIds()
abstract String systemAssignedManagedServiceIdentityPrincipalId()
abstract String systemAssignedManagedServiceIdentityTenantId()
abstract Set<String> userAssignedManagedServiceIdentityIds()
abstract Map<String,Volume> volumes()

Method Details

attachOutputStream

public abstract ContainerAttachResult attachOutputStream(Container container)

Attaches to the output stream of a specific container instance in a specified container group.

Parameters:

container - the container instance

Returns:

the information for the output stream

attachOutputStream

public abstract ContainerAttachResult attachOutputStream(String containerName)

Attaches to the output stream of a specific container instance in a specified container group.

Parameters:

containerName - the name of the container instance

Returns:

the information for the output stream

attachOutputStreamAsync

public abstract Mono attachOutputStreamAsync(Container container)

Attaches to the output stream of a specific container instance in a specified container group.

Parameters:

container - the container instance

Returns:

the information for the output stream

attachOutputStreamAsync

public abstract Mono attachOutputStreamAsync(String containerName)

Attaches to the output stream of a specific container instance in a specified container group.

Parameters:

containerName - the name of the container instance

Returns:

the information for the output stream

autoGeneratedDomainNameLabelScope

public abstract DnsNameLabelReusePolicy autoGeneratedDomainNameLabelScope()

Gets the reuse policy of DNS name label for the container group.

Returns:

the reuse policy

containers

public abstract Map containers()

Returns:

the container instances in this container group

dnsConfig

public abstract DnsConfiguration dnsConfig()

Returns:

the DNS configuration for the container group

dnsPrefix

public abstract String dnsPrefix()

Returns:

the DNS prefix which was specified at creation time

events

public abstract Set events()

Returns:

the container group events

executeCommand

public abstract ContainerExecResponse executeCommand(String containerName, String command, int row, int column)

Starts the exec command for a specific container instance.

Parameters:

containerName - the container instance name
command - the command to be executed
row - the row size of the terminal
column - the column size of the terminal

Returns:

the log lines from the end, up to the number specified

executeCommandAsync

public abstract Mono executeCommandAsync(String containerName, String command, int row, int column)

Starts the exec command for a specific container instance within the container group.

Parameters:

containerName - the container instance name
command - the command to be executed
row - the row size of the terminal
column - the column size of the terminal

Returns:

a representation of the future computation of this call

externalPorts

public abstract Set externalPorts()

Returns:

all the ports publicly exposed for this container group

externalTcpPorts

public abstract int[] externalTcpPorts()

Returns:

the TCP ports publicly exposed for this container group

externalUdpPorts

public abstract int[] externalUdpPorts()

Returns:

the UDP ports publicly exposed for this container group

fqdn

public abstract String fqdn()

Returns:

the FQDN for the container group

getLogContent

public abstract String getLogContent(String containerName)

Get the log content for the specified container instance within the container group.

Parameters:

containerName - the container instance name

Returns:

all available log lines

getLogContent

public abstract String getLogContent(String containerName, int tailLineCount)

Get the log content for the specified container instance within the container group.

Parameters:

containerName - the container instance name
tailLineCount - only get the last log lines up to this

Returns:

the log lines from the end, up to the number specified

getLogContentAsync

public abstract Mono getLogContentAsync(String containerName)

Get the log content for the specified container instance within the container group.

Parameters:

containerName - the container instance name

Returns:

a representation of the future computation of this call

getLogContentAsync

public abstract Mono getLogContentAsync(String containerName, int tailLineCount)

Get the log content for the specified container instance within the container group.

Parameters:

containerName - the container instance name
tailLineCount - only get the last log lines up to this

Returns:

a representation of the future computation of this call

imageRegistryServers

public abstract Collection imageRegistryServers()

Returns:

the Docker image registry servers by which the container group is created from

ipAddress

public abstract String ipAddress()

Returns:

the IP address

isIPAddressPrivate

public abstract boolean isIPAddressPrivate()

Returns:

true if IP address is private

isIPAddressPublic

public abstract boolean isIPAddressPublic()

Returns:

true if IP address is public

isManagedServiceIdentityEnabled

public abstract boolean isManagedServiceIdentityEnabled()

Returns:

whether managed service identity is enabled for the container group

logAnalytics

public abstract LogAnalytics logAnalytics()

Returns:

the log analytics information of the container group.

managedServiceIdentityType

public abstract ResourceIdentityType managedServiceIdentityType()

Returns:

whether managed service identity is system assigned, user assigned, both, or neither

osType

public abstract OperatingSystemTypes osType()

Returns:

the base level OS type required by the containers in the group

provisioningState

public abstract String provisioningState()

Returns:

the provisioningState of the container group

restart

public abstract void restart()

Restarts all containers in a container group in place. If container image has updates, new image will be downloaded.

restartAsync

public abstract Mono restartAsync()

Restarts all containers in a container group in place asynchronously. If container image has updates, new image will be downloaded.

Returns:

a representation of the deferred computation of this call

restartPolicy

public abstract ContainerGroupRestartPolicy restartPolicy()

Returns:

the container group restart policy

state

public abstract String state()

Returns:

the state of the container group; only valid in response

stop

public abstract void stop()

Stops all containers in a container group. Compute resources will be de-allocated and billing will stop.

stopAsync

public abstract Mono stopAsync()

Stops all containers in a container group asynchronously. Compute resources will be de-allocated and billing will stop.

Returns:

a representation of the deferred computation of this call

subnetIds

public abstract List subnetIds()

Returns:

the id of the subnets.

systemAssignedManagedServiceIdentityPrincipalId

public abstract String systemAssignedManagedServiceIdentityPrincipalId()

Returns:

the principal id of the system assigned managed service identity. Null if managed service identity is not configured.

systemAssignedManagedServiceIdentityTenantId

public abstract String systemAssignedManagedServiceIdentityTenantId()

Returns:

the tenant id of the system assigned managed service identity. Null if managed service identity is not configured.

userAssignedManagedServiceIdentityIds

public abstract Set userAssignedManagedServiceIdentityIds()

Returns:

the ids of the user assigned managed service identities. Returns an empty set if no MSIs are set.

volumes

public abstract Map volumes()

Returns:

the volumes for this container group

Applies to