选择您的 Cookie 首选项

我们使用必要 Cookie 和类似工具提供我们的网站和服务。我们使用性能 Cookie 收集匿名统计数据,以便我们可以了解客户如何使用我们的网站并进行改进。必要 Cookie 无法停用,但您可以单击“自定义”或“拒绝”来拒绝性能 Cookie。

如果您同意,AWS 和经批准的第三方还将使用 Cookie 提供有用的网站功能、记住您的首选项并显示相关内容,包括相关广告。要接受或拒绝所有非必要 Cookie,请单击“接受”或“拒绝”。要做出更详细的选择,请单击“自定义”。

ListContainerGroupDefinitionVersions - Amazon GameLift Servers
此页面尚未翻译为您的语言。 请求翻译

ListContainerGroupDefinitionVersions

Retrieves all versions of a container group definition. Use the pagination parameters to retrieve results in a set of sequential pages.

Request options:

  • Get all versions of a specified container group definition. Specify the container group definition name or ARN value. (If the ARN value has a version number, it's ignored.)

Results:

If successful, this operation returns the complete properties of a set of container group definition versions that match the request.

Note

This operation returns the list of container group definitions in descending version order (latest first).

Learn more

Request Syntax

{ "Limit": number, "Name": "string", "NextToken": "string" }

Request Parameters

For information about the parameters that are common to all actions, see Common Parameters.

The request accepts the following data in JSON format.

Note

In the following list, the required parameters are described first.

Name

The unique identifier for the container group definition to retrieve properties for. You can use either the Name or ARN value.

Type: String

Length Constraints: Minimum length of 1. Maximum length of 512.

Pattern: ^[a-zA-Z0-9\-]+$|^arn:.*:containergroupdefinition\/[a-zA-Z0-9\-]+(:[0-9]+)?$

Required: Yes

Limit

The maximum number of results to return. Use this parameter with NextToken to get results as a set of sequential pages.

Type: Integer

Valid Range: Minimum value of 1. Maximum value of 100.

Required: No

NextToken

A token that indicates the start of the next sequential page of results. Use the token that is returned with a previous call to this operation. To start at the beginning of the result set, do not specify a value.

Type: String

Length Constraints: Minimum length of 1. Maximum length of 1024.

Required: No

Response Syntax

{ "ContainerGroupDefinitions": [ { "ContainerGroupDefinitionArn": "string", "ContainerGroupType": "string", "CreationTime": number, "GameServerContainerDefinition": { "ContainerName": "string", "DependsOn": [ { "Condition": "string", "ContainerName": "string" } ], "EnvironmentOverride": [ { "Name": "string", "Value": "string" } ], "ImageUri": "string", "MountPoints": [ { "AccessLevel": "string", "ContainerPath": "string", "InstancePath": "string" } ], "PortConfiguration": { "ContainerPortRanges": [ { "FromPort": number, "Protocol": "string", "ToPort": number } ] }, "ResolvedImageDigest": "string", "ServerSdkVersion": "string" }, "Name": "string", "OperatingSystem": "string", "Status": "string", "StatusReason": "string", "SupportContainerDefinitions": [ { "ContainerName": "string", "DependsOn": [ { "Condition": "string", "ContainerName": "string" } ], "EnvironmentOverride": [ { "Name": "string", "Value": "string" } ], "Essential": boolean, "HealthCheck": { "Command": [ "string" ], "Interval": number, "Retries": number, "StartPeriod": number, "Timeout": number }, "ImageUri": "string", "MemoryHardLimitMebibytes": number, "MountPoints": [ { "AccessLevel": "string", "ContainerPath": "string", "InstancePath": "string" } ], "PortConfiguration": { "ContainerPortRanges": [ { "FromPort": number, "Protocol": "string", "ToPort": number } ] }, "ResolvedImageDigest": "string", "Vcpu": number } ], "TotalMemoryLimitMebibytes": number, "TotalVcpuLimit": number, "VersionDescription": "string", "VersionNumber": number } ], "NextToken": "string" }

Response Elements

If the action is successful, the service sends back an HTTP 200 response.

The following data is returned in JSON format by the service.

ContainerGroupDefinitions

A result set of container group definitions that match the request.

Type: Array of ContainerGroupDefinition objects

NextToken

A token that indicates where to resume retrieving results on the next call to this operation. If no token is returned, these results represent the end of the list.

Type: String

Length Constraints: Minimum length of 1. Maximum length of 1024.

Errors

For information about the errors that are common to all actions, see Common Errors.

InternalServiceException

The service encountered an unrecoverable internal failure while processing the request. Clients can retry such requests immediately or after a waiting period.

HTTP Status Code: 500

InvalidRequestException

One or more parameter values in the request are invalid. Correct the invalid parameter values before retrying.

HTTP Status Code: 400

NotFoundException

The requested resources was not found. The resource was either not created yet or deleted.

HTTP Status Code: 400

UnauthorizedException

The client failed authentication. Clients should not retry such requests.

HTTP Status Code: 400

UnsupportedRegionException

The requested operation is not supported in the Region specified.

HTTP Status Code: 400

Examples

Retrieve versions of a container group definition

This example retrieves all versions of a container group definition. It uses the pagination parameters to retrieve two definitions at a time. The response includes a NextToken, which indicates that there are still more results to retrieve.

HTTP requests are authenticated using an AWS Signature Version 4 signature in the Authorization header field.

Sample Request

{ "Name": "MyAdventureGameContainerGroup", "Limit": 2 }

Sample Response

{ "ContainerGroupDefinitions": [ { "ContainerGroupDefinitionArn": "arn:aws:gamelift:us-west-2:111122223333:containergroupdefinition/MyAdventureGameContainerGroup:3", "ContainerGroupType": "GAME_SERVER", "CreationTime": 1496365885.44, "GameServerContainerDefinition": { "ContainerName": "MyAdventureGameContainer", "ImageUri": "111122223333.dkr.ecr.us-west-2.amazonaws.com/MyAdventureGameContainerImage", "PortConfiguration": { "ContainerPortRanges": [ { "FromPort": 35000, "Protocol": "TCP", "ToPort": 40000 } ] }, "ResolvedImageDigest": "sha256:0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef", "ServerSdkVersion": "5.2.0" } "Name": "MyAdventureGameContainerGroup", "OperatingSystem": "AMAZON_LINUX_2023", "Status": "READY", "TotalMemoryLimitMebibytes": 1024, "TotalVcpuLimit": 1, "VersionNumber": "3" }, { "ContainerGroupDefinitionArn": "arn:aws:gamelift:us-west-2:111122223333:containergroupdefinition/MyAdventureGameContainerGroup:2", "ContainerGroupType": "GAME_SERVER", "CreationTime": 1496365892.11, "GameServerContainerDefinition": { "ContainerName": "MyAdventureGameContainer", "ImageUri": "111122223333.dkr.ecr.us-west-2.amazonaws.com/MyAdventureGameContainerImage", "PortConfiguration": { "ContainerPortRanges": [ { "FromPort": 35000, "Protocol": "TCP", "ToPort": 40000 } ] }, "ResolvedImageDigest": "sha256:0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef", "ServerSdkVersion": "5.2.0" } "Name": "MyAdventureGameContainerGroup", "OperatingSystem": "AMAZON_LINUX_2023", "Status": "COPYING", "TotalMemoryLimitMebibytes": 1024, "TotalVcpuLimit": 1, "VersionNumber": "2" }, ], "NextToken": "eyJhd3NBY2NvdW50SWQiOnsicyI6IjMwMjc3NjAxNjM5OCJ9LCJidWlsZElkIjp7InMiOiJidWlsZC01NWYxZTZmMS1jY2FlLTQ3YTctOWI5ZS1iYjFkYTQwMjEXAMPLE1" }

See Also

For more information about using this API in one of the language-specific AWS SDKs, see the following:

隐私网站条款Cookie 首选项
© 2025, Amazon Web Services, Inc. 或其附属公司。保留所有权利。