2024/11/12 - Amazon GameLift - 9 new11 updated api methods
Changes Amazon GameLift releases container fleets support for general availability. Deploy Linux-based containerized game server software for hosting on Amazon GameLift.
Updates properties in an existing container group definition. This operation doesn't replace the definition. Instead, it creates a new version of the definition and saves it separately. You can access all versions that you choose to retain.
The only property you can't update is the container group type.
Request options:
Update based on the latest version of the container group definition. Specify the container group definition name only, or use an ARN value without a version number. Provide updated values for the properties that you want to change only. All other values remain the same as the latest version.
Update based on a specific version of the container group definition. Specify the container group definition name and a source version number, or use an ARN value with a version number. Provide updated values for the properties that you want to change only. All other values remain the same as the source version.
Change a game server container definition. Provide the updated container definition.
Add or change a support container definition. Provide a complete set of container definitions, including the updated definition.
Remove a support container definition. Provide a complete set of container definitions, excluding the definition to remove. If the container group has only one support container definition, provide an empty set.
Results:
If successful, this operation returns the complete properties of the new container group definition version.
If the container group definition version is used in an active fleets, the update automatically initiates a new fleet deployment of the new version. You can track a fleet's deployments using ListFleetDeployments.
See also: AWS API Documentation
Request Syntax
client.update_container_group_definition( Name='string', GameServerContainerDefinition={ 'ContainerName': 'string', 'DependsOn': [ { 'ContainerName': 'string', 'Condition': 'START'|'COMPLETE'|'SUCCESS'|'HEALTHY' }, ], 'MountPoints': [ { 'InstancePath': 'string', 'ContainerPath': 'string', 'AccessLevel': 'READ_ONLY'|'READ_AND_WRITE' }, ], 'EnvironmentOverride': [ { 'Name': 'string', 'Value': 'string' }, ], 'ImageUri': 'string', 'PortConfiguration': { 'ContainerPortRanges': [ { 'FromPort': 123, 'ToPort': 123, 'Protocol': 'TCP'|'UDP' }, ] }, 'ServerSdkVersion': 'string' }, SupportContainerDefinitions=[ { 'ContainerName': 'string', 'DependsOn': [ { 'ContainerName': 'string', 'Condition': 'START'|'COMPLETE'|'SUCCESS'|'HEALTHY' }, ], 'MountPoints': [ { 'InstancePath': 'string', 'ContainerPath': 'string', 'AccessLevel': 'READ_ONLY'|'READ_AND_WRITE' }, ], 'EnvironmentOverride': [ { 'Name': 'string', 'Value': 'string' }, ], 'Essential': True|False, 'HealthCheck': { 'Command': [ 'string', ], 'Interval': 123, 'Retries': 123, 'StartPeriod': 123, 'Timeout': 123 }, 'ImageUri': 'string', 'MemoryHardLimitMebibytes': 123, 'PortConfiguration': { 'ContainerPortRanges': [ { 'FromPort': 123, 'ToPort': 123, 'Protocol': 'TCP'|'UDP' }, ] }, 'Vcpu': 123.0 }, ], TotalMemoryLimitMebibytes=123, TotalVcpuLimit=123.0, VersionDescription='string', SourceVersionNumber=123, OperatingSystem='AMAZON_LINUX_2023' )
string
[REQUIRED]
A descriptive identifier for the container group definition. The name value must be unique in an Amazon Web Services Region.
dict
An updated definition for the game server container in this group. Define a game server container only when the container group type is GAME_SERVER. You can pass in your container definitions as a JSON file.
ContainerName (string) -- [REQUIRED]
A string that uniquely identifies the container definition within a container group.
DependsOn (list) --
Establishes dependencies between this container and the status of other containers in the same container group. A container can have dependencies on multiple different containers.
You can use dependencies to establish a startup/shutdown sequence across the container group. For example, you might specify that ContainerB has a START dependency on ContainerA. This dependency means that ContainerB can't start until after ContainerA has started. This dependency is reversed on shutdown, which means that ContainerB must shut down before ContainerA can shut down.
(dict) --
A container's dependency on another container in the same container group. The dependency impacts how the dependent container is able to start or shut down based the status of the other container.
For example, ContainerA is configured with the following dependency: a START dependency on ContainerB. This means that ContainerA can't start until ContainerB has started. It also means that ContainerA must shut down before ContainerB.
eiifcbfhgrdurhnucnufkgbnbnnerrvbtjvljdetkehc**Part of:** GameServerContainerDefinition, GameServerContainerDefinitionInput, SupportContainerDefinition, SupportContainerDefinitionInput
ContainerName (string) -- [REQUIRED]
A descriptive label for the container definition that this container depends on.
Condition (string) -- [REQUIRED]
The condition that the dependency container must reach before the dependent container can start. Valid conditions include:
START - The dependency container must have started.
COMPLETE - The dependency container has run to completion (exits). Use this condition with nonessential containers, such as those that run a script and then exit. The dependency container can't be an essential container.
SUCCESS - The dependency container has run to completion and exited with a zero status. The dependency container can't be an essential container.
HEALTHY - The dependency container has passed its Docker health check. Use this condition with dependency containers that have health checks configured. This condition is confirmed at container group startup only.
MountPoints (list) --
A mount point that binds a path inside the container to a file or directory on the host system and lets it access the file or directory.
(dict) --
A mount point that binds a container to a file or directory on the host system.
Part of: GameServerContainerDefinition, GameServerContainerDefinitionInput, SupportContainerDefinition, SupportContainerDefinitionInput
InstancePath (string) -- [REQUIRED]
The path to the source file or directory.
ContainerPath (string) --
The mount path on the container. If this property isn't set, the instance path is used.
AccessLevel (string) --
The type of access for the container.
EnvironmentOverride (list) --
A set of environment variables to pass to the container on startup. See the ContainerDefinition::environment parameter in the Amazon Elastic Container Service API Reference.
(dict) --
An environment variable to set inside a container, in the form of a key-value pair.
Part of: GameServerContainerDefinition, GameServerContainerDefinitionInput, SupportContainerDefinition, SupportContainerDefinitionInput
Name (string) -- [REQUIRED]
The environment variable name.
Value (string) -- [REQUIRED]
The environment variable value.
ImageUri (string) -- [REQUIRED]
The location of the container image to deploy to a container fleet. Provide an image in an Amazon Elastic Container Registry public or private repository. The repository must be in the same Amazon Web Services account and Amazon Web Services Region where you're creating the container group definition. For limits on image size, see Amazon GameLift endpoints and quotas. You can use any of the following image URI formats:
Image ID only: [AWS account].dkr.ecr.[AWS region].amazonaws.com/[repository ID]
Image ID and digest: [AWS account].dkr.ecr.[AWS region].amazonaws.com/[repository ID]@[digest]
Image ID and tag: [AWS account].dkr.ecr.[AWS region].amazonaws.com/[repository ID]:[tag]
PortConfiguration (dict) -- [REQUIRED]
A set of ports that Amazon GameLift can assign to processes in the container. Processes, must be assigned a container port to accept inbound traffic connections. For example, a game server process requires a container port to allow game clients to connect to it. Container ports aren't directly accessed by inbound traffic. Instead, Amazon GameLift maps container ports to externally accessible connection ports (see the container fleet property ConnectionPortRange).
ContainerPortRanges (list) -- [REQUIRED]
A set of one or more container port number ranges. The ranges can't overlap.
(dict) --
A set of one or more port numbers that can be opened on the container.
Part of: ContainerPortConfiguration
FromPort (integer) -- [REQUIRED]
A starting value for the range of allowed port numbers.
ToPort (integer) -- [REQUIRED]
An ending value for the range of allowed port numbers. Port numbers are end-inclusive. This value must be equal to or greater than FromPort.
Protocol (string) -- [REQUIRED]
The network protocol that these ports support.
ServerSdkVersion (string) -- [REQUIRED]
The Amazon GameLift server SDK version that the game server is integrated with. Only game servers using 5.2.0 or higher are compatible with container fleets.
list
One or more definitions for support containers in this group. You can define a support container in any type of container group. You can pass in your container definitions as a JSON file.
(dict) --
Describes a support container in a container group. You can define a support container in either a game server container group or a per-instance container group. Support containers don't run game server processes.
This definition includes container configuration, resources, and start instructions. Use this data type when creating or updating a container group definition. For properties of a deployed support container, see SupportContainerDefinition.
Use with: CreateContainerGroupDefinition, UpdateContainerGroupDefinition
ContainerName (string) -- [REQUIRED]
A string that uniquely identifies the container definition within a container group.
DependsOn (list) --
Establishes dependencies between this container and the status of other containers in the same container group. A container can have dependencies on multiple different containers.
.
You can use dependencies to establish a startup/shutdown sequence across the container group. For example, you might specify that ContainerB has a START dependency on ContainerA. This dependency means that ContainerB can't start until after ContainerA has started. This dependency is reversed on shutdown, which means that ContainerB must shut down before ContainerA can shut down.
(dict) --
A container's dependency on another container in the same container group. The dependency impacts how the dependent container is able to start or shut down based the status of the other container.
For example, ContainerA is configured with the following dependency: a START dependency on ContainerB. This means that ContainerA can't start until ContainerB has started. It also means that ContainerA must shut down before ContainerB.
eiifcbfhgrdurhnucnufkgbnbnnerrvbtjvljdetkehc**Part of:** GameServerContainerDefinition, GameServerContainerDefinitionInput, SupportContainerDefinition, SupportContainerDefinitionInput
ContainerName (string) -- [REQUIRED]
A descriptive label for the container definition that this container depends on.
Condition (string) -- [REQUIRED]
The condition that the dependency container must reach before the dependent container can start. Valid conditions include:
START - The dependency container must have started.
COMPLETE - The dependency container has run to completion (exits). Use this condition with nonessential containers, such as those that run a script and then exit. The dependency container can't be an essential container.
SUCCESS - The dependency container has run to completion and exited with a zero status. The dependency container can't be an essential container.
HEALTHY - The dependency container has passed its Docker health check. Use this condition with dependency containers that have health checks configured. This condition is confirmed at container group startup only.
MountPoints (list) --
A mount point that binds a path inside the container to a file or directory on the host system and lets it access the file or directory.
(dict) --
A mount point that binds a container to a file or directory on the host system.
Part of: GameServerContainerDefinition, GameServerContainerDefinitionInput, SupportContainerDefinition, SupportContainerDefinitionInput
InstancePath (string) -- [REQUIRED]
The path to the source file or directory.
ContainerPath (string) --
The mount path on the container. If this property isn't set, the instance path is used.
AccessLevel (string) --
The type of access for the container.
EnvironmentOverride (list) --
A set of environment variables to pass to the container on startup. See the ContainerDefinition::environment parameter in the Amazon Elastic Container Service API Reference.
(dict) --
An environment variable to set inside a container, in the form of a key-value pair.
Part of: GameServerContainerDefinition, GameServerContainerDefinitionInput, SupportContainerDefinition, SupportContainerDefinitionInput
Name (string) -- [REQUIRED]
The environment variable name.
Value (string) -- [REQUIRED]
The environment variable value.
Essential (boolean) --
Flags the container as vital for the container group to function properly. If an essential container fails, the entire container group restarts. At least one support container in a per-instance container group must be essential. When flagging a container as essential, also configure a health check so that the container can signal that it's healthy.
HealthCheck (dict) --
Configuration for a non-terminal health check. A container automatically restarts if it stops functioning. With a health check, you can define additional reasons to flag a container as unhealthy and restart it. If an essential container fails a health check, the entire container group restarts.
Command (list) -- [REQUIRED]
A string array that specifies the command that the container runs to determine if it's healthy.
(string) --
Interval (integer) --
The time period (in seconds) between each health check.
Retries (integer) --
The number of times to retry a failed health check before flagging the container unhealthy. The first run of the command does not count as a retry.
StartPeriod (integer) --
The optional grace period (in seconds) to give a container time to bootstrap before the first failed health check counts toward the number of retries.
Timeout (integer) --
The time period (in seconds) to wait for a health check to succeed before counting a failed health check.
ImageUri (string) -- [REQUIRED]
The location of the container image to deploy to a container fleet. Provide an image in an Amazon Elastic Container Registry public or private repository. The repository must be in the same Amazon Web Services account and Amazon Web Services Region where you're creating the container group definition. For limits on image size, see Amazon GameLift endpoints and quotas. You can use any of the following image URI formats:
Image ID only: [AWS account].dkr.ecr.[AWS region].amazonaws.com/[repository ID]
Image ID and digest: [AWS account].dkr.ecr.[AWS region].amazonaws.com/[repository ID]@[digest]
Image ID and tag: [AWS account].dkr.ecr.[AWS region].amazonaws.com/[repository ID]:[tag]
MemoryHardLimitMebibytes (integer) --
A specified amount of memory (in MiB) to reserve for this container. If you don't specify a container-specific memory limit, the container shares the container group's total memory allocation.
Related data type: ContainerGroupDefinition TotalMemoryLimitMebibytes
PortConfiguration (dict) --
A set of ports that Amazon GameLift can assign to processes in the container. Any processes that accept inbound traffic connections must be assigned a port from this set. The container port range must be large enough to assign one to each process in the container that needs one.
Container ports aren't directly accessed by inbound traffic. Amazon GameLift maps these container ports to externally accessible connection ports, which are assigned as needed from the container fleet's ConnectionPortRange.
ContainerPortRanges (list) -- [REQUIRED]
A set of one or more container port number ranges. The ranges can't overlap.
(dict) --
A set of one or more port numbers that can be opened on the container.
Part of: ContainerPortConfiguration
FromPort (integer) -- [REQUIRED]
A starting value for the range of allowed port numbers.
ToPort (integer) -- [REQUIRED]
An ending value for the range of allowed port numbers. Port numbers are end-inclusive. This value must be equal to or greater than FromPort.
Protocol (string) -- [REQUIRED]
The network protocol that these ports support.
Vcpu (float) --
The number of vCPU units to reserve for this container. The container can use more resources when needed, if available. If you don't reserve CPU units for this container, it shares the container group's total vCPU limit.
Related data type: ContainerGroupDefinition TotalCpuLimit
integer
The maximum amount of memory (in MiB) to allocate to the container group. All containers in the group share this memory. If you specify memory limits for an individual container, the total value must be greater than any individual container's memory limit.
float
The maximum amount of vCPU units to allocate to the container group (1 vCPU is equal to 1024 CPU units). All containers in the group share this memory. If you specify vCPU limits for individual containers, the total value must be equal to or greater than the sum of the CPU limits for all containers in the group.
string
A description for this update to the container group definition.
integer
The container group definition version to update. The new version starts with values from the source version, and then updates values included in this request.
string
The platform that all containers in the group use. Containers in a group must run on the same operating system.
dict
Response Syntax
{ 'ContainerGroupDefinition': { 'ContainerGroupDefinitionArn': 'string', 'CreationTime': datetime(2015, 1, 1), 'OperatingSystem': 'AMAZON_LINUX_2023', 'Name': 'string', 'ContainerGroupType': 'GAME_SERVER'|'PER_INSTANCE', 'TotalMemoryLimitMebibytes': 123, 'TotalVcpuLimit': 123.0, 'GameServerContainerDefinition': { 'ContainerName': 'string', 'DependsOn': [ { 'ContainerName': 'string', 'Condition': 'START'|'COMPLETE'|'SUCCESS'|'HEALTHY' }, ], 'MountPoints': [ { 'InstancePath': 'string', 'ContainerPath': 'string', 'AccessLevel': 'READ_ONLY'|'READ_AND_WRITE' }, ], 'EnvironmentOverride': [ { 'Name': 'string', 'Value': 'string' }, ], 'ImageUri': 'string', 'PortConfiguration': { 'ContainerPortRanges': [ { 'FromPort': 123, 'ToPort': 123, 'Protocol': 'TCP'|'UDP' }, ] }, 'ResolvedImageDigest': 'string', 'ServerSdkVersion': 'string' }, 'SupportContainerDefinitions': [ { 'ContainerName': 'string', 'DependsOn': [ { 'ContainerName': 'string', 'Condition': 'START'|'COMPLETE'|'SUCCESS'|'HEALTHY' }, ], 'MountPoints': [ { 'InstancePath': 'string', 'ContainerPath': 'string', 'AccessLevel': 'READ_ONLY'|'READ_AND_WRITE' }, ], 'EnvironmentOverride': [ { 'Name': 'string', 'Value': 'string' }, ], 'Essential': True|False, 'HealthCheck': { 'Command': [ 'string', ], 'Interval': 123, 'Retries': 123, 'StartPeriod': 123, 'Timeout': 123 }, 'ImageUri': 'string', 'MemoryHardLimitMebibytes': 123, 'PortConfiguration': { 'ContainerPortRanges': [ { 'FromPort': 123, 'ToPort': 123, 'Protocol': 'TCP'|'UDP' }, ] }, 'ResolvedImageDigest': 'string', 'Vcpu': 123.0 }, ], 'VersionNumber': 123, 'VersionDescription': 'string', 'Status': 'READY'|'COPYING'|'FAILED', 'StatusReason': 'string' } }
Response Structure
(dict) --
ContainerGroupDefinition (dict) --
The properties of the updated container group definition version.
ContainerGroupDefinitionArn (string) --
The Amazon Resource Name ( ARN) that is assigned to an Amazon GameLift ContainerGroupDefinition resource. It uniquely identifies the resource across all Amazon Web Services Regions. Format is arn:aws:gamelift:[region]::containergroupdefinition/[container group definition name]:[version].
CreationTime (datetime) --
A time stamp indicating when this data object was created. Format is a number expressed in Unix time as milliseconds (for example "1469498468.057").
OperatingSystem (string) --
The platform that all containers in the container group definition run on.
Name (string) --
A descriptive identifier for the container group definition. The name value is unique in an Amazon Web Services Region.
ContainerGroupType (string) --
The type of container group. Container group type determines how Amazon GameLift deploys the container group on each fleet instance.
TotalMemoryLimitMebibytes (integer) --
The amount of memory (in MiB) on a fleet instance to allocate for the container group. All containers in the group share these resources.
You can set a limit for each container definition in the group. If individual containers have limits, this total value must be greater than any individual container's memory limit.
TotalVcpuLimit (float) --
The amount of vCPU units on a fleet instance to allocate for the container group (1 vCPU is equal to 1024 CPU units). All containers in the group share these resources. You can set a limit for each container definition in the group. If individual containers have limits, this total value must be equal to or greater than the sum of the limits for each container in the group.
GameServerContainerDefinition (dict) --
The definition for the game server container in this group. This property is used only when the container group type is GAME_SERVER. This container definition specifies a container image with the game server build.
ContainerName (string) --
The container definition identifier. Container names are unique within a container group definition.
DependsOn (list) --
Indicates that the container relies on the status of other containers in the same container group during startup and shutdown sequences. A container might have dependencies on multiple containers.
(dict) --
A container's dependency on another container in the same container group. The dependency impacts how the dependent container is able to start or shut down based the status of the other container.
For example, ContainerA is configured with the following dependency: a START dependency on ContainerB. This means that ContainerA can't start until ContainerB has started. It also means that ContainerA must shut down before ContainerB.
eiifcbfhgrdurhnucnufkgbnbnnerrvbtjvljdetkehc**Part of:** GameServerContainerDefinition, GameServerContainerDefinitionInput, SupportContainerDefinition, SupportContainerDefinitionInput
ContainerName (string) --
A descriptive label for the container definition that this container depends on.
Condition (string) --
The condition that the dependency container must reach before the dependent container can start. Valid conditions include:
START - The dependency container must have started.
COMPLETE - The dependency container has run to completion (exits). Use this condition with nonessential containers, such as those that run a script and then exit. The dependency container can't be an essential container.
SUCCESS - The dependency container has run to completion and exited with a zero status. The dependency container can't be an essential container.
HEALTHY - The dependency container has passed its Docker health check. Use this condition with dependency containers that have health checks configured. This condition is confirmed at container group startup only.
MountPoints (list) --
A mount point that binds a path inside the container to a file or directory on the host system and lets it access the file or directory.
(dict) --
A mount point that binds a container to a file or directory on the host system.
Part of: GameServerContainerDefinition, GameServerContainerDefinitionInput, SupportContainerDefinition, SupportContainerDefinitionInput
InstancePath (string) --
The path to the source file or directory.
ContainerPath (string) --
The mount path on the container. If this property isn't set, the instance path is used.
AccessLevel (string) --
The type of access for the container.
EnvironmentOverride (list) --
A set of environment variables that's passed to the container on startup. See the ContainerDefinition::environment parameter in the Amazon Elastic Container Service API Reference.
(dict) --
An environment variable to set inside a container, in the form of a key-value pair.
Part of: GameServerContainerDefinition, GameServerContainerDefinitionInput, SupportContainerDefinition, SupportContainerDefinitionInput
Name (string) --
The environment variable name.
Value (string) --
The environment variable value.
ImageUri (string) --
The URI to the image that Amazon GameLift uses when deploying this container to a container fleet. For a more specific identifier, see ResolvedImageDigest.
PortConfiguration (dict) --
The set of ports that are available to bind to processes in the container. For example, a game server process requires a container port to allow game clients to connect to it. Container ports aren't directly accessed by inbound traffic. Amazon GameLift maps these container ports to externally accessible connection ports, which are assigned as needed from the container fleet's ConnectionPortRange.
ContainerPortRanges (list) --
A set of one or more container port number ranges. The ranges can't overlap.
(dict) --
A set of one or more port numbers that can be opened on the container.
Part of: ContainerPortConfiguration
FromPort (integer) --
A starting value for the range of allowed port numbers.
ToPort (integer) --
An ending value for the range of allowed port numbers. Port numbers are end-inclusive. This value must be equal to or greater than FromPort.
Protocol (string) --
The network protocol that these ports support.
ResolvedImageDigest (string) --
A unique and immutable identifier for the container image. The digest is a SHA 256 hash of the container image manifest.
ServerSdkVersion (string) --
The Amazon GameLift server SDK version that the game server is integrated with. Only game servers using 5.2.0 or higher are compatible with container fleets.
SupportContainerDefinitions (list) --
The set of definitions for support containers in this group. A container group definition might have zero support container definitions. Support container can be used in any type of container group.
(dict) --
Describes a support container in a container group. A support container might be in a game server container group or a per-instance container group. Support containers don't run game server processes.
You can update a support container definition and deploy the updates to an existing fleet. When creating or updating a game server container group definition, use the property GameServerContainerDefinitionInput.
Part of: ContainerGroupDefinition
Returned by: DescribeContainerGroupDefinition, ListContainerGroupDefinitions, UpdateContainerGroupDefinition
ContainerName (string) --
The container definition identifier. Container names are unique within a container group definition.
DependsOn (list) --
Indicates that the container relies on the status of other containers in the same container group during its startup and shutdown sequences. A container might have dependencies on multiple containers.
(dict) --
A container's dependency on another container in the same container group. The dependency impacts how the dependent container is able to start or shut down based the status of the other container.
For example, ContainerA is configured with the following dependency: a START dependency on ContainerB. This means that ContainerA can't start until ContainerB has started. It also means that ContainerA must shut down before ContainerB.
eiifcbfhgrdurhnucnufkgbnbnnerrvbtjvljdetkehc**Part of:** GameServerContainerDefinition, GameServerContainerDefinitionInput, SupportContainerDefinition, SupportContainerDefinitionInput
ContainerName (string) --
A descriptive label for the container definition that this container depends on.
Condition (string) --
The condition that the dependency container must reach before the dependent container can start. Valid conditions include:
START - The dependency container must have started.
COMPLETE - The dependency container has run to completion (exits). Use this condition with nonessential containers, such as those that run a script and then exit. The dependency container can't be an essential container.
SUCCESS - The dependency container has run to completion and exited with a zero status. The dependency container can't be an essential container.
HEALTHY - The dependency container has passed its Docker health check. Use this condition with dependency containers that have health checks configured. This condition is confirmed at container group startup only.
MountPoints (list) --
A mount point that binds a path inside the container to a file or directory on the host system and lets it access the file or directory.
(dict) --
A mount point that binds a container to a file or directory on the host system.
Part of: GameServerContainerDefinition, GameServerContainerDefinitionInput, SupportContainerDefinition, SupportContainerDefinitionInput
InstancePath (string) --
The path to the source file or directory.
ContainerPath (string) --
The mount path on the container. If this property isn't set, the instance path is used.
AccessLevel (string) --
The type of access for the container.
EnvironmentOverride (list) --
A set of environment variables that's passed to the container on startup. See the ContainerDefinition::environment parameter in the Amazon Elastic Container Service API Reference.
(dict) --
An environment variable to set inside a container, in the form of a key-value pair.
Part of: GameServerContainerDefinition, GameServerContainerDefinitionInput, SupportContainerDefinition, SupportContainerDefinitionInput
Name (string) --
The environment variable name.
Value (string) --
The environment variable value.
Essential (boolean) --
Indicates whether the container is vital to the container group. If an essential container fails, the entire container group restarts.
HealthCheck (dict) --
A configuration for a non-terminal health check. A support container automatically restarts if it stops functioning or if it fails this health check.
Command (list) --
A string array that specifies the command that the container runs to determine if it's healthy.
(string) --
Interval (integer) --
The time period (in seconds) between each health check.
Retries (integer) --
The number of times to retry a failed health check before flagging the container unhealthy. The first run of the command does not count as a retry.
StartPeriod (integer) --
The optional grace period (in seconds) to give a container time to bootstrap before the first failed health check counts toward the number of retries.
Timeout (integer) --
The time period (in seconds) to wait for a health check to succeed before counting a failed health check.
ImageUri (string) --
The URI to the image that Amazon GameLift deploys to a container fleet. For a more specific identifier, see ResolvedImageDigest.
MemoryHardLimitMebibytes (integer) --
The amount of memory that Amazon GameLift makes available to the container. If memory limits aren't set for an individual container, the container shares the container group's total memory allocation.
Related data type: ContainerGroupDefinition$TotalMemoryLimitMebibytes
PortConfiguration (dict) --
A set of ports that allow access to the container from external users. Processes running in the container can bind to a one of these ports. Container ports aren't directly accessed by inbound traffic. Amazon GameLift maps these container ports to externally accessible connection ports, which are assigned as needed from the container fleet's ConnectionPortRange.
ContainerPortRanges (list) --
A set of one or more container port number ranges. The ranges can't overlap.
(dict) --
A set of one or more port numbers that can be opened on the container.
Part of: ContainerPortConfiguration
FromPort (integer) --
A starting value for the range of allowed port numbers.
ToPort (integer) --
An ending value for the range of allowed port numbers. Port numbers are end-inclusive. This value must be equal to or greater than FromPort.
Protocol (string) --
The network protocol that these ports support.
ResolvedImageDigest (string) --
A unique and immutable identifier for the container image. The digest is a SHA 256 hash of the container image manifest.
Vcpu (float) --
The number of vCPU units that are reserved for the container. If no resources are reserved, the container shares the total vCPU limit for the container group.
Related data type: ContainerGroupDefinition$TotalVcpuLimit
VersionNumber (integer) --
Indicates the version of a particular container group definition. This number is incremented automatically when you update a container group definition. You can view, update, or delete individual versions or the entire container group definition.
VersionDescription (string) --
An optional description that was provided for a container group definition update. Each version can have a unique description.
Status (string) --
Current status of the container group definition resource. Values include:
COPYING -- Amazon GameLift is in the process of making copies of all container images that are defined in the group. While in this state, the resource can't be used to create a container fleet.
READY -- Amazon GameLift has copied the registry images for all containers that are defined in the group. You can use a container group definition in this status to create a container fleet.
FAILED -- Amazon GameLift failed to create a valid container group definition resource. For more details on the cause of the failure, see StatusReason. A container group definition resource in failed status will be deleted within a few minutes.
StatusReason (string) --
Additional information about a container group definition that's in FAILED status. Possible reasons include:
An internal issue prevented Amazon GameLift from creating the container group definition resource. Delete the failed resource and call CreateContainerGroupDefinitionagain.
An access-denied message means that you don't have permissions to access the container image on ECR. See IAM permission examples for help setting up required IAM permissions for Amazon GameLift.
The ImageUri value for at least one of the containers in the container group definition was invalid or not found in the current Amazon Web Services account.
At least one of the container images referenced in the container group definition exceeds the allowed size. For size limits, see Amazon GameLift endpoints and quotas.
At least one of the container images referenced in the container group definition uses a different operating system than the one defined for the container group.
Creates a managed fleet of Amazon Elastic Compute Cloud (Amazon EC2) instances to host your containerized game servers. Use this operation to define how to deploy a container architecture onto each fleet instance and configure fleet settings. You can create a container fleet in any Amazon Web Services Regions that Amazon GameLift supports for multi-location fleets. A container fleet can be deployed to a single location or multiple locations. Container fleets are deployed with Amazon Linux 2023 as the instance operating system.
Define the fleet's container architecture using container group definitions. Each fleet can have one of the following container group types:
The game server container group runs your game server build and dependent software. Amazon GameLift deploys one or more replicas of this container group to each fleet instance. The number of replicas depends on the computing capabilities of the fleet instance in use.
An optional per-instance container group might be used to run other software that only needs to run once per instance, such as background services, logging, or test processes. One per-instance container group is deployed to each fleet instance.
Each container group can include the definition for one or more containers. A container definition specifies a container image that is stored in an Amazon Elastic Container Registry (Amazon ECR) public or private repository.
Request options
Use this operation to make the following types of requests. Most fleet settings have default values, so you can create a working fleet with a minimal configuration and default values, which you can customize later.
Create a fleet with no container groups. You can configure a container fleet and then add container group definitions later. In this scenario, no fleet instances are deployed, and the fleet can't host game sessions until you add a game server container group definition. Provide the following required parameter values:
FleetRoleArn
Create a fleet with a game server container group. Provide the following required parameter values:
FleetRoleArn
GameServerContainerGroupDefinitionName
Create a fleet with a game server container group and a per-instance container group. Provide the following required parameter values:
FleetRoleArn
GameServerContainerGroupDefinitionName
PerInstanceContainerGroupDefinitionName
Results
If successful, this operation creates a new container fleet resource, places it in PENDING status, and initiates the fleet creation workflow. For fleets with container groups, this workflow starts a fleet deployment and transitions the status to ACTIVE. Fleets without a container group are placed in CREATED status.
You can update most of the properties of a fleet, including container group definitions, and deploy the update across all fleet instances. Use a fleet update to deploy a new game server version update across the container fleet.
See also: AWS API Documentation
Request Syntax
client.create_container_fleet( FleetRoleArn='string', Description='string', GameServerContainerGroupDefinitionName='string', PerInstanceContainerGroupDefinitionName='string', InstanceConnectionPortRange={ 'FromPort': 123, 'ToPort': 123 }, InstanceInboundPermissions=[ { 'FromPort': 123, 'ToPort': 123, 'IpRange': 'string', 'Protocol': 'TCP'|'UDP' }, ], GameServerContainerGroupsPerInstance=123, InstanceType='string', BillingType='ON_DEMAND'|'SPOT', Locations=[ { 'Location': 'string' }, ], MetricGroups=[ 'string', ], NewGameSessionProtectionPolicy='NoProtection'|'FullProtection', GameSessionCreationLimitPolicy={ 'NewGameSessionsPerCreator': 123, 'PolicyPeriodInMinutes': 123 }, LogConfiguration={ 'LogDestination': 'NONE'|'CLOUDWATCH'|'S3', 'S3BucketName': 'string', 'LogGroupArn': 'string' }, Tags=[ { 'Key': 'string', 'Value': 'string' }, ] )
string
[REQUIRED]
The unique identifier for an Identity and Access Management (IAM) role with permissions to run your containers on resources that are managed by Amazon GameLift. Use an IAM service role with the GameLiftContainerFleetPolicy managed policy attached. For more information, see Set up an IAM service role. You can't change this fleet property after the fleet is created.
IAM role ARN values use the following pattern: arn:aws:iam::[Amazon Web Services account]:role/[role name].
string
A meaningful description of the container fleet.
string
A container group definition resource that describes how to deploy containers with your game server build and support software onto each fleet instance. You can specify the container group definition's name to use the latest version. Alternatively, provide an ARN value with a specific version number.
Create a container group definition by calling CreateContainerGroupDefinition. This operation creates a ContainerGroupDefinition resource.
string
The name of a container group definition resource that describes a set of axillary software. A fleet instance has one process for executables in this container group. A per-instance container group is optional. You can update the fleet to add or remove a per-instance container group at any time. You can specify the container group definition's name to use the latest version. Alternatively, provide an ARN value with a specific version number.
Create a container group definition by calling CreateContainerGroupDefinition. This operation creates a ContainerGroupDefinition resource.
dict
The set of port numbers to open on each fleet instance. A fleet's connection ports map to container ports that are configured in the fleet's container group definitions.
By default, Amazon GameLift calculates an optimal port range based on your fleet configuration. To use the calculated range, don't set this parameter. The values are:
Port range: 4192 to a number calculated based on your fleet configuration. Amazon GameLift uses the following formula: 4192 + [# of game server container groups per fleet instance] * [# of container ports in the game server container group definition] + [# of container ports in the game server container group definition]
You can also choose to manually set this parameter. When manually setting this parameter, you must use port numbers that match the fleet's inbound permissions port range.
FromPort (integer) -- [REQUIRED]
Starting value for the port range.
ToPort (integer) -- [REQUIRED]
Ending value for the port. Port numbers are end-inclusive. This value must be equal to or greater than FromPort.
list
The IP address ranges and port settings that allow inbound traffic to access game server processes and other processes on this fleet. As a best practice, when remotely accessing a fleet instance, we recommend opening ports only when you need them and closing them when you're finished.
By default, Amazon GameLift calculates an optimal port range based on your fleet configuration. To use the calculated range, don't set this parameter. The values are:
Protocol: UDP
Port range: 4192 to a number calculated based on your fleet configuration. Amazon GameLift uses the following formula: 4192 + [# of game server container groups per fleet instance] * [# of container ports in the game server container group definition] + [# of container ports in the game server container group definition]
You can also choose to manually set this parameter. When manually setting this parameter, you must use port numbers that match the fleet's connection port range.
(dict) --
A range of IP addresses and port settings that allow inbound traffic to connect to processes on an instance in a fleet. Processes are assigned an IP address/port number combination, which must fall into the fleet's allowed ranges. For managed container fleets, the port settings must use the same port numbers as the fleet's connection ports.
For Realtime Servers fleets, Amazon GameLift automatically opens two port ranges, one for TCP messaging and one for UDP.
FromPort (integer) -- [REQUIRED]
A starting value for a range of allowed port numbers.
For fleets using Linux builds, only ports 22 and 1026-60000 are valid.
For fleets using Windows builds, only ports 1026-60000 are valid.
ToPort (integer) -- [REQUIRED]
An ending value for a range of allowed port numbers. Port numbers are end-inclusive. This value must be equal to or greater than FromPort.
For fleets using Linux builds, only ports 22 and 1026-60000 are valid.
For fleets using Windows builds, only ports 1026-60000 are valid.
IpRange (string) -- [REQUIRED]
A range of allowed IP addresses. This value must be expressed in CIDR notation. Example: " 000.000.000.000/[subnet mask]" or optionally the shortened version " 0.0.0.0/[subnet mask]".
Protocol (string) -- [REQUIRED]
The network communication protocol used by the fleet.
integer
The number of times to replicate the game server container group on each fleet instance.
By default, Amazon GameLift calculates the maximum number of game server container groups that can fit on each instance. This calculation is based on the CPU and memory resources of the fleet's instance type). To use the calculated maximum, don't set this parameter. If you set this number manually, Amazon GameLift uses your value as long as it's less than the calculated maximum.
string
The Amazon EC2 instance type to use for all instances in the fleet. For multi-location fleets, the instance type must be available in the home region and all remote locations. Instance type determines the computing resources and processing power that's available to host your game servers. This includes including CPU, memory, storage, and networking capacity.
By default, Amazon GameLift selects an instance type that fits the needs of your container groups and is available in all selected fleet locations. You can also choose to manually set this parameter. See Amazon Elastic Compute Cloud Instance Types for detailed descriptions of Amazon EC2 instance types.
You can't update this fleet property later.
string
Indicates whether to use On-Demand or Spot instances for this fleet. Learn more about when to use On-Demand versus Spot Instances. This fleet property can't be changed after the fleet is created.
By default, this property is set to ON_DEMAND.
You can't update this fleet property later.
list
A set of locations to deploy container fleet instances to. You can add any Amazon Web Services Region or Local Zone that's supported by Amazon GameLift. Provide a list of one or more Amazon Web Services Region codes, such as us-west-2, or Local Zone names. Also include the fleet's home Region, which is the Amazon Web Services Region where the fleet is created. For a list of supported Regions and Local Zones, see Amazon GameLift service locations for managed hosting.
(dict) --
A remote location where a multi-location fleet can deploy game servers for game hosting.
Location (string) -- [REQUIRED]
An Amazon Web Services Region code, such as us-west-2. For a list of supported Regions and Local Zones, see Amazon GameLift service locations for managed hosting.
list
The name of an Amazon Web Services CloudWatch metric group to add this fleet to. You can use a metric group to aggregate metrics for multiple fleets. You can specify an existing metric group name or use a new name to create a new metric group. Each fleet can have only one metric group, but you can change this value at any time.
(string) --
string
Determines whether Amazon GameLift can shut down game sessions on the fleet that are actively running and hosting players. Amazon GameLift might prompt an instance shutdown when scaling down fleet capacity or when retiring unhealthy instances. You can also set game session protection for individual game sessions using UpdateGameSession.
NoProtection -- Game sessions can be shut down during active gameplay.
FullProtection -- Game sessions in ACTIVE status can't be shut down.
By default, this property is set to NoProtection.
dict
A policy that limits the number of game sessions that each individual player can create on instances in this fleet. The limit applies for a specified span of time.
NewGameSessionsPerCreator (integer) --
A policy that puts limits on the number of game sessions that a player can create within a specified span of time. With this policy, you can control players' ability to consume available resources.
The policy evaluates when a player tries to create a new game session. On receiving a CreateGameSession request, Amazon GameLift checks that the player (identified by CreatorId) has created fewer than game session limit in the specified time period.
PolicyPeriodInMinutes (integer) --
The time span used in evaluating the resource creation limit policy.
dict
A method for collecting container logs for the fleet. Amazon GameLift saves all standard output for each container in logs, including game session logs. You can select from the following methods:
CLOUDWATCH -- Send logs to an Amazon CloudWatch log group that you define. Each container emits a log stream, which is organized in the log group.
S3 -- Store logs in an Amazon S3 bucket that you define.
NONE -- Don't collect container logs.
By default, this property is set to CLOUDWATCH.
Amazon GameLift requires permissions to send logs other Amazon Web Services services in your account. These permissions are included in the IAM fleet role for this container fleet (see FleetRoleArn).
LogDestination (string) --
The type of log collection to use for a fleet.
CLOUDWATCH -- (default value) Send logs to an Amazon CloudWatch log group that you define. Each container emits a log stream, which is organized in the log group.
S3 -- Store logs in an Amazon S3 bucket that you define.
NONE -- Don't collect container logs.
S3BucketName (string) --
If log destination is S3, logs are sent to the specified Amazon S3 bucket name.
LogGroupArn (string) --
If log destination is CLOUDWATCH, logs are sent to the specified log group in Amazon CloudWatch.
list
A list of labels to assign to the new fleet resource. Tags are developer-defined key-value pairs. Tagging Amazon Web Services resources are useful for resource management, access management and cost allocation. For more information, see Tagging Amazon Web Services Resources in the Amazon Web Services General Reference.
(dict) --
A label that you can assign to a Amazon GameLift resource.
Learn more
Tagging Amazon Web Services Resources in the Amazon Web Services General Reference
Amazon Web Services Tagging Strategies
Related actions
Key (string) -- [REQUIRED]
The key for a developer-defined key value pair for tagging an Amazon Web Services resource.
Value (string) -- [REQUIRED]
The value for a developer-defined key value pair for tagging an Amazon Web Services resource.
dict
Response Syntax
{ 'ContainerFleet': { 'FleetId': 'string', 'FleetArn': 'string', 'FleetRoleArn': 'string', 'GameServerContainerGroupDefinitionName': 'string', 'GameServerContainerGroupDefinitionArn': 'string', 'PerInstanceContainerGroupDefinitionName': 'string', 'PerInstanceContainerGroupDefinitionArn': 'string', 'InstanceConnectionPortRange': { 'FromPort': 123, 'ToPort': 123 }, 'InstanceInboundPermissions': [ { 'FromPort': 123, 'ToPort': 123, 'IpRange': 'string', 'Protocol': 'TCP'|'UDP' }, ], 'GameServerContainerGroupsPerInstance': 123, 'MaximumGameServerContainerGroupsPerInstance': 123, 'InstanceType': 'string', 'BillingType': 'ON_DEMAND'|'SPOT', 'Description': 'string', 'CreationTime': datetime(2015, 1, 1), 'MetricGroups': [ 'string', ], 'NewGameSessionProtectionPolicy': 'NoProtection'|'FullProtection', 'GameSessionCreationLimitPolicy': { 'NewGameSessionsPerCreator': 123, 'PolicyPeriodInMinutes': 123 }, 'Status': 'PENDING'|'CREATING'|'CREATED'|'ACTIVATING'|'ACTIVE'|'UPDATING'|'DELETING', 'DeploymentDetails': { 'LatestDeploymentId': 'string' }, 'LogConfiguration': { 'LogDestination': 'NONE'|'CLOUDWATCH'|'S3', 'S3BucketName': 'string', 'LogGroupArn': 'string' }, 'LocationAttributes': [ { 'Location': 'string', 'Status': 'PENDING'|'CREATING'|'CREATED'|'ACTIVATING'|'ACTIVE'|'UPDATING'|'DELETING' }, ] } }
Response Structure
(dict) --
ContainerFleet (dict) --
The properties for the new container fleet, including current status. All fleets are initially placed in PENDING status.
FleetId (string) --
A unique identifier for the container fleet to retrieve.
FleetArn (string) --
The Amazon Resource Name ( ARN) that is assigned to a Amazon GameLift fleet resource and uniquely identifies it. ARNs are unique across all Regions. Format is arn:aws:gamelift:<region>::fleet/fleet-a1234567-b8c9-0d1e-2fa3-b45c6d7e8912. In a GameLift fleet ARN, the resource ID matches the FleetId value.
FleetRoleArn (string) --
The unique identifier for an Identity and Access Management (IAM) role with permissions to run your containers on resources that are managed by Amazon GameLift. See Set up an IAM service role. This fleet property can't be changed.
GameServerContainerGroupDefinitionName (string) --
The name of the fleet's game server container group definition, which describes how to deploy containers with your game server build and support software onto each fleet instance.
GameServerContainerGroupDefinitionArn (string) --
The Amazon Resource Name ( ARN) that is assigned to the fleet's game server container group. The ARN value also identifies the specific container group definition version in use.
PerInstanceContainerGroupDefinitionName (string) --
The name of the fleet's per-instance container group definition.
PerInstanceContainerGroupDefinitionArn (string) --
The Amazon Resource Name ( ARN) that is assigned to the fleet's per-instance container group. The ARN value also identifies the specific container group definition version in use.
InstanceConnectionPortRange (dict) --
The set of port numbers to open on each instance in a container fleet. Connection ports are used by inbound traffic to connect with processes that are running in containers on the fleet.
FromPort (integer) --
Starting value for the port range.
ToPort (integer) --
Ending value for the port. Port numbers are end-inclusive. This value must be equal to or greater than FromPort.
InstanceInboundPermissions (list) --
The IP address ranges and port settings that allow inbound traffic to access game server processes and other processes on this fleet.
(dict) --
A range of IP addresses and port settings that allow inbound traffic to connect to processes on an instance in a fleet. Processes are assigned an IP address/port number combination, which must fall into the fleet's allowed ranges. For managed container fleets, the port settings must use the same port numbers as the fleet's connection ports.
For Realtime Servers fleets, Amazon GameLift automatically opens two port ranges, one for TCP messaging and one for UDP.
FromPort (integer) --
A starting value for a range of allowed port numbers.
For fleets using Linux builds, only ports 22 and 1026-60000 are valid.
For fleets using Windows builds, only ports 1026-60000 are valid.
ToPort (integer) --
An ending value for a range of allowed port numbers. Port numbers are end-inclusive. This value must be equal to or greater than FromPort.
For fleets using Linux builds, only ports 22 and 1026-60000 are valid.
For fleets using Windows builds, only ports 1026-60000 are valid.
IpRange (string) --
A range of allowed IP addresses. This value must be expressed in CIDR notation. Example: " 000.000.000.000/[subnet mask]" or optionally the shortened version " 0.0.0.0/[subnet mask]".
Protocol (string) --
The network communication protocol used by the fleet.
GameServerContainerGroupsPerInstance (integer) --
The number of times to replicate the game server container group on each fleet instance.
MaximumGameServerContainerGroupsPerInstance (integer) --
The calculated maximum number of game server container group that can be deployed on each fleet instance. The calculation depends on the resource needs of the container group and the CPU and memory resources of the fleet's instance type.
InstanceType (string) --
The Amazon EC2 instance type to use for all instances in the fleet. Instance type determines the computing resources and processing power that's available to host your game servers. This includes including CPU, memory, storage, and networking capacity. You can't update this fleet property.
BillingType (string) --
Indicates whether the fleet uses On-Demand or Spot instances for this fleet. Learn more about when to use On-Demand versus Spot Instances. You can't update this fleet property.
By default, this property is set to ON_DEMAND.
Description (string) --
A meaningful description of the container fleet.
CreationTime (datetime) --
A time stamp indicating when this data object was created. Format is a number expressed in Unix time as milliseconds (for example "1469498468.057").
MetricGroups (list) --
The name of an Amazon Web Services CloudWatch metric group to add this fleet to. Metric groups aggregate metrics for multiple fleets.
(string) --
NewGameSessionProtectionPolicy (string) --
Determines whether Amazon GameLift can shut down game sessions on the fleet that are actively running and hosting players. Amazon GameLift might prompt an instance shutdown when scaling down fleet capacity or when retiring unhealthy instances. You can also set game session protection for individual game sessions using UpdateGameSession.
NoProtection -- Game sessions can be shut down during active gameplay.
FullProtection -- Game sessions in ACTIVE status can't be shut down.
GameSessionCreationLimitPolicy (dict) --
A policy that limits the number of game sessions that each individual player can create on instances in this fleet. The limit applies for a specified span of time.
NewGameSessionsPerCreator (integer) --
A policy that puts limits on the number of game sessions that a player can create within a specified span of time. With this policy, you can control players' ability to consume available resources.
The policy evaluates when a player tries to create a new game session. On receiving a CreateGameSession request, Amazon GameLift checks that the player (identified by CreatorId) has created fewer than game session limit in the specified time period.
PolicyPeriodInMinutes (integer) --
The time span used in evaluating the resource creation limit policy.
Status (string) --
The current status of the container fleet.
PENDING -- A new container fleet has been requested.
CREATING -- A new container fleet resource is being created.
CREATED -- A new container fleet resource has been created. No fleet instances have been deployed.
ACTIVATING -- New container fleet instances are being deployed.
ACTIVE -- The container fleet has been deployed and is ready to host game sessions.
UPDATING -- Updates to the container fleet is being updated. A deployment is in progress.
DeploymentDetails (dict) --
Information about the most recent deployment for the container fleet.
LatestDeploymentId (string) --
A unique identifier for a fleet deployment.
LogConfiguration (dict) --
The method that is used to collect container logs for the fleet. Amazon GameLift saves all standard output for each container in logs, including game session logs.
CLOUDWATCH -- Send logs to an Amazon CloudWatch log group that you define. Each container emits a log stream, which is organized in the log group.
S3 -- Store logs in an Amazon S3 bucket that you define.
NONE -- Don't collect container logs.
LogDestination (string) --
The type of log collection to use for a fleet.
CLOUDWATCH -- (default value) Send logs to an Amazon CloudWatch log group that you define. Each container emits a log stream, which is organized in the log group.
S3 -- Store logs in an Amazon S3 bucket that you define.
NONE -- Don't collect container logs.
S3BucketName (string) --
If log destination is S3, logs are sent to the specified Amazon S3 bucket name.
LogGroupArn (string) --
If log destination is CLOUDWATCH, logs are sent to the specified log group in Amazon CloudWatch.
LocationAttributes (list) --
Information about the container fleet's remote locations where fleet instances are deployed.
(dict) --
Details about a location in a multi-location container fleet.
Location (string) --
A location identifier.
Status (string) --
The status of fleet activity in the location.
PENDING -- A new container fleet has been requested.
CREATING -- A new container fleet resource is being created.
CREATED -- A new container fleet resource has been created. No fleet instances have been deployed.
ACTIVATING -- New container fleet instances are being deployed.
ACTIVE -- The container fleet has been deployed and is ready to host game sessions.
UPDATING -- Updates to the container fleet is being updated. A deployment is in progress.
Retrieves a collection of container fleet resources in an Amazon Web Services Region. For fleets that have multiple locations, this operation retrieves fleets based on their home Region only.
Request options
Get a list of all fleets. Call this operation without specifying a container group definition.
Get a list of fleets filtered by container group definition. Provide the container group definition name or ARN value.
To get a list of all Realtime Servers fleets with a specific configuration script, provide the script ID.
Use the pagination parameters to retrieve results as a set of sequential pages.
If successful, this operation returns a collection of container fleets that match the request parameters. A NextToken value is also returned if there are more result pages to retrieve.
See also: AWS API Documentation
Request Syntax
client.list_container_fleets( ContainerGroupDefinitionName='string', Limit=123, NextToken='string' )
string
The container group definition to filter the list on. Use this parameter to retrieve only those fleets that use the specified container group definition. You can specify the container group definition's name to get fleets with the latest versions. Alternatively, provide an ARN value to get fleets with a specific version number.
integer
The maximum number of results to return. Use this parameter with NextToken to get results as a set of sequential pages.
string
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.
dict
Response Syntax
{ 'ContainerFleets': [ { 'FleetId': 'string', 'FleetArn': 'string', 'FleetRoleArn': 'string', 'GameServerContainerGroupDefinitionName': 'string', 'GameServerContainerGroupDefinitionArn': 'string', 'PerInstanceContainerGroupDefinitionName': 'string', 'PerInstanceContainerGroupDefinitionArn': 'string', 'InstanceConnectionPortRange': { 'FromPort': 123, 'ToPort': 123 }, 'InstanceInboundPermissions': [ { 'FromPort': 123, 'ToPort': 123, 'IpRange': 'string', 'Protocol': 'TCP'|'UDP' }, ], 'GameServerContainerGroupsPerInstance': 123, 'MaximumGameServerContainerGroupsPerInstance': 123, 'InstanceType': 'string', 'BillingType': 'ON_DEMAND'|'SPOT', 'Description': 'string', 'CreationTime': datetime(2015, 1, 1), 'MetricGroups': [ 'string', ], 'NewGameSessionProtectionPolicy': 'NoProtection'|'FullProtection', 'GameSessionCreationLimitPolicy': { 'NewGameSessionsPerCreator': 123, 'PolicyPeriodInMinutes': 123 }, 'Status': 'PENDING'|'CREATING'|'CREATED'|'ACTIVATING'|'ACTIVE'|'UPDATING'|'DELETING', 'DeploymentDetails': { 'LatestDeploymentId': 'string' }, 'LogConfiguration': { 'LogDestination': 'NONE'|'CLOUDWATCH'|'S3', 'S3BucketName': 'string', 'LogGroupArn': 'string' }, 'LocationAttributes': [ { 'Location': 'string', 'Status': 'PENDING'|'CREATING'|'CREATED'|'ACTIVATING'|'ACTIVE'|'UPDATING'|'DELETING' }, ] }, ], 'NextToken': 'string' }
Response Structure
(dict) --
ContainerFleets (list) --
A collection of container fleet objects for all fleets that match the request criteria.
(dict) --
Describes an Amazon GameLift managed container fleet.
FleetId (string) --
A unique identifier for the container fleet to retrieve.
FleetArn (string) --
The Amazon Resource Name ( ARN) that is assigned to a Amazon GameLift fleet resource and uniquely identifies it. ARNs are unique across all Regions. Format is arn:aws:gamelift:<region>::fleet/fleet-a1234567-b8c9-0d1e-2fa3-b45c6d7e8912. In a GameLift fleet ARN, the resource ID matches the FleetId value.
FleetRoleArn (string) --
The unique identifier for an Identity and Access Management (IAM) role with permissions to run your containers on resources that are managed by Amazon GameLift. See Set up an IAM service role. This fleet property can't be changed.
GameServerContainerGroupDefinitionName (string) --
The name of the fleet's game server container group definition, which describes how to deploy containers with your game server build and support software onto each fleet instance.
GameServerContainerGroupDefinitionArn (string) --
The Amazon Resource Name ( ARN) that is assigned to the fleet's game server container group. The ARN value also identifies the specific container group definition version in use.
PerInstanceContainerGroupDefinitionName (string) --
The name of the fleet's per-instance container group definition.
PerInstanceContainerGroupDefinitionArn (string) --
The Amazon Resource Name ( ARN) that is assigned to the fleet's per-instance container group. The ARN value also identifies the specific container group definition version in use.
InstanceConnectionPortRange (dict) --
The set of port numbers to open on each instance in a container fleet. Connection ports are used by inbound traffic to connect with processes that are running in containers on the fleet.
FromPort (integer) --
Starting value for the port range.
ToPort (integer) --
Ending value for the port. Port numbers are end-inclusive. This value must be equal to or greater than FromPort.
InstanceInboundPermissions (list) --
The IP address ranges and port settings that allow inbound traffic to access game server processes and other processes on this fleet.
(dict) --
A range of IP addresses and port settings that allow inbound traffic to connect to processes on an instance in a fleet. Processes are assigned an IP address/port number combination, which must fall into the fleet's allowed ranges. For managed container fleets, the port settings must use the same port numbers as the fleet's connection ports.
For Realtime Servers fleets, Amazon GameLift automatically opens two port ranges, one for TCP messaging and one for UDP.
FromPort (integer) --
A starting value for a range of allowed port numbers.
For fleets using Linux builds, only ports 22 and 1026-60000 are valid.
For fleets using Windows builds, only ports 1026-60000 are valid.
ToPort (integer) --
An ending value for a range of allowed port numbers. Port numbers are end-inclusive. This value must be equal to or greater than FromPort.
For fleets using Linux builds, only ports 22 and 1026-60000 are valid.
For fleets using Windows builds, only ports 1026-60000 are valid.
IpRange (string) --
A range of allowed IP addresses. This value must be expressed in CIDR notation. Example: " 000.000.000.000/[subnet mask]" or optionally the shortened version " 0.0.0.0/[subnet mask]".
Protocol (string) --
The network communication protocol used by the fleet.
GameServerContainerGroupsPerInstance (integer) --
The number of times to replicate the game server container group on each fleet instance.
MaximumGameServerContainerGroupsPerInstance (integer) --
The calculated maximum number of game server container group that can be deployed on each fleet instance. The calculation depends on the resource needs of the container group and the CPU and memory resources of the fleet's instance type.
InstanceType (string) --
The Amazon EC2 instance type to use for all instances in the fleet. Instance type determines the computing resources and processing power that's available to host your game servers. This includes including CPU, memory, storage, and networking capacity. You can't update this fleet property.
BillingType (string) --
Indicates whether the fleet uses On-Demand or Spot instances for this fleet. Learn more about when to use On-Demand versus Spot Instances. You can't update this fleet property.
By default, this property is set to ON_DEMAND.
Description (string) --
A meaningful description of the container fleet.
CreationTime (datetime) --
A time stamp indicating when this data object was created. Format is a number expressed in Unix time as milliseconds (for example "1469498468.057").
MetricGroups (list) --
The name of an Amazon Web Services CloudWatch metric group to add this fleet to. Metric groups aggregate metrics for multiple fleets.
(string) --
NewGameSessionProtectionPolicy (string) --
Determines whether Amazon GameLift can shut down game sessions on the fleet that are actively running and hosting players. Amazon GameLift might prompt an instance shutdown when scaling down fleet capacity or when retiring unhealthy instances. You can also set game session protection for individual game sessions using UpdateGameSession.
NoProtection -- Game sessions can be shut down during active gameplay.
FullProtection -- Game sessions in ACTIVE status can't be shut down.
GameSessionCreationLimitPolicy (dict) --
A policy that limits the number of game sessions that each individual player can create on instances in this fleet. The limit applies for a specified span of time.
NewGameSessionsPerCreator (integer) --
A policy that puts limits on the number of game sessions that a player can create within a specified span of time. With this policy, you can control players' ability to consume available resources.
The policy evaluates when a player tries to create a new game session. On receiving a CreateGameSession request, Amazon GameLift checks that the player (identified by CreatorId) has created fewer than game session limit in the specified time period.
PolicyPeriodInMinutes (integer) --
The time span used in evaluating the resource creation limit policy.
Status (string) --
The current status of the container fleet.
PENDING -- A new container fleet has been requested.
CREATING -- A new container fleet resource is being created.
CREATED -- A new container fleet resource has been created. No fleet instances have been deployed.
ACTIVATING -- New container fleet instances are being deployed.
ACTIVE -- The container fleet has been deployed and is ready to host game sessions.
UPDATING -- Updates to the container fleet is being updated. A deployment is in progress.
DeploymentDetails (dict) --
Information about the most recent deployment for the container fleet.
LatestDeploymentId (string) --
A unique identifier for a fleet deployment.
LogConfiguration (dict) --
The method that is used to collect container logs for the fleet. Amazon GameLift saves all standard output for each container in logs, including game session logs.
CLOUDWATCH -- Send logs to an Amazon CloudWatch log group that you define. Each container emits a log stream, which is organized in the log group.
S3 -- Store logs in an Amazon S3 bucket that you define.
NONE -- Don't collect container logs.
LogDestination (string) --
The type of log collection to use for a fleet.
CLOUDWATCH -- (default value) Send logs to an Amazon CloudWatch log group that you define. Each container emits a log stream, which is organized in the log group.
S3 -- Store logs in an Amazon S3 bucket that you define.
NONE -- Don't collect container logs.
S3BucketName (string) --
If log destination is S3, logs are sent to the specified Amazon S3 bucket name.
LogGroupArn (string) --
If log destination is CLOUDWATCH, logs are sent to the specified log group in Amazon CloudWatch.
LocationAttributes (list) --
Information about the container fleet's remote locations where fleet instances are deployed.
(dict) --
Details about a location in a multi-location container fleet.
Location (string) --
A location identifier.
Status (string) --
The status of fleet activity in the location.
PENDING -- A new container fleet has been requested.
CREATING -- A new container fleet resource is being created.
CREATED -- A new container fleet resource has been created. No fleet instances have been deployed.
ACTIVATING -- New container fleet instances are being deployed.
ACTIVE -- The container fleet has been deployed and is ready to host game sessions.
UPDATING -- Updates to the container fleet is being updated. A deployment is in progress.
NextToken (string) --
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.
Deletes all resources and information related to a container fleet and shuts down currently running fleet instances, including those in remote locations. The container fleet must be in ACTIVE status to be deleted.
To delete a fleet, specify the fleet ID to be terminated. During the deletion process, the fleet status is changed to DELETING.
Learn more
See also: AWS API Documentation
Request Syntax
client.delete_container_fleet( FleetId='string' )
string
[REQUIRED]
A unique identifier for the container fleet to delete. You can use either the fleet ID or ARN value.
dict
Response Syntax
{}
Response Structure
(dict) --
Retrieves the properties for a container fleet. When requesting attributes for multiple fleets, use the pagination parameters to retrieve results as a set of sequential pages.
Request options
Get container fleet properties for a single fleet. Provide either the fleet ID or ARN value.
Results
If successful, a ContainerFleet object is returned. This object includes the fleet properties, including information about the most recent deployment.
See also: AWS API Documentation
Request Syntax
client.describe_container_fleet( FleetId='string' )
string
[REQUIRED]
A unique identifier for the container fleet to retrieve. You can use either the fleet ID or ARN value.
dict
Response Syntax
{ 'ContainerFleet': { 'FleetId': 'string', 'FleetArn': 'string', 'FleetRoleArn': 'string', 'GameServerContainerGroupDefinitionName': 'string', 'GameServerContainerGroupDefinitionArn': 'string', 'PerInstanceContainerGroupDefinitionName': 'string', 'PerInstanceContainerGroupDefinitionArn': 'string', 'InstanceConnectionPortRange': { 'FromPort': 123, 'ToPort': 123 }, 'InstanceInboundPermissions': [ { 'FromPort': 123, 'ToPort': 123, 'IpRange': 'string', 'Protocol': 'TCP'|'UDP' }, ], 'GameServerContainerGroupsPerInstance': 123, 'MaximumGameServerContainerGroupsPerInstance': 123, 'InstanceType': 'string', 'BillingType': 'ON_DEMAND'|'SPOT', 'Description': 'string', 'CreationTime': datetime(2015, 1, 1), 'MetricGroups': [ 'string', ], 'NewGameSessionProtectionPolicy': 'NoProtection'|'FullProtection', 'GameSessionCreationLimitPolicy': { 'NewGameSessionsPerCreator': 123, 'PolicyPeriodInMinutes': 123 }, 'Status': 'PENDING'|'CREATING'|'CREATED'|'ACTIVATING'|'ACTIVE'|'UPDATING'|'DELETING', 'DeploymentDetails': { 'LatestDeploymentId': 'string' }, 'LogConfiguration': { 'LogDestination': 'NONE'|'CLOUDWATCH'|'S3', 'S3BucketName': 'string', 'LogGroupArn': 'string' }, 'LocationAttributes': [ { 'Location': 'string', 'Status': 'PENDING'|'CREATING'|'CREATED'|'ACTIVATING'|'ACTIVE'|'UPDATING'|'DELETING' }, ] } }
Response Structure
(dict) --
ContainerFleet (dict) --
The properties for the requested container fleet, including current status.
FleetId (string) --
A unique identifier for the container fleet to retrieve.
FleetArn (string) --
The Amazon Resource Name ( ARN) that is assigned to a Amazon GameLift fleet resource and uniquely identifies it. ARNs are unique across all Regions. Format is arn:aws:gamelift:<region>::fleet/fleet-a1234567-b8c9-0d1e-2fa3-b45c6d7e8912. In a GameLift fleet ARN, the resource ID matches the FleetId value.
FleetRoleArn (string) --
The unique identifier for an Identity and Access Management (IAM) role with permissions to run your containers on resources that are managed by Amazon GameLift. See Set up an IAM service role. This fleet property can't be changed.
GameServerContainerGroupDefinitionName (string) --
The name of the fleet's game server container group definition, which describes how to deploy containers with your game server build and support software onto each fleet instance.
GameServerContainerGroupDefinitionArn (string) --
The Amazon Resource Name ( ARN) that is assigned to the fleet's game server container group. The ARN value also identifies the specific container group definition version in use.
PerInstanceContainerGroupDefinitionName (string) --
The name of the fleet's per-instance container group definition.
PerInstanceContainerGroupDefinitionArn (string) --
The Amazon Resource Name ( ARN) that is assigned to the fleet's per-instance container group. The ARN value also identifies the specific container group definition version in use.
InstanceConnectionPortRange (dict) --
The set of port numbers to open on each instance in a container fleet. Connection ports are used by inbound traffic to connect with processes that are running in containers on the fleet.
FromPort (integer) --
Starting value for the port range.
ToPort (integer) --
Ending value for the port. Port numbers are end-inclusive. This value must be equal to or greater than FromPort.
InstanceInboundPermissions (list) --
The IP address ranges and port settings that allow inbound traffic to access game server processes and other processes on this fleet.
(dict) --
A range of IP addresses and port settings that allow inbound traffic to connect to processes on an instance in a fleet. Processes are assigned an IP address/port number combination, which must fall into the fleet's allowed ranges. For managed container fleets, the port settings must use the same port numbers as the fleet's connection ports.
For Realtime Servers fleets, Amazon GameLift automatically opens two port ranges, one for TCP messaging and one for UDP.
FromPort (integer) --
A starting value for a range of allowed port numbers.
For fleets using Linux builds, only ports 22 and 1026-60000 are valid.
For fleets using Windows builds, only ports 1026-60000 are valid.
ToPort (integer) --
An ending value for a range of allowed port numbers. Port numbers are end-inclusive. This value must be equal to or greater than FromPort.
For fleets using Linux builds, only ports 22 and 1026-60000 are valid.
For fleets using Windows builds, only ports 1026-60000 are valid.
IpRange (string) --
A range of allowed IP addresses. This value must be expressed in CIDR notation. Example: " 000.000.000.000/[subnet mask]" or optionally the shortened version " 0.0.0.0/[subnet mask]".
Protocol (string) --
The network communication protocol used by the fleet.
GameServerContainerGroupsPerInstance (integer) --
The number of times to replicate the game server container group on each fleet instance.
MaximumGameServerContainerGroupsPerInstance (integer) --
The calculated maximum number of game server container group that can be deployed on each fleet instance. The calculation depends on the resource needs of the container group and the CPU and memory resources of the fleet's instance type.
InstanceType (string) --
The Amazon EC2 instance type to use for all instances in the fleet. Instance type determines the computing resources and processing power that's available to host your game servers. This includes including CPU, memory, storage, and networking capacity. You can't update this fleet property.
BillingType (string) --
Indicates whether the fleet uses On-Demand or Spot instances for this fleet. Learn more about when to use On-Demand versus Spot Instances. You can't update this fleet property.
By default, this property is set to ON_DEMAND.
Description (string) --
A meaningful description of the container fleet.
CreationTime (datetime) --
A time stamp indicating when this data object was created. Format is a number expressed in Unix time as milliseconds (for example "1469498468.057").
MetricGroups (list) --
The name of an Amazon Web Services CloudWatch metric group to add this fleet to. Metric groups aggregate metrics for multiple fleets.
(string) --
NewGameSessionProtectionPolicy (string) --
Determines whether Amazon GameLift can shut down game sessions on the fleet that are actively running and hosting players. Amazon GameLift might prompt an instance shutdown when scaling down fleet capacity or when retiring unhealthy instances. You can also set game session protection for individual game sessions using UpdateGameSession.
NoProtection -- Game sessions can be shut down during active gameplay.
FullProtection -- Game sessions in ACTIVE status can't be shut down.
GameSessionCreationLimitPolicy (dict) --
A policy that limits the number of game sessions that each individual player can create on instances in this fleet. The limit applies for a specified span of time.
NewGameSessionsPerCreator (integer) --
A policy that puts limits on the number of game sessions that a player can create within a specified span of time. With this policy, you can control players' ability to consume available resources.
The policy evaluates when a player tries to create a new game session. On receiving a CreateGameSession request, Amazon GameLift checks that the player (identified by CreatorId) has created fewer than game session limit in the specified time period.
PolicyPeriodInMinutes (integer) --
The time span used in evaluating the resource creation limit policy.
Status (string) --
The current status of the container fleet.
PENDING -- A new container fleet has been requested.
CREATING -- A new container fleet resource is being created.
CREATED -- A new container fleet resource has been created. No fleet instances have been deployed.
ACTIVATING -- New container fleet instances are being deployed.
ACTIVE -- The container fleet has been deployed and is ready to host game sessions.
UPDATING -- Updates to the container fleet is being updated. A deployment is in progress.
DeploymentDetails (dict) --
Information about the most recent deployment for the container fleet.
LatestDeploymentId (string) --
A unique identifier for a fleet deployment.
LogConfiguration (dict) --
The method that is used to collect container logs for the fleet. Amazon GameLift saves all standard output for each container in logs, including game session logs.
CLOUDWATCH -- Send logs to an Amazon CloudWatch log group that you define. Each container emits a log stream, which is organized in the log group.
S3 -- Store logs in an Amazon S3 bucket that you define.
NONE -- Don't collect container logs.
LogDestination (string) --
The type of log collection to use for a fleet.
CLOUDWATCH -- (default value) Send logs to an Amazon CloudWatch log group that you define. Each container emits a log stream, which is organized in the log group.
S3 -- Store logs in an Amazon S3 bucket that you define.
NONE -- Don't collect container logs.
S3BucketName (string) --
If log destination is S3, logs are sent to the specified Amazon S3 bucket name.
LogGroupArn (string) --
If log destination is CLOUDWATCH, logs are sent to the specified log group in Amazon CloudWatch.
LocationAttributes (list) --
Information about the container fleet's remote locations where fleet instances are deployed.
(dict) --
Details about a location in a multi-location container fleet.
Location (string) --
A location identifier.
Status (string) --
The status of fleet activity in the location.
PENDING -- A new container fleet has been requested.
CREATING -- A new container fleet resource is being created.
CREATED -- A new container fleet resource has been created. No fleet instances have been deployed.
ACTIVATING -- New container fleet instances are being deployed.
ACTIVE -- The container fleet has been deployed and is ready to host game sessions.
UPDATING -- Updates to the container fleet is being updated. A deployment is in progress.
Retrieves information about a managed container fleet deployment.
Request options
Get information about the latest deployment for a specific fleet. Provide the fleet ID or ARN.
Get information about a specific deployment. Provide the fleet ID or ARN and the deployment ID.
Results
If successful, a FleetDeployment object is returned.
See also: AWS API Documentation
Request Syntax
client.describe_fleet_deployment( FleetId='string', DeploymentId='string' )
string
[REQUIRED]
A unique identifier for the container fleet. You can use either the fleet ID or ARN value.
string
A unique identifier for the deployment to return information for.
dict
Response Syntax
{ 'FleetDeployment': { 'DeploymentId': 'string', 'FleetId': 'string', 'GameServerBinaryArn': 'string', 'RollbackGameServerBinaryArn': 'string', 'PerInstanceBinaryArn': 'string', 'RollbackPerInstanceBinaryArn': 'string', 'DeploymentStatus': 'IN_PROGRESS'|'IMPAIRED'|'COMPLETE'|'ROLLBACK_IN_PROGRESS'|'ROLLBACK_COMPLETE'|'CANCELLED'|'PENDING', 'DeploymentConfiguration': { 'ProtectionStrategy': 'WITH_PROTECTION'|'IGNORE_PROTECTION', 'MinimumHealthyPercentage': 123, 'ImpairmentStrategy': 'MAINTAIN'|'ROLLBACK' }, 'CreationTime': datetime(2015, 1, 1) }, 'LocationalDeployments': { 'string': { 'DeploymentStatus': 'IN_PROGRESS'|'IMPAIRED'|'COMPLETE'|'ROLLBACK_IN_PROGRESS'|'ROLLBACK_COMPLETE'|'CANCELLED'|'PENDING' } } }
Response Structure
(dict) --
FleetDeployment (dict) --
The requested deployment information.
DeploymentId (string) --
A unique identifier for the deployment.
FleetId (string) --
A unique identifier for the container fleet.
GameServerBinaryArn (string) --
The unique identifier for the version of the game server container group definition that is being deployed.
RollbackGameServerBinaryArn (string) --
The unique identifier for the version of the game server container group definition to roll back to if deployment fails.
PerInstanceBinaryArn (string) --
The unique identifier for the version of the per-instance container group definition that is being deployed.
RollbackPerInstanceBinaryArn (string) --
The unique identifier for the version of the per-instance container group definition to roll back to if deployment fails.
DeploymentStatus (string) --
The status of fleet deployment activity in the location.
IN_PROGRESS -- The deployment is in progress.
IMPAIRED -- The deployment failed and the fleet has some impaired containers.
COMPLETE -- The deployment has completed successfully.
ROLLBACK_IN_PROGRESS -- The deployment failed and rollback has been initiated.
ROLLBACK_IN_COMPLETE -- The deployment failed and rollback has been completed.
CANCELLED -- The deployment was cancelled.
DeploymentConfiguration (dict) --
Instructions for how to deploy updates to a container fleet and what actions to take if the deployment fails.
ProtectionStrategy (string) --
Determines how fleet deployment activity affects active game sessions on the fleet. With protection, a deployment honors game session protection, and delays actions that would interrupt a protected active game session until the game session ends. Without protection, deployment activity can shut down all running tasks, including active game sessions, regardless of game session protection.
MinimumHealthyPercentage (integer) --
Sets a minimum level of healthy tasks to maintain during deployment activity.
ImpairmentStrategy (string) --
Determines what actions to take if a deployment fails. If the fleet is multi-location, this strategy applies across all fleet locations. With a rollback strategy, updated fleet instances are rolled back to the last successful deployment. Alternatively, you can maintain a few impaired containers for the purpose of debugging, while all other tasks return to the last successful deployment.
CreationTime (datetime) --
A time stamp indicating when this data object was created. Format is a number expressed in Unix time as milliseconds (for example "1469498468.057").
LocationalDeployments (dict) --
If the deployment is for a multi-location fleet, the requests returns the deployment status in each fleet location.
(string) --
(dict) --
For a multi-location container fleet, describes the progress of a deployment across all fleet locations.
DeploymentStatus (string) --
The status of fleet deployment activity in the location.
IN_PROGRESS -- The deployment is in progress.
IMPAIRED -- The deployment failed and the fleet has some impaired containers.
COMPLETE -- The deployment has completed successfully.
ROLLBACK_IN_PROGRESS -- The deployment failed and rollback has been initiated.
ROLLBACK_IN_COMPLETE -- The deployment failed and rollback has been completed.
CANCELLED -- The deployment was cancelled.
Retrieves a collection of container fleet deployments in an Amazon Web Services Region.
Request options
Get a list of all deployments. Call this operation without specifying a fleet ID.
Get a list of all deployments for a fleet. Specify the container fleet ID or ARN value.
To get a list of all Realtime Servers fleets with a specific configuration script, provide the script ID.
Use the pagination parameters to retrieve results as a set of sequential pages.
Results
If successful, this operation returns a list of deployments that match the request parameters. A NextToken value is also returned if there are more result pages to retrieve.
See also: AWS API Documentation
Request Syntax
client.list_fleet_deployments( FleetId='string', Limit=123, NextToken='string' )
string
A unique identifier for the container fleet. You can use either the fleet ID or ARN value.
integer
The maximum number of results to return. Use this parameter with NextToken to get results as a set of sequential pages.
string
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.
dict
Response Syntax
{ 'FleetDeployments': [ { 'DeploymentId': 'string', 'FleetId': 'string', 'GameServerBinaryArn': 'string', 'RollbackGameServerBinaryArn': 'string', 'PerInstanceBinaryArn': 'string', 'RollbackPerInstanceBinaryArn': 'string', 'DeploymentStatus': 'IN_PROGRESS'|'IMPAIRED'|'COMPLETE'|'ROLLBACK_IN_PROGRESS'|'ROLLBACK_COMPLETE'|'CANCELLED'|'PENDING', 'DeploymentConfiguration': { 'ProtectionStrategy': 'WITH_PROTECTION'|'IGNORE_PROTECTION', 'MinimumHealthyPercentage': 123, 'ImpairmentStrategy': 'MAINTAIN'|'ROLLBACK' }, 'CreationTime': datetime(2015, 1, 1) }, ], 'NextToken': 'string' }
Response Structure
(dict) --
FleetDeployments (list) --
The requested deployment information.
(dict) --
Describes a container fleet deployment with updates to the fleet.
DeploymentId (string) --
A unique identifier for the deployment.
FleetId (string) --
A unique identifier for the container fleet.
GameServerBinaryArn (string) --
The unique identifier for the version of the game server container group definition that is being deployed.
RollbackGameServerBinaryArn (string) --
The unique identifier for the version of the game server container group definition to roll back to if deployment fails.
PerInstanceBinaryArn (string) --
The unique identifier for the version of the per-instance container group definition that is being deployed.
RollbackPerInstanceBinaryArn (string) --
The unique identifier for the version of the per-instance container group definition to roll back to if deployment fails.
DeploymentStatus (string) --
The status of fleet deployment activity in the location.
IN_PROGRESS -- The deployment is in progress.
IMPAIRED -- The deployment failed and the fleet has some impaired containers.
COMPLETE -- The deployment has completed successfully.
ROLLBACK_IN_PROGRESS -- The deployment failed and rollback has been initiated.
ROLLBACK_IN_COMPLETE -- The deployment failed and rollback has been completed.
CANCELLED -- The deployment was cancelled.
DeploymentConfiguration (dict) --
Instructions for how to deploy updates to a container fleet and what actions to take if the deployment fails.
ProtectionStrategy (string) --
Determines how fleet deployment activity affects active game sessions on the fleet. With protection, a deployment honors game session protection, and delays actions that would interrupt a protected active game session until the game session ends. Without protection, deployment activity can shut down all running tasks, including active game sessions, regardless of game session protection.
MinimumHealthyPercentage (integer) --
Sets a minimum level of healthy tasks to maintain during deployment activity.
ImpairmentStrategy (string) --
Determines what actions to take if a deployment fails. If the fleet is multi-location, this strategy applies across all fleet locations. With a rollback strategy, updated fleet instances are rolled back to the last successful deployment. Alternatively, you can maintain a few impaired containers for the purpose of debugging, while all other tasks return to the last successful deployment.
CreationTime (datetime) --
A time stamp indicating when this data object was created. Format is a number expressed in Unix time as milliseconds (for example "1469498468.057").
NextToken (string) --
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.
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.
Learn more
See also: AWS API Documentation
Request Syntax
client.list_container_group_definition_versions( Name='string', Limit=123, NextToken='string' )
string
[REQUIRED]
The unique identifier for the container group definition to retrieve properties for. You can use either the Name or ARN value.
integer
The maximum number of results to return. Use this parameter with NextToken to get results as a set of sequential pages.
string
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.
dict
Response Syntax
{ 'ContainerGroupDefinitions': [ { 'ContainerGroupDefinitionArn': 'string', 'CreationTime': datetime(2015, 1, 1), 'OperatingSystem': 'AMAZON_LINUX_2023', 'Name': 'string', 'ContainerGroupType': 'GAME_SERVER'|'PER_INSTANCE', 'TotalMemoryLimitMebibytes': 123, 'TotalVcpuLimit': 123.0, 'GameServerContainerDefinition': { 'ContainerName': 'string', 'DependsOn': [ { 'ContainerName': 'string', 'Condition': 'START'|'COMPLETE'|'SUCCESS'|'HEALTHY' }, ], 'MountPoints': [ { 'InstancePath': 'string', 'ContainerPath': 'string', 'AccessLevel': 'READ_ONLY'|'READ_AND_WRITE' }, ], 'EnvironmentOverride': [ { 'Name': 'string', 'Value': 'string' }, ], 'ImageUri': 'string', 'PortConfiguration': { 'ContainerPortRanges': [ { 'FromPort': 123, 'ToPort': 123, 'Protocol': 'TCP'|'UDP' }, ] }, 'ResolvedImageDigest': 'string', 'ServerSdkVersion': 'string' }, 'SupportContainerDefinitions': [ { 'ContainerName': 'string', 'DependsOn': [ { 'ContainerName': 'string', 'Condition': 'START'|'COMPLETE'|'SUCCESS'|'HEALTHY' }, ], 'MountPoints': [ { 'InstancePath': 'string', 'ContainerPath': 'string', 'AccessLevel': 'READ_ONLY'|'READ_AND_WRITE' }, ], 'EnvironmentOverride': [ { 'Name': 'string', 'Value': 'string' }, ], 'Essential': True|False, 'HealthCheck': { 'Command': [ 'string', ], 'Interval': 123, 'Retries': 123, 'StartPeriod': 123, 'Timeout': 123 }, 'ImageUri': 'string', 'MemoryHardLimitMebibytes': 123, 'PortConfiguration': { 'ContainerPortRanges': [ { 'FromPort': 123, 'ToPort': 123, 'Protocol': 'TCP'|'UDP' }, ] }, 'ResolvedImageDigest': 'string', 'Vcpu': 123.0 }, ], 'VersionNumber': 123, 'VersionDescription': 'string', 'Status': 'READY'|'COPYING'|'FAILED', 'StatusReason': 'string' }, ], 'NextToken': 'string' }
Response Structure
(dict) --
ContainerGroupDefinitions (list) --
A result set of container group definitions that match the request.
(dict) --
The properties that describe a container group resource. You can update all properties of a container group definition properties. Updates to a container group definition are saved as new versions.
Used with: CreateContainerGroupDefinition
Returned by: DescribeContainerGroupDefinition, ListContainerGroupDefinitions, UpdateContainerGroupDefinition
ContainerGroupDefinitionArn (string) --
The Amazon Resource Name ( ARN) that is assigned to an Amazon GameLift ContainerGroupDefinition resource. It uniquely identifies the resource across all Amazon Web Services Regions. Format is arn:aws:gamelift:[region]::containergroupdefinition/[container group definition name]:[version].
CreationTime (datetime) --
A time stamp indicating when this data object was created. Format is a number expressed in Unix time as milliseconds (for example "1469498468.057").
OperatingSystem (string) --
The platform that all containers in the container group definition run on.
Name (string) --
A descriptive identifier for the container group definition. The name value is unique in an Amazon Web Services Region.
ContainerGroupType (string) --
The type of container group. Container group type determines how Amazon GameLift deploys the container group on each fleet instance.
TotalMemoryLimitMebibytes (integer) --
The amount of memory (in MiB) on a fleet instance to allocate for the container group. All containers in the group share these resources.
You can set a limit for each container definition in the group. If individual containers have limits, this total value must be greater than any individual container's memory limit.
TotalVcpuLimit (float) --
The amount of vCPU units on a fleet instance to allocate for the container group (1 vCPU is equal to 1024 CPU units). All containers in the group share these resources. You can set a limit for each container definition in the group. If individual containers have limits, this total value must be equal to or greater than the sum of the limits for each container in the group.
GameServerContainerDefinition (dict) --
The definition for the game server container in this group. This property is used only when the container group type is GAME_SERVER. This container definition specifies a container image with the game server build.
ContainerName (string) --
The container definition identifier. Container names are unique within a container group definition.
DependsOn (list) --
Indicates that the container relies on the status of other containers in the same container group during startup and shutdown sequences. A container might have dependencies on multiple containers.
(dict) --
A container's dependency on another container in the same container group. The dependency impacts how the dependent container is able to start or shut down based the status of the other container.
For example, ContainerA is configured with the following dependency: a START dependency on ContainerB. This means that ContainerA can't start until ContainerB has started. It also means that ContainerA must shut down before ContainerB.
eiifcbfhgrdurhnucnufkgbnbnnerrvbtjvljdetkehc**Part of:** GameServerContainerDefinition, GameServerContainerDefinitionInput, SupportContainerDefinition, SupportContainerDefinitionInput
ContainerName (string) --
A descriptive label for the container definition that this container depends on.
Condition (string) --
The condition that the dependency container must reach before the dependent container can start. Valid conditions include:
START - The dependency container must have started.
COMPLETE - The dependency container has run to completion (exits). Use this condition with nonessential containers, such as those that run a script and then exit. The dependency container can't be an essential container.
SUCCESS - The dependency container has run to completion and exited with a zero status. The dependency container can't be an essential container.
HEALTHY - The dependency container has passed its Docker health check. Use this condition with dependency containers that have health checks configured. This condition is confirmed at container group startup only.
MountPoints (list) --
A mount point that binds a path inside the container to a file or directory on the host system and lets it access the file or directory.
(dict) --
A mount point that binds a container to a file or directory on the host system.
Part of: GameServerContainerDefinition, GameServerContainerDefinitionInput, SupportContainerDefinition, SupportContainerDefinitionInput
InstancePath (string) --
The path to the source file or directory.
ContainerPath (string) --
The mount path on the container. If this property isn't set, the instance path is used.
AccessLevel (string) --
The type of access for the container.
EnvironmentOverride (list) --
A set of environment variables that's passed to the container on startup. See the ContainerDefinition::environment parameter in the Amazon Elastic Container Service API Reference.
(dict) --
An environment variable to set inside a container, in the form of a key-value pair.
Part of: GameServerContainerDefinition, GameServerContainerDefinitionInput, SupportContainerDefinition, SupportContainerDefinitionInput
Name (string) --
The environment variable name.
Value (string) --
The environment variable value.
ImageUri (string) --
The URI to the image that Amazon GameLift uses when deploying this container to a container fleet. For a more specific identifier, see ResolvedImageDigest.
PortConfiguration (dict) --
The set of ports that are available to bind to processes in the container. For example, a game server process requires a container port to allow game clients to connect to it. Container ports aren't directly accessed by inbound traffic. Amazon GameLift maps these container ports to externally accessible connection ports, which are assigned as needed from the container fleet's ConnectionPortRange.
ContainerPortRanges (list) --
A set of one or more container port number ranges. The ranges can't overlap.
(dict) --
A set of one or more port numbers that can be opened on the container.
Part of: ContainerPortConfiguration
FromPort (integer) --
A starting value for the range of allowed port numbers.
ToPort (integer) --
An ending value for the range of allowed port numbers. Port numbers are end-inclusive. This value must be equal to or greater than FromPort.
Protocol (string) --
The network protocol that these ports support.
ResolvedImageDigest (string) --
A unique and immutable identifier for the container image. The digest is a SHA 256 hash of the container image manifest.
ServerSdkVersion (string) --
The Amazon GameLift server SDK version that the game server is integrated with. Only game servers using 5.2.0 or higher are compatible with container fleets.
SupportContainerDefinitions (list) --
The set of definitions for support containers in this group. A container group definition might have zero support container definitions. Support container can be used in any type of container group.
(dict) --
Describes a support container in a container group. A support container might be in a game server container group or a per-instance container group. Support containers don't run game server processes.
You can update a support container definition and deploy the updates to an existing fleet. When creating or updating a game server container group definition, use the property GameServerContainerDefinitionInput.
Part of: ContainerGroupDefinition
Returned by: DescribeContainerGroupDefinition, ListContainerGroupDefinitions, UpdateContainerGroupDefinition
ContainerName (string) --
The container definition identifier. Container names are unique within a container group definition.
DependsOn (list) --
Indicates that the container relies on the status of other containers in the same container group during its startup and shutdown sequences. A container might have dependencies on multiple containers.
(dict) --
A container's dependency on another container in the same container group. The dependency impacts how the dependent container is able to start or shut down based the status of the other container.
For example, ContainerA is configured with the following dependency: a START dependency on ContainerB. This means that ContainerA can't start until ContainerB has started. It also means that ContainerA must shut down before ContainerB.
eiifcbfhgrdurhnucnufkgbnbnnerrvbtjvljdetkehc**Part of:** GameServerContainerDefinition, GameServerContainerDefinitionInput, SupportContainerDefinition, SupportContainerDefinitionInput
ContainerName (string) --
A descriptive label for the container definition that this container depends on.
Condition (string) --
The condition that the dependency container must reach before the dependent container can start. Valid conditions include:
START - The dependency container must have started.
COMPLETE - The dependency container has run to completion (exits). Use this condition with nonessential containers, such as those that run a script and then exit. The dependency container can't be an essential container.
SUCCESS - The dependency container has run to completion and exited with a zero status. The dependency container can't be an essential container.
HEALTHY - The dependency container has passed its Docker health check. Use this condition with dependency containers that have health checks configured. This condition is confirmed at container group startup only.
MountPoints (list) --
A mount point that binds a path inside the container to a file or directory on the host system and lets it access the file or directory.
(dict) --
A mount point that binds a container to a file or directory on the host system.
Part of: GameServerContainerDefinition, GameServerContainerDefinitionInput, SupportContainerDefinition, SupportContainerDefinitionInput
InstancePath (string) --
The path to the source file or directory.
ContainerPath (string) --
The mount path on the container. If this property isn't set, the instance path is used.
AccessLevel (string) --
The type of access for the container.
EnvironmentOverride (list) --
A set of environment variables that's passed to the container on startup. See the ContainerDefinition::environment parameter in the Amazon Elastic Container Service API Reference.
(dict) --
An environment variable to set inside a container, in the form of a key-value pair.
Part of: GameServerContainerDefinition, GameServerContainerDefinitionInput, SupportContainerDefinition, SupportContainerDefinitionInput
Name (string) --
The environment variable name.
Value (string) --
The environment variable value.
Essential (boolean) --
Indicates whether the container is vital to the container group. If an essential container fails, the entire container group restarts.
HealthCheck (dict) --
A configuration for a non-terminal health check. A support container automatically restarts if it stops functioning or if it fails this health check.
Command (list) --
A string array that specifies the command that the container runs to determine if it's healthy.
(string) --
Interval (integer) --
The time period (in seconds) between each health check.
Retries (integer) --
The number of times to retry a failed health check before flagging the container unhealthy. The first run of the command does not count as a retry.
StartPeriod (integer) --
The optional grace period (in seconds) to give a container time to bootstrap before the first failed health check counts toward the number of retries.
Timeout (integer) --
The time period (in seconds) to wait for a health check to succeed before counting a failed health check.
ImageUri (string) --
The URI to the image that Amazon GameLift deploys to a container fleet. For a more specific identifier, see ResolvedImageDigest.
MemoryHardLimitMebibytes (integer) --
The amount of memory that Amazon GameLift makes available to the container. If memory limits aren't set for an individual container, the container shares the container group's total memory allocation.
Related data type: ContainerGroupDefinition$TotalMemoryLimitMebibytes
PortConfiguration (dict) --
A set of ports that allow access to the container from external users. Processes running in the container can bind to a one of these ports. Container ports aren't directly accessed by inbound traffic. Amazon GameLift maps these container ports to externally accessible connection ports, which are assigned as needed from the container fleet's ConnectionPortRange.
ContainerPortRanges (list) --
A set of one or more container port number ranges. The ranges can't overlap.
(dict) --
A set of one or more port numbers that can be opened on the container.
Part of: ContainerPortConfiguration
FromPort (integer) --
A starting value for the range of allowed port numbers.
ToPort (integer) --
An ending value for the range of allowed port numbers. Port numbers are end-inclusive. This value must be equal to or greater than FromPort.
Protocol (string) --
The network protocol that these ports support.
ResolvedImageDigest (string) --
A unique and immutable identifier for the container image. The digest is a SHA 256 hash of the container image manifest.
Vcpu (float) --
The number of vCPU units that are reserved for the container. If no resources are reserved, the container shares the total vCPU limit for the container group.
Related data type: ContainerGroupDefinition$TotalVcpuLimit
VersionNumber (integer) --
Indicates the version of a particular container group definition. This number is incremented automatically when you update a container group definition. You can view, update, or delete individual versions or the entire container group definition.
VersionDescription (string) --
An optional description that was provided for a container group definition update. Each version can have a unique description.
Status (string) --
Current status of the container group definition resource. Values include:
COPYING -- Amazon GameLift is in the process of making copies of all container images that are defined in the group. While in this state, the resource can't be used to create a container fleet.
READY -- Amazon GameLift has copied the registry images for all containers that are defined in the group. You can use a container group definition in this status to create a container fleet.
FAILED -- Amazon GameLift failed to create a valid container group definition resource. For more details on the cause of the failure, see StatusReason. A container group definition resource in failed status will be deleted within a few minutes.
StatusReason (string) --
Additional information about a container group definition that's in FAILED status. Possible reasons include:
An internal issue prevented Amazon GameLift from creating the container group definition resource. Delete the failed resource and call CreateContainerGroupDefinitionagain.
An access-denied message means that you don't have permissions to access the container image on ECR. See IAM permission examples for help setting up required IAM permissions for Amazon GameLift.
The ImageUri value for at least one of the containers in the container group definition was invalid or not found in the current Amazon Web Services account.
At least one of the container images referenced in the container group definition exceeds the allowed size. For size limits, see Amazon GameLift endpoints and quotas.
At least one of the container images referenced in the container group definition uses a different operating system than the one defined for the container group.
NextToken (string) --
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.
Updates the properties of a managed container fleet. Depending on the properties being updated, this operation might initiate a fleet deployment. You can track deployments for a fleet using DescribeFleetDeployment.
Request options
As with CreateContainerFleet, many fleet properties use common defaults or are calculated based on the fleet's container group definitions.
Update fleet properties that result in a fleet deployment. Include only those properties that you want to change. Specify deployment configuration settings.
Update fleet properties that don't result in a fleet deployment. Include only those properties that you want to change.
Changes to the following properties initiate a fleet deployment:
GameServerContainerGroupDefinition
PerInstanceContainerGroupDefinition
GameServerContainerGroupsPerInstance
InstanceInboundPermissions
InstanceConnectionPortRange
LogConfiguration
Results
If successful, this operation updates the container fleet resource, and might initiate a new deployment of fleet resources using the deployment configuration provided. A deployment replaces existing fleet instances with new instances that are deployed with the updated fleet properties. The fleet is placed in UPDATING status until the deployment is complete, then return to ACTIVE.
You can have only one update deployment active at a time for a fleet. If a second update request initiates a deployment while another deployment is in progress, the first deployment is cancelled.
See also: AWS API Documentation
Request Syntax
client.update_container_fleet( FleetId='string', GameServerContainerGroupDefinitionName='string', PerInstanceContainerGroupDefinitionName='string', GameServerContainerGroupsPerInstance=123, InstanceConnectionPortRange={ 'FromPort': 123, 'ToPort': 123 }, InstanceInboundPermissionAuthorizations=[ { 'FromPort': 123, 'ToPort': 123, 'IpRange': 'string', 'Protocol': 'TCP'|'UDP' }, ], InstanceInboundPermissionRevocations=[ { 'FromPort': 123, 'ToPort': 123, 'IpRange': 'string', 'Protocol': 'TCP'|'UDP' }, ], DeploymentConfiguration={ 'ProtectionStrategy': 'WITH_PROTECTION'|'IGNORE_PROTECTION', 'MinimumHealthyPercentage': 123, 'ImpairmentStrategy': 'MAINTAIN'|'ROLLBACK' }, Description='string', MetricGroups=[ 'string', ], NewGameSessionProtectionPolicy='NoProtection'|'FullProtection', GameSessionCreationLimitPolicy={ 'NewGameSessionsPerCreator': 123, 'PolicyPeriodInMinutes': 123 }, LogConfiguration={ 'LogDestination': 'NONE'|'CLOUDWATCH'|'S3', 'S3BucketName': 'string', 'LogGroupArn': 'string' }, RemoveAttributes=[ 'PER_INSTANCE_CONTAINER_GROUP_DEFINITION', ] )
string
[REQUIRED]
A unique identifier for the container fleet to update. You can use either the fleet ID or ARN value.
string
The name or ARN value of a new game server container group definition to deploy on the fleet. If you're updating the fleet to a specific version of a container group definition, use the ARN value and include the version number. If you're updating the fleet to the latest version of a container group definition, you can use the name value. You can't remove a fleet's game server container group definition, you can only update or replace it with another definition.
Update a container group definition by calling UpdateContainerGroupDefinition. This operation creates a ContainerGroupDefinition resource with an incremented version.
string
The name or ARN value of a new per-instance container group definition to deploy on the fleet. If you're updating the fleet to a specific version of a container group definition, use the ARN value and include the version number. If you're updating the fleet to the latest version of a container group definition, you can use the name value.
Update a container group definition by calling UpdateContainerGroupDefinition. This operation creates a ContainerGroupDefinition resource with an incremented version.
To remove a fleet's per-instance container group definition, leave this parameter empty and use the parameter RemoveAttributes.
integer
The number of times to replicate the game server container group on each fleet instance. By default, Amazon GameLift calculates the maximum number of game server container groups that can fit on each instance. You can remove this property value to use the calculated value, or set it manually. If you set this number manually, Amazon GameLift uses your value as long as it's less than the calculated maximum.
dict
A revised set of port numbers to open on each fleet instance. By default, Amazon GameLift calculates an optimal port range based on your fleet configuration. If you previously set this parameter manually, you can't reset this to use the calculated settings.
FromPort (integer) -- [REQUIRED]
Starting value for the port range.
ToPort (integer) -- [REQUIRED]
Ending value for the port. Port numbers are end-inclusive. This value must be equal to or greater than FromPort.
list
A set of ports to add to the container fleet's inbound permissions.
(dict) --
A range of IP addresses and port settings that allow inbound traffic to connect to processes on an instance in a fleet. Processes are assigned an IP address/port number combination, which must fall into the fleet's allowed ranges. For managed container fleets, the port settings must use the same port numbers as the fleet's connection ports.
For Realtime Servers fleets, Amazon GameLift automatically opens two port ranges, one for TCP messaging and one for UDP.
FromPort (integer) -- [REQUIRED]
A starting value for a range of allowed port numbers.
For fleets using Linux builds, only ports 22 and 1026-60000 are valid.
For fleets using Windows builds, only ports 1026-60000 are valid.
ToPort (integer) -- [REQUIRED]
An ending value for a range of allowed port numbers. Port numbers are end-inclusive. This value must be equal to or greater than FromPort.
For fleets using Linux builds, only ports 22 and 1026-60000 are valid.
For fleets using Windows builds, only ports 1026-60000 are valid.
IpRange (string) -- [REQUIRED]
A range of allowed IP addresses. This value must be expressed in CIDR notation. Example: " 000.000.000.000/[subnet mask]" or optionally the shortened version " 0.0.0.0/[subnet mask]".
Protocol (string) -- [REQUIRED]
The network communication protocol used by the fleet.
list
A set of ports to remove from the container fleet's inbound permissions.
(dict) --
A range of IP addresses and port settings that allow inbound traffic to connect to processes on an instance in a fleet. Processes are assigned an IP address/port number combination, which must fall into the fleet's allowed ranges. For managed container fleets, the port settings must use the same port numbers as the fleet's connection ports.
For Realtime Servers fleets, Amazon GameLift automatically opens two port ranges, one for TCP messaging and one for UDP.
FromPort (integer) -- [REQUIRED]
A starting value for a range of allowed port numbers.
For fleets using Linux builds, only ports 22 and 1026-60000 are valid.
For fleets using Windows builds, only ports 1026-60000 are valid.
ToPort (integer) -- [REQUIRED]
An ending value for a range of allowed port numbers. Port numbers are end-inclusive. This value must be equal to or greater than FromPort.
For fleets using Linux builds, only ports 22 and 1026-60000 are valid.
For fleets using Windows builds, only ports 1026-60000 are valid.
IpRange (string) -- [REQUIRED]
A range of allowed IP addresses. This value must be expressed in CIDR notation. Example: " 000.000.000.000/[subnet mask]" or optionally the shortened version " 0.0.0.0/[subnet mask]".
Protocol (string) -- [REQUIRED]
The network communication protocol used by the fleet.
dict
Instructions for how to deploy updates to a container fleet, if the fleet update initiates a deployment. The deployment configuration lets you determine how to replace fleet instances and what actions to take if the deployment fails.
ProtectionStrategy (string) --
Determines how fleet deployment activity affects active game sessions on the fleet. With protection, a deployment honors game session protection, and delays actions that would interrupt a protected active game session until the game session ends. Without protection, deployment activity can shut down all running tasks, including active game sessions, regardless of game session protection.
MinimumHealthyPercentage (integer) --
Sets a minimum level of healthy tasks to maintain during deployment activity.
ImpairmentStrategy (string) --
Determines what actions to take if a deployment fails. If the fleet is multi-location, this strategy applies across all fleet locations. With a rollback strategy, updated fleet instances are rolled back to the last successful deployment. Alternatively, you can maintain a few impaired containers for the purpose of debugging, while all other tasks return to the last successful deployment.
string
A meaningful description of the container fleet.
list
The name of an Amazon Web Services CloudWatch metric group to add this fleet to.
(string) --
string
The game session protection policy to apply to all new game sessions that are started in this fleet. Game sessions that already exist are not affected.
dict
A policy that limits the number of game sessions that each individual player can create on instances in this fleet. The limit applies for a specified span of time.
NewGameSessionsPerCreator (integer) --
A policy that puts limits on the number of game sessions that a player can create within a specified span of time. With this policy, you can control players' ability to consume available resources.
The policy evaluates when a player tries to create a new game session. On receiving a CreateGameSession request, Amazon GameLift checks that the player (identified by CreatorId) has created fewer than game session limit in the specified time period.
PolicyPeriodInMinutes (integer) --
The time span used in evaluating the resource creation limit policy.
dict
The method for collecting container logs for the fleet.
LogDestination (string) --
The type of log collection to use for a fleet.
CLOUDWATCH -- (default value) Send logs to an Amazon CloudWatch log group that you define. Each container emits a log stream, which is organized in the log group.
S3 -- Store logs in an Amazon S3 bucket that you define.
NONE -- Don't collect container logs.
S3BucketName (string) --
If log destination is S3, logs are sent to the specified Amazon S3 bucket name.
LogGroupArn (string) --
If log destination is CLOUDWATCH, logs are sent to the specified log group in Amazon CloudWatch.
list
If set, this update removes a fleet's per-instance container group definition. You can't remove a fleet's game server container group definition.
(string) --
dict
Response Syntax
{ 'ContainerFleet': { 'FleetId': 'string', 'FleetArn': 'string', 'FleetRoleArn': 'string', 'GameServerContainerGroupDefinitionName': 'string', 'GameServerContainerGroupDefinitionArn': 'string', 'PerInstanceContainerGroupDefinitionName': 'string', 'PerInstanceContainerGroupDefinitionArn': 'string', 'InstanceConnectionPortRange': { 'FromPort': 123, 'ToPort': 123 }, 'InstanceInboundPermissions': [ { 'FromPort': 123, 'ToPort': 123, 'IpRange': 'string', 'Protocol': 'TCP'|'UDP' }, ], 'GameServerContainerGroupsPerInstance': 123, 'MaximumGameServerContainerGroupsPerInstance': 123, 'InstanceType': 'string', 'BillingType': 'ON_DEMAND'|'SPOT', 'Description': 'string', 'CreationTime': datetime(2015, 1, 1), 'MetricGroups': [ 'string', ], 'NewGameSessionProtectionPolicy': 'NoProtection'|'FullProtection', 'GameSessionCreationLimitPolicy': { 'NewGameSessionsPerCreator': 123, 'PolicyPeriodInMinutes': 123 }, 'Status': 'PENDING'|'CREATING'|'CREATED'|'ACTIVATING'|'ACTIVE'|'UPDATING'|'DELETING', 'DeploymentDetails': { 'LatestDeploymentId': 'string' }, 'LogConfiguration': { 'LogDestination': 'NONE'|'CLOUDWATCH'|'S3', 'S3BucketName': 'string', 'LogGroupArn': 'string' }, 'LocationAttributes': [ { 'Location': 'string', 'Status': 'PENDING'|'CREATING'|'CREATED'|'ACTIVATING'|'ACTIVE'|'UPDATING'|'DELETING' }, ] } }
Response Structure
(dict) --
ContainerFleet (dict) --
A collection of container fleet objects for all fleets that match the request criteria.
FleetId (string) --
A unique identifier for the container fleet to retrieve.
FleetArn (string) --
The Amazon Resource Name ( ARN) that is assigned to a Amazon GameLift fleet resource and uniquely identifies it. ARNs are unique across all Regions. Format is arn:aws:gamelift:<region>::fleet/fleet-a1234567-b8c9-0d1e-2fa3-b45c6d7e8912. In a GameLift fleet ARN, the resource ID matches the FleetId value.
FleetRoleArn (string) --
The unique identifier for an Identity and Access Management (IAM) role with permissions to run your containers on resources that are managed by Amazon GameLift. See Set up an IAM service role. This fleet property can't be changed.
GameServerContainerGroupDefinitionName (string) --
The name of the fleet's game server container group definition, which describes how to deploy containers with your game server build and support software onto each fleet instance.
GameServerContainerGroupDefinitionArn (string) --
The Amazon Resource Name ( ARN) that is assigned to the fleet's game server container group. The ARN value also identifies the specific container group definition version in use.
PerInstanceContainerGroupDefinitionName (string) --
The name of the fleet's per-instance container group definition.
PerInstanceContainerGroupDefinitionArn (string) --
The Amazon Resource Name ( ARN) that is assigned to the fleet's per-instance container group. The ARN value also identifies the specific container group definition version in use.
InstanceConnectionPortRange (dict) --
The set of port numbers to open on each instance in a container fleet. Connection ports are used by inbound traffic to connect with processes that are running in containers on the fleet.
FromPort (integer) --
Starting value for the port range.
ToPort (integer) --
Ending value for the port. Port numbers are end-inclusive. This value must be equal to or greater than FromPort.
InstanceInboundPermissions (list) --
The IP address ranges and port settings that allow inbound traffic to access game server processes and other processes on this fleet.
(dict) --
A range of IP addresses and port settings that allow inbound traffic to connect to processes on an instance in a fleet. Processes are assigned an IP address/port number combination, which must fall into the fleet's allowed ranges. For managed container fleets, the port settings must use the same port numbers as the fleet's connection ports.
For Realtime Servers fleets, Amazon GameLift automatically opens two port ranges, one for TCP messaging and one for UDP.
FromPort (integer) --
A starting value for a range of allowed port numbers.
For fleets using Linux builds, only ports 22 and 1026-60000 are valid.
For fleets using Windows builds, only ports 1026-60000 are valid.
ToPort (integer) --
An ending value for a range of allowed port numbers. Port numbers are end-inclusive. This value must be equal to or greater than FromPort.
For fleets using Linux builds, only ports 22 and 1026-60000 are valid.
For fleets using Windows builds, only ports 1026-60000 are valid.
IpRange (string) --
A range of allowed IP addresses. This value must be expressed in CIDR notation. Example: " 000.000.000.000/[subnet mask]" or optionally the shortened version " 0.0.0.0/[subnet mask]".
Protocol (string) --
The network communication protocol used by the fleet.
GameServerContainerGroupsPerInstance (integer) --
The number of times to replicate the game server container group on each fleet instance.
MaximumGameServerContainerGroupsPerInstance (integer) --
The calculated maximum number of game server container group that can be deployed on each fleet instance. The calculation depends on the resource needs of the container group and the CPU and memory resources of the fleet's instance type.
InstanceType (string) --
The Amazon EC2 instance type to use for all instances in the fleet. Instance type determines the computing resources and processing power that's available to host your game servers. This includes including CPU, memory, storage, and networking capacity. You can't update this fleet property.
BillingType (string) --
Indicates whether the fleet uses On-Demand or Spot instances for this fleet. Learn more about when to use On-Demand versus Spot Instances. You can't update this fleet property.
By default, this property is set to ON_DEMAND.
Description (string) --
A meaningful description of the container fleet.
CreationTime (datetime) --
A time stamp indicating when this data object was created. Format is a number expressed in Unix time as milliseconds (for example "1469498468.057").
MetricGroups (list) --
The name of an Amazon Web Services CloudWatch metric group to add this fleet to. Metric groups aggregate metrics for multiple fleets.
(string) --
NewGameSessionProtectionPolicy (string) --
Determines whether Amazon GameLift can shut down game sessions on the fleet that are actively running and hosting players. Amazon GameLift might prompt an instance shutdown when scaling down fleet capacity or when retiring unhealthy instances. You can also set game session protection for individual game sessions using UpdateGameSession.
NoProtection -- Game sessions can be shut down during active gameplay.
FullProtection -- Game sessions in ACTIVE status can't be shut down.
GameSessionCreationLimitPolicy (dict) --
A policy that limits the number of game sessions that each individual player can create on instances in this fleet. The limit applies for a specified span of time.
NewGameSessionsPerCreator (integer) --
A policy that puts limits on the number of game sessions that a player can create within a specified span of time. With this policy, you can control players' ability to consume available resources.
The policy evaluates when a player tries to create a new game session. On receiving a CreateGameSession request, Amazon GameLift checks that the player (identified by CreatorId) has created fewer than game session limit in the specified time period.
PolicyPeriodInMinutes (integer) --
The time span used in evaluating the resource creation limit policy.
Status (string) --
The current status of the container fleet.
PENDING -- A new container fleet has been requested.
CREATING -- A new container fleet resource is being created.
CREATED -- A new container fleet resource has been created. No fleet instances have been deployed.
ACTIVATING -- New container fleet instances are being deployed.
ACTIVE -- The container fleet has been deployed and is ready to host game sessions.
UPDATING -- Updates to the container fleet is being updated. A deployment is in progress.
DeploymentDetails (dict) --
Information about the most recent deployment for the container fleet.
LatestDeploymentId (string) --
A unique identifier for a fleet deployment.
LogConfiguration (dict) --
The method that is used to collect container logs for the fleet. Amazon GameLift saves all standard output for each container in logs, including game session logs.
CLOUDWATCH -- Send logs to an Amazon CloudWatch log group that you define. Each container emits a log stream, which is organized in the log group.
S3 -- Store logs in an Amazon S3 bucket that you define.
NONE -- Don't collect container logs.
LogDestination (string) --
The type of log collection to use for a fleet.
CLOUDWATCH -- (default value) Send logs to an Amazon CloudWatch log group that you define. Each container emits a log stream, which is organized in the log group.
S3 -- Store logs in an Amazon S3 bucket that you define.
NONE -- Don't collect container logs.
S3BucketName (string) --
If log destination is S3, logs are sent to the specified Amazon S3 bucket name.
LogGroupArn (string) --
If log destination is CLOUDWATCH, logs are sent to the specified log group in Amazon CloudWatch.
LocationAttributes (list) --
Information about the container fleet's remote locations where fleet instances are deployed.
(dict) --
Details about a location in a multi-location container fleet.
Location (string) --
A location identifier.
Status (string) --
The status of fleet activity in the location.
PENDING -- A new container fleet has been requested.
CREATING -- A new container fleet resource is being created.
CREATED -- A new container fleet resource has been created. No fleet instances have been deployed.
ACTIVATING -- New container fleet instances are being deployed.
ACTIVE -- The container fleet has been deployed and is ready to host game sessions.
UPDATING -- Updates to the container fleet is being updated. A deployment is in progress.
{'ContainerGroupType': 'GAME_SERVER | PER_INSTANCE', 'GameServerContainerDefinition': {'ContainerName': 'string', 'DependsOn': [{'Condition': 'START | ' 'COMPLETE | ' 'SUCCESS | ' 'HEALTHY', 'ContainerName': 'string'}], 'EnvironmentOverride': [{'Name': 'string', 'Value': 'string'}], 'ImageUri': 'string', 'MountPoints': [{'AccessLevel': 'READ_ONLY ' '| ' 'READ_AND_WRITE', 'ContainerPath': 'string', 'InstancePath': 'string'}], 'PortConfiguration': {'ContainerPortRanges': [{'FromPort': 'integer', 'Protocol': 'TCP ' '| ' 'UDP', 'ToPort': 'integer'}]}, 'ServerSdkVersion': 'string'}, 'SupportContainerDefinitions': [{'ContainerName': 'string', 'DependsOn': [{'Condition': 'START | ' 'COMPLETE | ' 'SUCCESS | ' 'HEALTHY', 'ContainerName': 'string'}], 'EnvironmentOverride': [{'Name': 'string', 'Value': 'string'}], 'Essential': 'boolean', 'HealthCheck': {'Command': ['string'], 'Interval': 'integer', 'Retries': 'integer', 'StartPeriod': 'integer', 'Timeout': 'integer'}, 'ImageUri': 'string', 'MemoryHardLimitMebibytes': 'integer', 'MountPoints': [{'AccessLevel': 'READ_ONLY | ' 'READ_AND_WRITE', 'ContainerPath': 'string', 'InstancePath': 'string'}], 'PortConfiguration': {'ContainerPortRanges': [{'FromPort': 'integer', 'Protocol': 'TCP ' '| ' 'UDP', 'ToPort': 'integer'}]}, 'Vcpu': 'double'}], 'TotalMemoryLimitMebibytes': 'integer', 'TotalVcpuLimit': 'double', 'VersionDescription': 'string'}Response
{'ContainerGroupDefinition': {'ContainerGroupType': 'GAME_SERVER | ' 'PER_INSTANCE', 'GameServerContainerDefinition': {'ContainerName': 'string', 'DependsOn': [{'Condition': 'START ' '| ' 'COMPLETE ' '| ' 'SUCCESS ' '| ' 'HEALTHY', 'ContainerName': 'string'}], 'EnvironmentOverride': [{'Name': 'string', 'Value': 'string'}], 'ImageUri': 'string', 'MountPoints': [{'AccessLevel': 'READ_ONLY ' '| ' 'READ_AND_WRITE', 'ContainerPath': 'string', 'InstancePath': 'string'}], 'PortConfiguration': {'ContainerPortRanges': [{'FromPort': 'integer', 'Protocol': 'TCP ' '| ' 'UDP', 'ToPort': 'integer'}]}, 'ResolvedImageDigest': 'string', 'ServerSdkVersion': 'string'}, 'SupportContainerDefinitions': [{'ContainerName': 'string', 'DependsOn': [{'Condition': 'START ' '| ' 'COMPLETE ' '| ' 'SUCCESS ' '| ' 'HEALTHY', 'ContainerName': 'string'}], 'EnvironmentOverride': [{'Name': 'string', 'Value': 'string'}], 'Essential': 'boolean', 'HealthCheck': {'Command': ['string'], 'Interval': 'integer', 'Retries': 'integer', 'StartPeriod': 'integer', 'Timeout': 'integer'}, 'ImageUri': 'string', 'MemoryHardLimitMebibytes': 'integer', 'MountPoints': [{'AccessLevel': 'READ_ONLY ' '| ' 'READ_AND_WRITE', 'ContainerPath': 'string', 'InstancePath': 'string'}], 'PortConfiguration': {'ContainerPortRanges': [{'FromPort': 'integer', 'Protocol': 'TCP ' '| ' 'UDP', 'ToPort': 'integer'}]}, 'ResolvedImageDigest': 'string', 'Vcpu': 'double'}], 'TotalMemoryLimitMebibytes': 'integer', 'TotalVcpuLimit': 'double', 'VersionDescription': 'string', 'VersionNumber': 'integer'}}
Creates a ContainerGroupDefinition that describes a set of containers for hosting your game server with Amazon GameLift managed containers hosting. An Amazon GameLift container group is similar to a container task or pod. Use container group definitions when you create a container fleet with CreateContainerFleet.
A container group definition determines how Amazon GameLift deploys your containers to each instance in a container fleet. You can maintain multiple versions of a container group definition.
There are two types of container groups:
A game server container group has the containers that run your game server application and supporting software. A game server container group can have these container types:
Game server container. This container runs your game server. You can define one game server container in a game server container group.
Support container. This container runs software in parallel with your game server. You can define up to 8 support containers in a game server group.
When building a game server container group definition, you can choose to bundle your game server executable and all dependent software into a single game server container. Alternatively, you can separate the software into one game server container and one or more support containers.
On a container fleet instance, a game server container group can be deployed multiple times (depending on the compute resources of the instance). This means that all containers in the container group are replicated together.
A per-instance container group has containers for processes that aren't replicated on a container fleet instance. This might include background services, logging, test processes, or processes that need to persist independently of the game server container group. When building a per-instance container group, you can define up to 10 support containers.
Request options
Use this operation to make the following types of requests. You can specify values for the minimum required parameters and customize optional values later.
Create a game server container group definition. Provide the following required parameter values:
Name
ContainerGroupType ( GAME_SERVER)
OperatingSystem (omit to use default value)
TotalMemoryLimitMebibytes (omit to use default value)
``TotalVcpuLimit ``(omit to use default value)
At least one GameServerContainerDefinition
ContainerName
ImageUrl
PortConfiguration
ServerSdkVersion (omit to use default value)
Create a per-instance container group definition. Provide the following required parameter values:
Name
ContainerGroupType ( PER_INSTANCE)
OperatingSystem (omit to use default value)
TotalMemoryLimitMebibytes (omit to use default value)
``TotalVcpuLimit ``(omit to use default value)
At least one SupportContainerDefinition
ContainerName
ImageUrl
Results
If successful, this request creates a ContainerGroupDefinition resource and assigns a unique ARN value. You can update most properties of a container group definition by calling UpdateContainerGroupDefinition, and optionally save the update as a new version.
See also: AWS API Documentation
Request Syntax
client.create_container_group_definition( Name='string', ContainerGroupType='GAME_SERVER'|'PER_INSTANCE', TotalMemoryLimitMebibytes=123, TotalVcpuLimit=123.0, GameServerContainerDefinition={ 'ContainerName': 'string', 'DependsOn': [ { 'ContainerName': 'string', 'Condition': 'START'|'COMPLETE'|'SUCCESS'|'HEALTHY' }, ], 'MountPoints': [ { 'InstancePath': 'string', 'ContainerPath': 'string', 'AccessLevel': 'READ_ONLY'|'READ_AND_WRITE' }, ], 'EnvironmentOverride': [ { 'Name': 'string', 'Value': 'string' }, ], 'ImageUri': 'string', 'PortConfiguration': { 'ContainerPortRanges': [ { 'FromPort': 123, 'ToPort': 123, 'Protocol': 'TCP'|'UDP' }, ] }, 'ServerSdkVersion': 'string' }, SupportContainerDefinitions=[ { 'ContainerName': 'string', 'DependsOn': [ { 'ContainerName': 'string', 'Condition': 'START'|'COMPLETE'|'SUCCESS'|'HEALTHY' }, ], 'MountPoints': [ { 'InstancePath': 'string', 'ContainerPath': 'string', 'AccessLevel': 'READ_ONLY'|'READ_AND_WRITE' }, ], 'EnvironmentOverride': [ { 'Name': 'string', 'Value': 'string' }, ], 'Essential': True|False, 'HealthCheck': { 'Command': [ 'string', ], 'Interval': 123, 'Retries': 123, 'StartPeriod': 123, 'Timeout': 123 }, 'ImageUri': 'string', 'MemoryHardLimitMebibytes': 123, 'PortConfiguration': { 'ContainerPortRanges': [ { 'FromPort': 123, 'ToPort': 123, 'Protocol': 'TCP'|'UDP' }, ] }, 'Vcpu': 123.0 }, ], OperatingSystem='AMAZON_LINUX_2023', VersionDescription='string', Tags=[ { 'Key': 'string', 'Value': 'string' }, ] )
string
[REQUIRED]
A descriptive identifier for the container group definition. The name value must be unique in an Amazon Web Services Region.
string
The type of container group being defined. Container group type determines how Amazon GameLift deploys the container group on each fleet instance.
Default value: GAME_SERVER
integer
[REQUIRED]
The maximum amount of memory (in MiB) to allocate to the container group. All containers in the group share this memory. If you specify memory limits for an individual container, the total value must be greater than any individual container's memory limit.
Default value: 1024
float
[REQUIRED]
The maximum amount of vCPU units to allocate to the container group (1 vCPU is equal to 1024 CPU units). All containers in the group share this memory. If you specify vCPU limits for individual containers, the total value must be equal to or greater than the sum of the CPU limits for all containers in the group.
Default value: 1
dict
The definition for the game server container in this group. Define a game server container only when the container group type is GAME_SERVER. Game server containers specify a container image with your game server build. You can pass in your container definitions as a JSON file.
ContainerName (string) -- [REQUIRED]
A string that uniquely identifies the container definition within a container group.
DependsOn (list) --
Establishes dependencies between this container and the status of other containers in the same container group. A container can have dependencies on multiple different containers.
You can use dependencies to establish a startup/shutdown sequence across the container group. For example, you might specify that ContainerB has a START dependency on ContainerA. This dependency means that ContainerB can't start until after ContainerA has started. This dependency is reversed on shutdown, which means that ContainerB must shut down before ContainerA can shut down.
(dict) --
A container's dependency on another container in the same container group. The dependency impacts how the dependent container is able to start or shut down based the status of the other container.
For example, ContainerA is configured with the following dependency: a START dependency on ContainerB. This means that ContainerA can't start until ContainerB has started. It also means that ContainerA must shut down before ContainerB.
eiifcbfhgrdurhnucnufkgbnbnnerrvbtjvljdetkehc**Part of:** GameServerContainerDefinition, GameServerContainerDefinitionInput, SupportContainerDefinition, SupportContainerDefinitionInput
ContainerName (string) -- [REQUIRED]
A descriptive label for the container definition that this container depends on.
Condition (string) -- [REQUIRED]
The condition that the dependency container must reach before the dependent container can start. Valid conditions include:
START - The dependency container must have started.
COMPLETE - The dependency container has run to completion (exits). Use this condition with nonessential containers, such as those that run a script and then exit. The dependency container can't be an essential container.
SUCCESS - The dependency container has run to completion and exited with a zero status. The dependency container can't be an essential container.
HEALTHY - The dependency container has passed its Docker health check. Use this condition with dependency containers that have health checks configured. This condition is confirmed at container group startup only.
MountPoints (list) --
A mount point that binds a path inside the container to a file or directory on the host system and lets it access the file or directory.
(dict) --
A mount point that binds a container to a file or directory on the host system.
Part of: GameServerContainerDefinition, GameServerContainerDefinitionInput, SupportContainerDefinition, SupportContainerDefinitionInput
InstancePath (string) -- [REQUIRED]
The path to the source file or directory.
ContainerPath (string) --
The mount path on the container. If this property isn't set, the instance path is used.
AccessLevel (string) --
The type of access for the container.
EnvironmentOverride (list) --
A set of environment variables to pass to the container on startup. See the ContainerDefinition::environment parameter in the Amazon Elastic Container Service API Reference.
(dict) --
An environment variable to set inside a container, in the form of a key-value pair.
Part of: GameServerContainerDefinition, GameServerContainerDefinitionInput, SupportContainerDefinition, SupportContainerDefinitionInput
Name (string) -- [REQUIRED]
The environment variable name.
Value (string) -- [REQUIRED]
The environment variable value.
ImageUri (string) -- [REQUIRED]
The location of the container image to deploy to a container fleet. Provide an image in an Amazon Elastic Container Registry public or private repository. The repository must be in the same Amazon Web Services account and Amazon Web Services Region where you're creating the container group definition. For limits on image size, see Amazon GameLift endpoints and quotas. You can use any of the following image URI formats:
Image ID only: [AWS account].dkr.ecr.[AWS region].amazonaws.com/[repository ID]
Image ID and digest: [AWS account].dkr.ecr.[AWS region].amazonaws.com/[repository ID]@[digest]
Image ID and tag: [AWS account].dkr.ecr.[AWS region].amazonaws.com/[repository ID]:[tag]
PortConfiguration (dict) -- [REQUIRED]
A set of ports that Amazon GameLift can assign to processes in the container. Processes, must be assigned a container port to accept inbound traffic connections. For example, a game server process requires a container port to allow game clients to connect to it. Container ports aren't directly accessed by inbound traffic. Instead, Amazon GameLift maps container ports to externally accessible connection ports (see the container fleet property ConnectionPortRange).
ContainerPortRanges (list) -- [REQUIRED]
A set of one or more container port number ranges. The ranges can't overlap.
(dict) --
A set of one or more port numbers that can be opened on the container.
Part of: ContainerPortConfiguration
FromPort (integer) -- [REQUIRED]
A starting value for the range of allowed port numbers.
ToPort (integer) -- [REQUIRED]
An ending value for the range of allowed port numbers. Port numbers are end-inclusive. This value must be equal to or greater than FromPort.
Protocol (string) -- [REQUIRED]
The network protocol that these ports support.
ServerSdkVersion (string) -- [REQUIRED]
The Amazon GameLift server SDK version that the game server is integrated with. Only game servers using 5.2.0 or higher are compatible with container fleets.
list
One or more definition for support containers in this group. You can define a support container in any type of container group. You can pass in your container definitions as a JSON file.
(dict) --
Describes a support container in a container group. You can define a support container in either a game server container group or a per-instance container group. Support containers don't run game server processes.
This definition includes container configuration, resources, and start instructions. Use this data type when creating or updating a container group definition. For properties of a deployed support container, see SupportContainerDefinition.
Use with: CreateContainerGroupDefinition, UpdateContainerGroupDefinition
ContainerName (string) -- [REQUIRED]
A string that uniquely identifies the container definition within a container group.
DependsOn (list) --
Establishes dependencies between this container and the status of other containers in the same container group. A container can have dependencies on multiple different containers.
.
You can use dependencies to establish a startup/shutdown sequence across the container group. For example, you might specify that ContainerB has a START dependency on ContainerA. This dependency means that ContainerB can't start until after ContainerA has started. This dependency is reversed on shutdown, which means that ContainerB must shut down before ContainerA can shut down.
(dict) --
A container's dependency on another container in the same container group. The dependency impacts how the dependent container is able to start or shut down based the status of the other container.
For example, ContainerA is configured with the following dependency: a START dependency on ContainerB. This means that ContainerA can't start until ContainerB has started. It also means that ContainerA must shut down before ContainerB.
eiifcbfhgrdurhnucnufkgbnbnnerrvbtjvljdetkehc**Part of:** GameServerContainerDefinition, GameServerContainerDefinitionInput, SupportContainerDefinition, SupportContainerDefinitionInput
ContainerName (string) -- [REQUIRED]
A descriptive label for the container definition that this container depends on.
Condition (string) -- [REQUIRED]
The condition that the dependency container must reach before the dependent container can start. Valid conditions include:
START - The dependency container must have started.
COMPLETE - The dependency container has run to completion (exits). Use this condition with nonessential containers, such as those that run a script and then exit. The dependency container can't be an essential container.
SUCCESS - The dependency container has run to completion and exited with a zero status. The dependency container can't be an essential container.
HEALTHY - The dependency container has passed its Docker health check. Use this condition with dependency containers that have health checks configured. This condition is confirmed at container group startup only.
MountPoints (list) --
A mount point that binds a path inside the container to a file or directory on the host system and lets it access the file or directory.
(dict) --
A mount point that binds a container to a file or directory on the host system.
Part of: GameServerContainerDefinition, GameServerContainerDefinitionInput, SupportContainerDefinition, SupportContainerDefinitionInput
InstancePath (string) -- [REQUIRED]
The path to the source file or directory.
ContainerPath (string) --
The mount path on the container. If this property isn't set, the instance path is used.
AccessLevel (string) --
The type of access for the container.
EnvironmentOverride (list) --
A set of environment variables to pass to the container on startup. See the ContainerDefinition::environment parameter in the Amazon Elastic Container Service API Reference.
(dict) --
An environment variable to set inside a container, in the form of a key-value pair.
Part of: GameServerContainerDefinition, GameServerContainerDefinitionInput, SupportContainerDefinition, SupportContainerDefinitionInput
Name (string) -- [REQUIRED]
The environment variable name.
Value (string) -- [REQUIRED]
The environment variable value.
Essential (boolean) --
Flags the container as vital for the container group to function properly. If an essential container fails, the entire container group restarts. At least one support container in a per-instance container group must be essential. When flagging a container as essential, also configure a health check so that the container can signal that it's healthy.
HealthCheck (dict) --
Configuration for a non-terminal health check. A container automatically restarts if it stops functioning. With a health check, you can define additional reasons to flag a container as unhealthy and restart it. If an essential container fails a health check, the entire container group restarts.
Command (list) -- [REQUIRED]
A string array that specifies the command that the container runs to determine if it's healthy.
(string) --
Interval (integer) --
The time period (in seconds) between each health check.
Retries (integer) --
The number of times to retry a failed health check before flagging the container unhealthy. The first run of the command does not count as a retry.
StartPeriod (integer) --
The optional grace period (in seconds) to give a container time to bootstrap before the first failed health check counts toward the number of retries.
Timeout (integer) --
The time period (in seconds) to wait for a health check to succeed before counting a failed health check.
ImageUri (string) -- [REQUIRED]
The location of the container image to deploy to a container fleet. Provide an image in an Amazon Elastic Container Registry public or private repository. The repository must be in the same Amazon Web Services account and Amazon Web Services Region where you're creating the container group definition. For limits on image size, see Amazon GameLift endpoints and quotas. You can use any of the following image URI formats:
Image ID only: [AWS account].dkr.ecr.[AWS region].amazonaws.com/[repository ID]
Image ID and digest: [AWS account].dkr.ecr.[AWS region].amazonaws.com/[repository ID]@[digest]
Image ID and tag: [AWS account].dkr.ecr.[AWS region].amazonaws.com/[repository ID]:[tag]
MemoryHardLimitMebibytes (integer) --
A specified amount of memory (in MiB) to reserve for this container. If you don't specify a container-specific memory limit, the container shares the container group's total memory allocation.
Related data type: ContainerGroupDefinition TotalMemoryLimitMebibytes
PortConfiguration (dict) --
A set of ports that Amazon GameLift can assign to processes in the container. Any processes that accept inbound traffic connections must be assigned a port from this set. The container port range must be large enough to assign one to each process in the container that needs one.
Container ports aren't directly accessed by inbound traffic. Amazon GameLift maps these container ports to externally accessible connection ports, which are assigned as needed from the container fleet's ConnectionPortRange.
ContainerPortRanges (list) -- [REQUIRED]
A set of one or more container port number ranges. The ranges can't overlap.
(dict) --
A set of one or more port numbers that can be opened on the container.
Part of: ContainerPortConfiguration
FromPort (integer) -- [REQUIRED]
A starting value for the range of allowed port numbers.
ToPort (integer) -- [REQUIRED]
An ending value for the range of allowed port numbers. Port numbers are end-inclusive. This value must be equal to or greater than FromPort.
Protocol (string) -- [REQUIRED]
The network protocol that these ports support.
Vcpu (float) --
The number of vCPU units to reserve for this container. The container can use more resources when needed, if available. If you don't reserve CPU units for this container, it shares the container group's total vCPU limit.
Related data type: ContainerGroupDefinition TotalCpuLimit
string
[REQUIRED]
The platform that all containers in the group use. Containers in a group must run on the same operating system.
Default value: AMAZON_LINUX_2023
string
A description for the initial version of this container group definition.
list
A list of labels to assign to the container group definition resource. Tags are developer-defined key-value pairs. Tagging Amazon Web Services resources are useful for resource management, access management and cost allocation. For more information, see Tagging Amazon Web Services Resources in the Amazon Web Services General Reference.
(dict) --
A label that you can assign to a Amazon GameLift resource.
Learn more
Tagging Amazon Web Services Resources in the Amazon Web Services General Reference
Amazon Web Services Tagging Strategies
Related actions
Key (string) -- [REQUIRED]
The key for a developer-defined key value pair for tagging an Amazon Web Services resource.
Value (string) -- [REQUIRED]
The value for a developer-defined key value pair for tagging an Amazon Web Services resource.
dict
Response Syntax
{ 'ContainerGroupDefinition': { 'ContainerGroupDefinitionArn': 'string', 'CreationTime': datetime(2015, 1, 1), 'OperatingSystem': 'AMAZON_LINUX_2023', 'Name': 'string', 'ContainerGroupType': 'GAME_SERVER'|'PER_INSTANCE', 'TotalMemoryLimitMebibytes': 123, 'TotalVcpuLimit': 123.0, 'GameServerContainerDefinition': { 'ContainerName': 'string', 'DependsOn': [ { 'ContainerName': 'string', 'Condition': 'START'|'COMPLETE'|'SUCCESS'|'HEALTHY' }, ], 'MountPoints': [ { 'InstancePath': 'string', 'ContainerPath': 'string', 'AccessLevel': 'READ_ONLY'|'READ_AND_WRITE' }, ], 'EnvironmentOverride': [ { 'Name': 'string', 'Value': 'string' }, ], 'ImageUri': 'string', 'PortConfiguration': { 'ContainerPortRanges': [ { 'FromPort': 123, 'ToPort': 123, 'Protocol': 'TCP'|'UDP' }, ] }, 'ResolvedImageDigest': 'string', 'ServerSdkVersion': 'string' }, 'SupportContainerDefinitions': [ { 'ContainerName': 'string', 'DependsOn': [ { 'ContainerName': 'string', 'Condition': 'START'|'COMPLETE'|'SUCCESS'|'HEALTHY' }, ], 'MountPoints': [ { 'InstancePath': 'string', 'ContainerPath': 'string', 'AccessLevel': 'READ_ONLY'|'READ_AND_WRITE' }, ], 'EnvironmentOverride': [ { 'Name': 'string', 'Value': 'string' }, ], 'Essential': True|False, 'HealthCheck': { 'Command': [ 'string', ], 'Interval': 123, 'Retries': 123, 'StartPeriod': 123, 'Timeout': 123 }, 'ImageUri': 'string', 'MemoryHardLimitMebibytes': 123, 'PortConfiguration': { 'ContainerPortRanges': [ { 'FromPort': 123, 'ToPort': 123, 'Protocol': 'TCP'|'UDP' }, ] }, 'ResolvedImageDigest': 'string', 'Vcpu': 123.0 }, ], 'VersionNumber': 123, 'VersionDescription': 'string', 'Status': 'READY'|'COPYING'|'FAILED', 'StatusReason': 'string' } }
Response Structure
(dict) --
ContainerGroupDefinition (dict) --
The properties of the new container group definition resource. You can use this resource to create a container fleet.
ContainerGroupDefinitionArn (string) --
The Amazon Resource Name ( ARN) that is assigned to an Amazon GameLift ContainerGroupDefinition resource. It uniquely identifies the resource across all Amazon Web Services Regions. Format is arn:aws:gamelift:[region]::containergroupdefinition/[container group definition name]:[version].
CreationTime (datetime) --
A time stamp indicating when this data object was created. Format is a number expressed in Unix time as milliseconds (for example "1469498468.057").
OperatingSystem (string) --
The platform that all containers in the container group definition run on.
Name (string) --
A descriptive identifier for the container group definition. The name value is unique in an Amazon Web Services Region.
ContainerGroupType (string) --
The type of container group. Container group type determines how Amazon GameLift deploys the container group on each fleet instance.
TotalMemoryLimitMebibytes (integer) --
The amount of memory (in MiB) on a fleet instance to allocate for the container group. All containers in the group share these resources.
You can set a limit for each container definition in the group. If individual containers have limits, this total value must be greater than any individual container's memory limit.
TotalVcpuLimit (float) --
The amount of vCPU units on a fleet instance to allocate for the container group (1 vCPU is equal to 1024 CPU units). All containers in the group share these resources. You can set a limit for each container definition in the group. If individual containers have limits, this total value must be equal to or greater than the sum of the limits for each container in the group.
GameServerContainerDefinition (dict) --
The definition for the game server container in this group. This property is used only when the container group type is GAME_SERVER. This container definition specifies a container image with the game server build.
ContainerName (string) --
The container definition identifier. Container names are unique within a container group definition.
DependsOn (list) --
Indicates that the container relies on the status of other containers in the same container group during startup and shutdown sequences. A container might have dependencies on multiple containers.
(dict) --
A container's dependency on another container in the same container group. The dependency impacts how the dependent container is able to start or shut down based the status of the other container.
For example, ContainerA is configured with the following dependency: a START dependency on ContainerB. This means that ContainerA can't start until ContainerB has started. It also means that ContainerA must shut down before ContainerB.
eiifcbfhgrdurhnucnufkgbnbnnerrvbtjvljdetkehc**Part of:** GameServerContainerDefinition, GameServerContainerDefinitionInput, SupportContainerDefinition, SupportContainerDefinitionInput
ContainerName (string) --
A descriptive label for the container definition that this container depends on.
Condition (string) --
The condition that the dependency container must reach before the dependent container can start. Valid conditions include:
START - The dependency container must have started.
COMPLETE - The dependency container has run to completion (exits). Use this condition with nonessential containers, such as those that run a script and then exit. The dependency container can't be an essential container.
SUCCESS - The dependency container has run to completion and exited with a zero status. The dependency container can't be an essential container.
HEALTHY - The dependency container has passed its Docker health check. Use this condition with dependency containers that have health checks configured. This condition is confirmed at container group startup only.
MountPoints (list) --
A mount point that binds a path inside the container to a file or directory on the host system and lets it access the file or directory.
(dict) --
A mount point that binds a container to a file or directory on the host system.
Part of: GameServerContainerDefinition, GameServerContainerDefinitionInput, SupportContainerDefinition, SupportContainerDefinitionInput
InstancePath (string) --
The path to the source file or directory.
ContainerPath (string) --
The mount path on the container. If this property isn't set, the instance path is used.
AccessLevel (string) --
The type of access for the container.
EnvironmentOverride (list) --
A set of environment variables that's passed to the container on startup. See the ContainerDefinition::environment parameter in the Amazon Elastic Container Service API Reference.
(dict) --
An environment variable to set inside a container, in the form of a key-value pair.
Part of: GameServerContainerDefinition, GameServerContainerDefinitionInput, SupportContainerDefinition, SupportContainerDefinitionInput
Name (string) --
The environment variable name.
Value (string) --
The environment variable value.
ImageUri (string) --
The URI to the image that Amazon GameLift uses when deploying this container to a container fleet. For a more specific identifier, see ResolvedImageDigest.
PortConfiguration (dict) --
The set of ports that are available to bind to processes in the container. For example, a game server process requires a container port to allow game clients to connect to it. Container ports aren't directly accessed by inbound traffic. Amazon GameLift maps these container ports to externally accessible connection ports, which are assigned as needed from the container fleet's ConnectionPortRange.
ContainerPortRanges (list) --
A set of one or more container port number ranges. The ranges can't overlap.
(dict) --
A set of one or more port numbers that can be opened on the container.
Part of: ContainerPortConfiguration
FromPort (integer) --
A starting value for the range of allowed port numbers.
ToPort (integer) --
An ending value for the range of allowed port numbers. Port numbers are end-inclusive. This value must be equal to or greater than FromPort.
Protocol (string) --
The network protocol that these ports support.
ResolvedImageDigest (string) --
A unique and immutable identifier for the container image. The digest is a SHA 256 hash of the container image manifest.
ServerSdkVersion (string) --
The Amazon GameLift server SDK version that the game server is integrated with. Only game servers using 5.2.0 or higher are compatible with container fleets.
SupportContainerDefinitions (list) --
The set of definitions for support containers in this group. A container group definition might have zero support container definitions. Support container can be used in any type of container group.
(dict) --
Describes a support container in a container group. A support container might be in a game server container group or a per-instance container group. Support containers don't run game server processes.
You can update a support container definition and deploy the updates to an existing fleet. When creating or updating a game server container group definition, use the property GameServerContainerDefinitionInput.
Part of: ContainerGroupDefinition
Returned by: DescribeContainerGroupDefinition, ListContainerGroupDefinitions, UpdateContainerGroupDefinition
ContainerName (string) --
The container definition identifier. Container names are unique within a container group definition.
DependsOn (list) --
Indicates that the container relies on the status of other containers in the same container group during its startup and shutdown sequences. A container might have dependencies on multiple containers.
(dict) --
A container's dependency on another container in the same container group. The dependency impacts how the dependent container is able to start or shut down based the status of the other container.
For example, ContainerA is configured with the following dependency: a START dependency on ContainerB. This means that ContainerA can't start until ContainerB has started. It also means that ContainerA must shut down before ContainerB.
eiifcbfhgrdurhnucnufkgbnbnnerrvbtjvljdetkehc**Part of:** GameServerContainerDefinition, GameServerContainerDefinitionInput, SupportContainerDefinition, SupportContainerDefinitionInput
ContainerName (string) --
A descriptive label for the container definition that this container depends on.
Condition (string) --
The condition that the dependency container must reach before the dependent container can start. Valid conditions include:
START - The dependency container must have started.
COMPLETE - The dependency container has run to completion (exits). Use this condition with nonessential containers, such as those that run a script and then exit. The dependency container can't be an essential container.
SUCCESS - The dependency container has run to completion and exited with a zero status. The dependency container can't be an essential container.
HEALTHY - The dependency container has passed its Docker health check. Use this condition with dependency containers that have health checks configured. This condition is confirmed at container group startup only.
MountPoints (list) --
A mount point that binds a path inside the container to a file or directory on the host system and lets it access the file or directory.
(dict) --
A mount point that binds a container to a file or directory on the host system.
Part of: GameServerContainerDefinition, GameServerContainerDefinitionInput, SupportContainerDefinition, SupportContainerDefinitionInput
InstancePath (string) --
The path to the source file or directory.
ContainerPath (string) --
The mount path on the container. If this property isn't set, the instance path is used.
AccessLevel (string) --
The type of access for the container.
EnvironmentOverride (list) --
A set of environment variables that's passed to the container on startup. See the ContainerDefinition::environment parameter in the Amazon Elastic Container Service API Reference.
(dict) --
An environment variable to set inside a container, in the form of a key-value pair.
Part of: GameServerContainerDefinition, GameServerContainerDefinitionInput, SupportContainerDefinition, SupportContainerDefinitionInput
Name (string) --
The environment variable name.
Value (string) --
The environment variable value.
Essential (boolean) --
Indicates whether the container is vital to the container group. If an essential container fails, the entire container group restarts.
HealthCheck (dict) --
A configuration for a non-terminal health check. A support container automatically restarts if it stops functioning or if it fails this health check.
Command (list) --
A string array that specifies the command that the container runs to determine if it's healthy.
(string) --
Interval (integer) --
The time period (in seconds) between each health check.
Retries (integer) --
The number of times to retry a failed health check before flagging the container unhealthy. The first run of the command does not count as a retry.
StartPeriod (integer) --
The optional grace period (in seconds) to give a container time to bootstrap before the first failed health check counts toward the number of retries.
Timeout (integer) --
The time period (in seconds) to wait for a health check to succeed before counting a failed health check.
ImageUri (string) --
The URI to the image that Amazon GameLift deploys to a container fleet. For a more specific identifier, see ResolvedImageDigest.
MemoryHardLimitMebibytes (integer) --
The amount of memory that Amazon GameLift makes available to the container. If memory limits aren't set for an individual container, the container shares the container group's total memory allocation.
Related data type: ContainerGroupDefinition$TotalMemoryLimitMebibytes
PortConfiguration (dict) --
A set of ports that allow access to the container from external users. Processes running in the container can bind to a one of these ports. Container ports aren't directly accessed by inbound traffic. Amazon GameLift maps these container ports to externally accessible connection ports, which are assigned as needed from the container fleet's ConnectionPortRange.
ContainerPortRanges (list) --
A set of one or more container port number ranges. The ranges can't overlap.
(dict) --
A set of one or more port numbers that can be opened on the container.
Part of: ContainerPortConfiguration
FromPort (integer) --
A starting value for the range of allowed port numbers.
ToPort (integer) --
An ending value for the range of allowed port numbers. Port numbers are end-inclusive. This value must be equal to or greater than FromPort.
Protocol (string) --
The network protocol that these ports support.
ResolvedImageDigest (string) --
A unique and immutable identifier for the container image. The digest is a SHA 256 hash of the container image manifest.
Vcpu (float) --
The number of vCPU units that are reserved for the container. If no resources are reserved, the container shares the total vCPU limit for the container group.
Related data type: ContainerGroupDefinition$TotalVcpuLimit
VersionNumber (integer) --
Indicates the version of a particular container group definition. This number is incremented automatically when you update a container group definition. You can view, update, or delete individual versions or the entire container group definition.
VersionDescription (string) --
An optional description that was provided for a container group definition update. Each version can have a unique description.
Status (string) --
Current status of the container group definition resource. Values include:
COPYING -- Amazon GameLift is in the process of making copies of all container images that are defined in the group. While in this state, the resource can't be used to create a container fleet.
READY -- Amazon GameLift has copied the registry images for all containers that are defined in the group. You can use a container group definition in this status to create a container fleet.
FAILED -- Amazon GameLift failed to create a valid container group definition resource. For more details on the cause of the failure, see StatusReason. A container group definition resource in failed status will be deleted within a few minutes.
StatusReason (string) --
Additional information about a container group definition that's in FAILED status. Possible reasons include:
An internal issue prevented Amazon GameLift from creating the container group definition resource. Delete the failed resource and call CreateContainerGroupDefinitionagain.
An access-denied message means that you don't have permissions to access the container image on ECR. See IAM permission examples for help setting up required IAM permissions for Amazon GameLift.
The ImageUri value for at least one of the containers in the container group definition was invalid or not found in the current Amazon Web Services account.
At least one of the container images referenced in the container group definition exceeds the allowed size. For size limits, see Amazon GameLift endpoints and quotas.
At least one of the container images referenced in the container group definition uses a different operating system than the one defined for the container group.
{'VersionCountToRetain': 'integer', 'VersionNumber': 'integer'}
Deletes a container group definition. You can delete a container group definition if there are no fleets using the definition.
Request options:
Delete an entire container group definition, including all versions. Specify the container group definition name, or use an ARN value without the version number.
Delete a particular version. Specify the container group definition name and a version number, or use an ARN value that includes the version number.
Keep the newest versions and delete all older versions. Specify the container group definition name and the number of versions to retain. For example, set VersionCountToRetain to 5 to delete all but the five most recent versions.
Learn more
See also: AWS API Documentation
Request Syntax
client.delete_container_group_definition( Name='string', VersionNumber=123, VersionCountToRetain=123 )
string
[REQUIRED]
The unique identifier for the container group definition to delete. You can use either the Name or ARN value.
integer
The specific version to delete.
integer
The number of most recent versions to keep while deleting all older versions.
dict
Response Syntax
{}
Response Structure
(dict) --
{'Compute': {'ComputeStatus': {'IMPAIRED'}, 'GameServerContainerGroupDefinitionArn': 'string'}}
Retrieves properties for a compute resource in an Amazon GameLift fleet. To get a list of all computes in a fleet, call ListCompute.
To request information on a specific compute, provide the fleet ID and compute name.
If successful, this operation returns details for the requested compute resource. Depending on the fleet's compute type, the result includes the following information:
For managed EC2 fleets, this operation returns information about the EC2 instance.
For Anywhere fleets, this operation returns information about the registered compute.
See also: AWS API Documentation
Request Syntax
client.describe_compute( FleetId='string', ComputeName='string' )
string
[REQUIRED]
A unique identifier for the fleet that the compute belongs to. You can use either the fleet ID or ARN value.
string
[REQUIRED]
The unique identifier of the compute resource to retrieve properties for. For an Anywhere fleet compute, use the registered compute name. For an EC2 fleet instance, use the instance ID.
dict
Response Syntax
{ 'Compute': { 'FleetId': 'string', 'FleetArn': 'string', 'ComputeName': 'string', 'ComputeArn': 'string', 'IpAddress': 'string', 'DnsName': 'string', 'ComputeStatus': 'PENDING'|'ACTIVE'|'TERMINATING'|'IMPAIRED', 'Location': 'string', 'CreationTime': datetime(2015, 1, 1), 'OperatingSystem': 'WINDOWS_2012'|'AMAZON_LINUX'|'AMAZON_LINUX_2'|'WINDOWS_2016'|'AMAZON_LINUX_2023', 'Type': 't2.micro'|'t2.small'|'t2.medium'|'t2.large'|'c3.large'|'c3.xlarge'|'c3.2xlarge'|'c3.4xlarge'|'c3.8xlarge'|'c4.large'|'c4.xlarge'|'c4.2xlarge'|'c4.4xlarge'|'c4.8xlarge'|'c5.large'|'c5.xlarge'|'c5.2xlarge'|'c5.4xlarge'|'c5.9xlarge'|'c5.12xlarge'|'c5.18xlarge'|'c5.24xlarge'|'c5a.large'|'c5a.xlarge'|'c5a.2xlarge'|'c5a.4xlarge'|'c5a.8xlarge'|'c5a.12xlarge'|'c5a.16xlarge'|'c5a.24xlarge'|'r3.large'|'r3.xlarge'|'r3.2xlarge'|'r3.4xlarge'|'r3.8xlarge'|'r4.large'|'r4.xlarge'|'r4.2xlarge'|'r4.4xlarge'|'r4.8xlarge'|'r4.16xlarge'|'r5.large'|'r5.xlarge'|'r5.2xlarge'|'r5.4xlarge'|'r5.8xlarge'|'r5.12xlarge'|'r5.16xlarge'|'r5.24xlarge'|'r5a.large'|'r5a.xlarge'|'r5a.2xlarge'|'r5a.4xlarge'|'r5a.8xlarge'|'r5a.12xlarge'|'r5a.16xlarge'|'r5a.24xlarge'|'m3.medium'|'m3.large'|'m3.xlarge'|'m3.2xlarge'|'m4.large'|'m4.xlarge'|'m4.2xlarge'|'m4.4xlarge'|'m4.10xlarge'|'m5.large'|'m5.xlarge'|'m5.2xlarge'|'m5.4xlarge'|'m5.8xlarge'|'m5.12xlarge'|'m5.16xlarge'|'m5.24xlarge'|'m5a.large'|'m5a.xlarge'|'m5a.2xlarge'|'m5a.4xlarge'|'m5a.8xlarge'|'m5a.12xlarge'|'m5a.16xlarge'|'m5a.24xlarge'|'c5d.large'|'c5d.xlarge'|'c5d.2xlarge'|'c5d.4xlarge'|'c5d.9xlarge'|'c5d.12xlarge'|'c5d.18xlarge'|'c5d.24xlarge'|'c6a.large'|'c6a.xlarge'|'c6a.2xlarge'|'c6a.4xlarge'|'c6a.8xlarge'|'c6a.12xlarge'|'c6a.16xlarge'|'c6a.24xlarge'|'c6i.large'|'c6i.xlarge'|'c6i.2xlarge'|'c6i.4xlarge'|'c6i.8xlarge'|'c6i.12xlarge'|'c6i.16xlarge'|'c6i.24xlarge'|'r5d.large'|'r5d.xlarge'|'r5d.2xlarge'|'r5d.4xlarge'|'r5d.8xlarge'|'r5d.12xlarge'|'r5d.16xlarge'|'r5d.24xlarge'|'m6g.medium'|'m6g.large'|'m6g.xlarge'|'m6g.2xlarge'|'m6g.4xlarge'|'m6g.8xlarge'|'m6g.12xlarge'|'m6g.16xlarge'|'c6g.medium'|'c6g.large'|'c6g.xlarge'|'c6g.2xlarge'|'c6g.4xlarge'|'c6g.8xlarge'|'c6g.12xlarge'|'c6g.16xlarge'|'r6g.medium'|'r6g.large'|'r6g.xlarge'|'r6g.2xlarge'|'r6g.4xlarge'|'r6g.8xlarge'|'r6g.12xlarge'|'r6g.16xlarge'|'c6gn.medium'|'c6gn.large'|'c6gn.xlarge'|'c6gn.2xlarge'|'c6gn.4xlarge'|'c6gn.8xlarge'|'c6gn.12xlarge'|'c6gn.16xlarge'|'c7g.medium'|'c7g.large'|'c7g.xlarge'|'c7g.2xlarge'|'c7g.4xlarge'|'c7g.8xlarge'|'c7g.12xlarge'|'c7g.16xlarge'|'r7g.medium'|'r7g.large'|'r7g.xlarge'|'r7g.2xlarge'|'r7g.4xlarge'|'r7g.8xlarge'|'r7g.12xlarge'|'r7g.16xlarge'|'m7g.medium'|'m7g.large'|'m7g.xlarge'|'m7g.2xlarge'|'m7g.4xlarge'|'m7g.8xlarge'|'m7g.12xlarge'|'m7g.16xlarge'|'g5g.xlarge'|'g5g.2xlarge'|'g5g.4xlarge'|'g5g.8xlarge'|'g5g.16xlarge', 'GameLiftServiceSdkEndpoint': 'string', 'GameLiftAgentEndpoint': 'string', 'InstanceId': 'string', 'ContainerAttributes': [ { 'ContainerName': 'string', 'ContainerRuntimeId': 'string' }, ], 'GameServerContainerGroupDefinitionArn': 'string' } }
Response Structure
(dict) --
Compute (dict) --
The set of properties for the requested compute resource.
FleetId (string) --
A unique identifier for the fleet that the compute belongs to.
FleetArn (string) --
The Amazon Resource Name (ARN) of the fleet that the compute belongs to.
ComputeName (string) --
A descriptive label for the compute resource. For instances in a managed EC2 fleet, the compute name is the same value as the InstanceId ID.
ComputeArn (string) --
The ARN that is assigned to a compute resource and uniquely identifies it. ARNs are unique across locations. Instances in managed EC2 fleets are not assigned a Compute ARN.
IpAddress (string) --
The IP address of a compute resource. Amazon GameLift requires a DNS name or IP address for a compute.
DnsName (string) --
The DNS name of a compute resource. Amazon GameLift requires a DNS name or IP address for a compute.
ComputeStatus (string) --
Current status of the compute. A compute must have an ACTIVE status to host game sessions.
Location (string) --
The name of the custom location you added to the fleet that this compute resource resides in.
CreationTime (datetime) --
A time stamp indicating when this data object was created. Format is a number expressed in Unix time as milliseconds (for example "1469498468.057").
OperatingSystem (string) --
The type of operating system on the compute resource.
Type (string) --
The Amazon EC2 instance type that the fleet uses. For registered computes in an Amazon GameLift Anywhere fleet, this property is empty.
GameLiftServiceSdkEndpoint (string) --
The Amazon GameLift SDK endpoint connection for a registered compute resource in an Anywhere fleet. The game servers on the compute use this endpoint to connect to the Amazon GameLift service.
GameLiftAgentEndpoint (string) --
The endpoint of the Amazon GameLift Agent.
InstanceId (string) --
The InstanceID of the EC2 instance that is hosting the compute.
ContainerAttributes (list) --
A set of attributes for each container in the compute.
(dict) --
A unique identifier for a container in a container fleet compute.
Returned by: DescribeCompute
ContainerName (string) --
The identifier for a container that's running in a compute.
ContainerRuntimeId (string) --
The runtime ID for the container that's running in a compute. This value is unique within the compute.
GameServerContainerGroupDefinitionArn (string) --
The game server container group definition for the compute.
{'VersionNumber': 'integer'}Response
{'ContainerGroupDefinition': {'ContainerGroupType': 'GAME_SERVER | ' 'PER_INSTANCE', 'GameServerContainerDefinition': {'ContainerName': 'string', 'DependsOn': [{'Condition': 'START ' '| ' 'COMPLETE ' '| ' 'SUCCESS ' '| ' 'HEALTHY', 'ContainerName': 'string'}], 'EnvironmentOverride': [{'Name': 'string', 'Value': 'string'}], 'ImageUri': 'string', 'MountPoints': [{'AccessLevel': 'READ_ONLY ' '| ' 'READ_AND_WRITE', 'ContainerPath': 'string', 'InstancePath': 'string'}], 'PortConfiguration': {'ContainerPortRanges': [{'FromPort': 'integer', 'Protocol': 'TCP ' '| ' 'UDP', 'ToPort': 'integer'}]}, 'ResolvedImageDigest': 'string', 'ServerSdkVersion': 'string'}, 'SupportContainerDefinitions': [{'ContainerName': 'string', 'DependsOn': [{'Condition': 'START ' '| ' 'COMPLETE ' '| ' 'SUCCESS ' '| ' 'HEALTHY', 'ContainerName': 'string'}], 'EnvironmentOverride': [{'Name': 'string', 'Value': 'string'}], 'Essential': 'boolean', 'HealthCheck': {'Command': ['string'], 'Interval': 'integer', 'Retries': 'integer', 'StartPeriod': 'integer', 'Timeout': 'integer'}, 'ImageUri': 'string', 'MemoryHardLimitMebibytes': 'integer', 'MountPoints': [{'AccessLevel': 'READ_ONLY ' '| ' 'READ_AND_WRITE', 'ContainerPath': 'string', 'InstancePath': 'string'}], 'PortConfiguration': {'ContainerPortRanges': [{'FromPort': 'integer', 'Protocol': 'TCP ' '| ' 'UDP', 'ToPort': 'integer'}]}, 'ResolvedImageDigest': 'string', 'Vcpu': 'double'}], 'TotalMemoryLimitMebibytes': 'integer', 'TotalVcpuLimit': 'double', 'VersionDescription': 'string', 'VersionNumber': 'integer'}}
Retrieves the properties of a container group definition, including all container definitions in the group.
Request options:
Retrieve the latest version of a container group definition. Specify the container group definition name only, or use an ARN value without a version number.
Retrieve a particular version. Specify the container group definition name and a version number, or use an ARN value that includes the version number.
Results:
If successful, this operation returns the complete properties of a container group definition version.
Learn more
See also: AWS API Documentation
Request Syntax
client.describe_container_group_definition( Name='string', VersionNumber=123 )
string
[REQUIRED]
The unique identifier for the container group definition to retrieve properties for. You can use either the Name or ARN value.
integer
The specific version to retrieve.
dict
Response Syntax
{ 'ContainerGroupDefinition': { 'ContainerGroupDefinitionArn': 'string', 'CreationTime': datetime(2015, 1, 1), 'OperatingSystem': 'AMAZON_LINUX_2023', 'Name': 'string', 'ContainerGroupType': 'GAME_SERVER'|'PER_INSTANCE', 'TotalMemoryLimitMebibytes': 123, 'TotalVcpuLimit': 123.0, 'GameServerContainerDefinition': { 'ContainerName': 'string', 'DependsOn': [ { 'ContainerName': 'string', 'Condition': 'START'|'COMPLETE'|'SUCCESS'|'HEALTHY' }, ], 'MountPoints': [ { 'InstancePath': 'string', 'ContainerPath': 'string', 'AccessLevel': 'READ_ONLY'|'READ_AND_WRITE' }, ], 'EnvironmentOverride': [ { 'Name': 'string', 'Value': 'string' }, ], 'ImageUri': 'string', 'PortConfiguration': { 'ContainerPortRanges': [ { 'FromPort': 123, 'ToPort': 123, 'Protocol': 'TCP'|'UDP' }, ] }, 'ResolvedImageDigest': 'string', 'ServerSdkVersion': 'string' }, 'SupportContainerDefinitions': [ { 'ContainerName': 'string', 'DependsOn': [ { 'ContainerName': 'string', 'Condition': 'START'|'COMPLETE'|'SUCCESS'|'HEALTHY' }, ], 'MountPoints': [ { 'InstancePath': 'string', 'ContainerPath': 'string', 'AccessLevel': 'READ_ONLY'|'READ_AND_WRITE' }, ], 'EnvironmentOverride': [ { 'Name': 'string', 'Value': 'string' }, ], 'Essential': True|False, 'HealthCheck': { 'Command': [ 'string', ], 'Interval': 123, 'Retries': 123, 'StartPeriod': 123, 'Timeout': 123 }, 'ImageUri': 'string', 'MemoryHardLimitMebibytes': 123, 'PortConfiguration': { 'ContainerPortRanges': [ { 'FromPort': 123, 'ToPort': 123, 'Protocol': 'TCP'|'UDP' }, ] }, 'ResolvedImageDigest': 'string', 'Vcpu': 123.0 }, ], 'VersionNumber': 123, 'VersionDescription': 'string', 'Status': 'READY'|'COPYING'|'FAILED', 'StatusReason': 'string' } }
Response Structure
(dict) --
ContainerGroupDefinition (dict) --
The properties of the requested container group definition resource.
ContainerGroupDefinitionArn (string) --
The Amazon Resource Name ( ARN) that is assigned to an Amazon GameLift ContainerGroupDefinition resource. It uniquely identifies the resource across all Amazon Web Services Regions. Format is arn:aws:gamelift:[region]::containergroupdefinition/[container group definition name]:[version].
CreationTime (datetime) --
A time stamp indicating when this data object was created. Format is a number expressed in Unix time as milliseconds (for example "1469498468.057").
OperatingSystem (string) --
The platform that all containers in the container group definition run on.
Name (string) --
A descriptive identifier for the container group definition. The name value is unique in an Amazon Web Services Region.
ContainerGroupType (string) --
The type of container group. Container group type determines how Amazon GameLift deploys the container group on each fleet instance.
TotalMemoryLimitMebibytes (integer) --
The amount of memory (in MiB) on a fleet instance to allocate for the container group. All containers in the group share these resources.
You can set a limit for each container definition in the group. If individual containers have limits, this total value must be greater than any individual container's memory limit.
TotalVcpuLimit (float) --
The amount of vCPU units on a fleet instance to allocate for the container group (1 vCPU is equal to 1024 CPU units). All containers in the group share these resources. You can set a limit for each container definition in the group. If individual containers have limits, this total value must be equal to or greater than the sum of the limits for each container in the group.
GameServerContainerDefinition (dict) --
The definition for the game server container in this group. This property is used only when the container group type is GAME_SERVER. This container definition specifies a container image with the game server build.
ContainerName (string) --
The container definition identifier. Container names are unique within a container group definition.
DependsOn (list) --
Indicates that the container relies on the status of other containers in the same container group during startup and shutdown sequences. A container might have dependencies on multiple containers.
(dict) --
A container's dependency on another container in the same container group. The dependency impacts how the dependent container is able to start or shut down based the status of the other container.
For example, ContainerA is configured with the following dependency: a START dependency on ContainerB. This means that ContainerA can't start until ContainerB has started. It also means that ContainerA must shut down before ContainerB.
eiifcbfhgrdurhnucnufkgbnbnnerrvbtjvljdetkehc**Part of:** GameServerContainerDefinition, GameServerContainerDefinitionInput, SupportContainerDefinition, SupportContainerDefinitionInput
ContainerName (string) --
A descriptive label for the container definition that this container depends on.
Condition (string) --
The condition that the dependency container must reach before the dependent container can start. Valid conditions include:
START - The dependency container must have started.
COMPLETE - The dependency container has run to completion (exits). Use this condition with nonessential containers, such as those that run a script and then exit. The dependency container can't be an essential container.
SUCCESS - The dependency container has run to completion and exited with a zero status. The dependency container can't be an essential container.
HEALTHY - The dependency container has passed its Docker health check. Use this condition with dependency containers that have health checks configured. This condition is confirmed at container group startup only.
MountPoints (list) --
A mount point that binds a path inside the container to a file or directory on the host system and lets it access the file or directory.
(dict) --
A mount point that binds a container to a file or directory on the host system.
Part of: GameServerContainerDefinition, GameServerContainerDefinitionInput, SupportContainerDefinition, SupportContainerDefinitionInput
InstancePath (string) --
The path to the source file or directory.
ContainerPath (string) --
The mount path on the container. If this property isn't set, the instance path is used.
AccessLevel (string) --
The type of access for the container.
EnvironmentOverride (list) --
A set of environment variables that's passed to the container on startup. See the ContainerDefinition::environment parameter in the Amazon Elastic Container Service API Reference.
(dict) --
An environment variable to set inside a container, in the form of a key-value pair.
Part of: GameServerContainerDefinition, GameServerContainerDefinitionInput, SupportContainerDefinition, SupportContainerDefinitionInput
Name (string) --
The environment variable name.
Value (string) --
The environment variable value.
ImageUri (string) --
The URI to the image that Amazon GameLift uses when deploying this container to a container fleet. For a more specific identifier, see ResolvedImageDigest.
PortConfiguration (dict) --
The set of ports that are available to bind to processes in the container. For example, a game server process requires a container port to allow game clients to connect to it. Container ports aren't directly accessed by inbound traffic. Amazon GameLift maps these container ports to externally accessible connection ports, which are assigned as needed from the container fleet's ConnectionPortRange.
ContainerPortRanges (list) --
A set of one or more container port number ranges. The ranges can't overlap.
(dict) --
A set of one or more port numbers that can be opened on the container.
Part of: ContainerPortConfiguration
FromPort (integer) --
A starting value for the range of allowed port numbers.
ToPort (integer) --
An ending value for the range of allowed port numbers. Port numbers are end-inclusive. This value must be equal to or greater than FromPort.
Protocol (string) --
The network protocol that these ports support.
ResolvedImageDigest (string) --
A unique and immutable identifier for the container image. The digest is a SHA 256 hash of the container image manifest.
ServerSdkVersion (string) --
The Amazon GameLift server SDK version that the game server is integrated with. Only game servers using 5.2.0 or higher are compatible with container fleets.
SupportContainerDefinitions (list) --
The set of definitions for support containers in this group. A container group definition might have zero support container definitions. Support container can be used in any type of container group.
(dict) --
Describes a support container in a container group. A support container might be in a game server container group or a per-instance container group. Support containers don't run game server processes.
You can update a support container definition and deploy the updates to an existing fleet. When creating or updating a game server container group definition, use the property GameServerContainerDefinitionInput.
Part of: ContainerGroupDefinition
Returned by: DescribeContainerGroupDefinition, ListContainerGroupDefinitions, UpdateContainerGroupDefinition
ContainerName (string) --
The container definition identifier. Container names are unique within a container group definition.
DependsOn (list) --
Indicates that the container relies on the status of other containers in the same container group during its startup and shutdown sequences. A container might have dependencies on multiple containers.
(dict) --
A container's dependency on another container in the same container group. The dependency impacts how the dependent container is able to start or shut down based the status of the other container.
For example, ContainerA is configured with the following dependency: a START dependency on ContainerB. This means that ContainerA can't start until ContainerB has started. It also means that ContainerA must shut down before ContainerB.
eiifcbfhgrdurhnucnufkgbnbnnerrvbtjvljdetkehc**Part of:** GameServerContainerDefinition, GameServerContainerDefinitionInput, SupportContainerDefinition, SupportContainerDefinitionInput
ContainerName (string) --
A descriptive label for the container definition that this container depends on.
Condition (string) --
The condition that the dependency container must reach before the dependent container can start. Valid conditions include:
START - The dependency container must have started.
COMPLETE - The dependency container has run to completion (exits). Use this condition with nonessential containers, such as those that run a script and then exit. The dependency container can't be an essential container.
SUCCESS - The dependency container has run to completion and exited with a zero status. The dependency container can't be an essential container.
HEALTHY - The dependency container has passed its Docker health check. Use this condition with dependency containers that have health checks configured. This condition is confirmed at container group startup only.
MountPoints (list) --
A mount point that binds a path inside the container to a file or directory on the host system and lets it access the file or directory.
(dict) --
A mount point that binds a container to a file or directory on the host system.
Part of: GameServerContainerDefinition, GameServerContainerDefinitionInput, SupportContainerDefinition, SupportContainerDefinitionInput
InstancePath (string) --
The path to the source file or directory.
ContainerPath (string) --
The mount path on the container. If this property isn't set, the instance path is used.
AccessLevel (string) --
The type of access for the container.
EnvironmentOverride (list) --
A set of environment variables that's passed to the container on startup. See the ContainerDefinition::environment parameter in the Amazon Elastic Container Service API Reference.
(dict) --
An environment variable to set inside a container, in the form of a key-value pair.
Part of: GameServerContainerDefinition, GameServerContainerDefinitionInput, SupportContainerDefinition, SupportContainerDefinitionInput
Name (string) --
The environment variable name.
Value (string) --
The environment variable value.
Essential (boolean) --
Indicates whether the container is vital to the container group. If an essential container fails, the entire container group restarts.
HealthCheck (dict) --
A configuration for a non-terminal health check. A support container automatically restarts if it stops functioning or if it fails this health check.
Command (list) --
A string array that specifies the command that the container runs to determine if it's healthy.
(string) --
Interval (integer) --
The time period (in seconds) between each health check.
Retries (integer) --
The number of times to retry a failed health check before flagging the container unhealthy. The first run of the command does not count as a retry.
StartPeriod (integer) --
The optional grace period (in seconds) to give a container time to bootstrap before the first failed health check counts toward the number of retries.
Timeout (integer) --
The time period (in seconds) to wait for a health check to succeed before counting a failed health check.
ImageUri (string) --
The URI to the image that Amazon GameLift deploys to a container fleet. For a more specific identifier, see ResolvedImageDigest.
MemoryHardLimitMebibytes (integer) --
The amount of memory that Amazon GameLift makes available to the container. If memory limits aren't set for an individual container, the container shares the container group's total memory allocation.
Related data type: ContainerGroupDefinition$TotalMemoryLimitMebibytes
PortConfiguration (dict) --
A set of ports that allow access to the container from external users. Processes running in the container can bind to a one of these ports. Container ports aren't directly accessed by inbound traffic. Amazon GameLift maps these container ports to externally accessible connection ports, which are assigned as needed from the container fleet's ConnectionPortRange.
ContainerPortRanges (list) --
A set of one or more container port number ranges. The ranges can't overlap.
(dict) --
A set of one or more port numbers that can be opened on the container.
Part of: ContainerPortConfiguration
FromPort (integer) --
A starting value for the range of allowed port numbers.
ToPort (integer) --
An ending value for the range of allowed port numbers. Port numbers are end-inclusive. This value must be equal to or greater than FromPort.
Protocol (string) --
The network protocol that these ports support.
ResolvedImageDigest (string) --
A unique and immutable identifier for the container image. The digest is a SHA 256 hash of the container image manifest.
Vcpu (float) --
The number of vCPU units that are reserved for the container. If no resources are reserved, the container shares the total vCPU limit for the container group.
Related data type: ContainerGroupDefinition$TotalVcpuLimit
VersionNumber (integer) --
Indicates the version of a particular container group definition. This number is incremented automatically when you update a container group definition. You can view, update, or delete individual versions or the entire container group definition.
VersionDescription (string) --
An optional description that was provided for a container group definition update. Each version can have a unique description.
Status (string) --
Current status of the container group definition resource. Values include:
COPYING -- Amazon GameLift is in the process of making copies of all container images that are defined in the group. While in this state, the resource can't be used to create a container fleet.
READY -- Amazon GameLift has copied the registry images for all containers that are defined in the group. You can use a container group definition in this status to create a container fleet.
FAILED -- Amazon GameLift failed to create a valid container group definition resource. For more details on the cause of the failure, see StatusReason. A container group definition resource in failed status will be deleted within a few minutes.
StatusReason (string) --
Additional information about a container group definition that's in FAILED status. Possible reasons include:
An internal issue prevented Amazon GameLift from creating the container group definition resource. Delete the failed resource and call CreateContainerGroupDefinitionagain.
An access-denied message means that you don't have permissions to access the container image on ECR. See IAM permission examples for help setting up required IAM permissions for Amazon GameLift.
The ImageUri value for at least one of the containers in the container group definition was invalid or not found in the current Amazon Web Services account.
At least one of the container images referenced in the container group definition exceeds the allowed size. For size limits, see Amazon GameLift endpoints and quotas.
At least one of the container images referenced in the container group definition uses a different operating system than the one defined for the container group.
{'FleetCapacity': {'GameServerContainerGroupCounts': {'ACTIVE': 'integer', 'IDLE': 'integer', 'PENDING': 'integer', 'TERMINATING': 'integer'}}}
Retrieves the resource capacity settings for one or more fleets. For a container fleet, this operation also returns counts for game server container groups.
With multi-location fleets, this operation retrieves data for the fleet's home Region only. To retrieve capacity for remote locations, see DescribeFleetLocationCapacity.
This operation can be used in the following ways:
To get capacity data for one or more specific fleets, provide a list of fleet IDs or fleet ARNs.
To get capacity data for all fleets, do not provide a fleet identifier.
When requesting multiple fleets, use the pagination parameters to retrieve results as a set of sequential pages.
If successful, a FleetCapacity object is returned for each requested fleet ID. Each FleetCapacity object includes a Location property, which is set to the fleet's home Region. Capacity values are returned only for fleets that currently exist.
Learn more
See also: AWS API Documentation
Request Syntax
client.describe_fleet_capacity( FleetIds=[ 'string', ], Limit=123, NextToken='string' )
list
A unique identifier for the fleet to retrieve capacity information for. You can use either the fleet ID or ARN value. Leave this parameter empty to retrieve capacity information for all fleets.
(string) --
integer
The maximum number of results to return. Use this parameter with NextToken to get results as a set of sequential pages. This parameter is ignored when the request specifies one or a list of fleet IDs.
string
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. This parameter is ignored when the request specifies one or a list of fleet IDs.
dict
Response Syntax
{ 'FleetCapacity': [ { 'FleetId': 'string', 'FleetArn': 'string', 'InstanceType': 't2.micro'|'t2.small'|'t2.medium'|'t2.large'|'c3.large'|'c3.xlarge'|'c3.2xlarge'|'c3.4xlarge'|'c3.8xlarge'|'c4.large'|'c4.xlarge'|'c4.2xlarge'|'c4.4xlarge'|'c4.8xlarge'|'c5.large'|'c5.xlarge'|'c5.2xlarge'|'c5.4xlarge'|'c5.9xlarge'|'c5.12xlarge'|'c5.18xlarge'|'c5.24xlarge'|'c5a.large'|'c5a.xlarge'|'c5a.2xlarge'|'c5a.4xlarge'|'c5a.8xlarge'|'c5a.12xlarge'|'c5a.16xlarge'|'c5a.24xlarge'|'r3.large'|'r3.xlarge'|'r3.2xlarge'|'r3.4xlarge'|'r3.8xlarge'|'r4.large'|'r4.xlarge'|'r4.2xlarge'|'r4.4xlarge'|'r4.8xlarge'|'r4.16xlarge'|'r5.large'|'r5.xlarge'|'r5.2xlarge'|'r5.4xlarge'|'r5.8xlarge'|'r5.12xlarge'|'r5.16xlarge'|'r5.24xlarge'|'r5a.large'|'r5a.xlarge'|'r5a.2xlarge'|'r5a.4xlarge'|'r5a.8xlarge'|'r5a.12xlarge'|'r5a.16xlarge'|'r5a.24xlarge'|'m3.medium'|'m3.large'|'m3.xlarge'|'m3.2xlarge'|'m4.large'|'m4.xlarge'|'m4.2xlarge'|'m4.4xlarge'|'m4.10xlarge'|'m5.large'|'m5.xlarge'|'m5.2xlarge'|'m5.4xlarge'|'m5.8xlarge'|'m5.12xlarge'|'m5.16xlarge'|'m5.24xlarge'|'m5a.large'|'m5a.xlarge'|'m5a.2xlarge'|'m5a.4xlarge'|'m5a.8xlarge'|'m5a.12xlarge'|'m5a.16xlarge'|'m5a.24xlarge'|'c5d.large'|'c5d.xlarge'|'c5d.2xlarge'|'c5d.4xlarge'|'c5d.9xlarge'|'c5d.12xlarge'|'c5d.18xlarge'|'c5d.24xlarge'|'c6a.large'|'c6a.xlarge'|'c6a.2xlarge'|'c6a.4xlarge'|'c6a.8xlarge'|'c6a.12xlarge'|'c6a.16xlarge'|'c6a.24xlarge'|'c6i.large'|'c6i.xlarge'|'c6i.2xlarge'|'c6i.4xlarge'|'c6i.8xlarge'|'c6i.12xlarge'|'c6i.16xlarge'|'c6i.24xlarge'|'r5d.large'|'r5d.xlarge'|'r5d.2xlarge'|'r5d.4xlarge'|'r5d.8xlarge'|'r5d.12xlarge'|'r5d.16xlarge'|'r5d.24xlarge'|'m6g.medium'|'m6g.large'|'m6g.xlarge'|'m6g.2xlarge'|'m6g.4xlarge'|'m6g.8xlarge'|'m6g.12xlarge'|'m6g.16xlarge'|'c6g.medium'|'c6g.large'|'c6g.xlarge'|'c6g.2xlarge'|'c6g.4xlarge'|'c6g.8xlarge'|'c6g.12xlarge'|'c6g.16xlarge'|'r6g.medium'|'r6g.large'|'r6g.xlarge'|'r6g.2xlarge'|'r6g.4xlarge'|'r6g.8xlarge'|'r6g.12xlarge'|'r6g.16xlarge'|'c6gn.medium'|'c6gn.large'|'c6gn.xlarge'|'c6gn.2xlarge'|'c6gn.4xlarge'|'c6gn.8xlarge'|'c6gn.12xlarge'|'c6gn.16xlarge'|'c7g.medium'|'c7g.large'|'c7g.xlarge'|'c7g.2xlarge'|'c7g.4xlarge'|'c7g.8xlarge'|'c7g.12xlarge'|'c7g.16xlarge'|'r7g.medium'|'r7g.large'|'r7g.xlarge'|'r7g.2xlarge'|'r7g.4xlarge'|'r7g.8xlarge'|'r7g.12xlarge'|'r7g.16xlarge'|'m7g.medium'|'m7g.large'|'m7g.xlarge'|'m7g.2xlarge'|'m7g.4xlarge'|'m7g.8xlarge'|'m7g.12xlarge'|'m7g.16xlarge'|'g5g.xlarge'|'g5g.2xlarge'|'g5g.4xlarge'|'g5g.8xlarge'|'g5g.16xlarge', 'InstanceCounts': { 'DESIRED': 123, 'MINIMUM': 123, 'MAXIMUM': 123, 'PENDING': 123, 'ACTIVE': 123, 'IDLE': 123, 'TERMINATING': 123 }, 'Location': 'string', 'GameServerContainerGroupCounts': { 'PENDING': 123, 'ACTIVE': 123, 'IDLE': 123, 'TERMINATING': 123 } }, ], 'NextToken': 'string' }
Response Structure
(dict) --
FleetCapacity (list) --
A collection of objects that contains capacity information for each requested fleet ID. Capacity objects are returned only for fleets that currently exist. Changes in desired instance value can take up to 1 minute to be reflected.
(dict) --
Current resource capacity settings for managed EC2 fleets and managed container fleets. For multi-location fleets, location values might refer to a fleet's remote location or its home Region.
Returned by: DescribeFleetCapacity, DescribeFleetLocationCapacity, UpdateFleetCapacity
FleetId (string) --
A unique identifier for the fleet associated with the location.
FleetArn (string) --
The Amazon Resource Name ( ARN) that is assigned to a Amazon GameLift fleet resource and uniquely identifies it. ARNs are unique across all Regions. Format is arn:aws:gamelift:<region>::fleet/fleet-a1234567-b8c9-0d1e-2fa3-b45c6d7e8912.
InstanceType (string) --
The Amazon EC2 instance type that is used for instances in a fleet. Instance type determines the computing resources in use, including CPU, memory, storage, and networking capacity. See Amazon Elastic Compute Cloud Instance Types for detailed descriptions.
InstanceCounts (dict) --
The current number of instances in the fleet, listed by instance status. Counts for pending and terminating instances might be non-zero if the fleet is adjusting to a scaling event or if access to resources is temporarily affected.
DESIRED (integer) --
Requested number of active instances. Amazon GameLift takes action as needed to maintain the desired number of instances. Capacity is scaled up or down by changing the desired instances. A change in the desired instances value can take up to 1 minute to be reflected when viewing a fleet's capacity settings.
MINIMUM (integer) --
The minimum instance count value allowed.
MAXIMUM (integer) --
The maximum instance count value allowed.
PENDING (integer) --
Number of instances that are starting but not yet active.
ACTIVE (integer) --
Actual number of instances that are ready to host game sessions.
IDLE (integer) --
Number of active instances that are not currently hosting a game session.
TERMINATING (integer) --
Number of instances that are no longer active but haven't yet been terminated.
Location (string) --
The fleet location for the instance count information, expressed as an Amazon Web Services Region code, such as us-west-2.
GameServerContainerGroupCounts (dict) --
The number and status of game server container groups deployed in a container fleet.
PENDING (integer) --
The number of container groups that are starting up but haven't yet registered.
ACTIVE (integer) --
The number of container groups that have active game sessions.
IDLE (integer) --
The number of container groups that have no active game sessions.
TERMINATING (integer) --
The number of container groups that are in the process of shutting down.
NextToken (string) --
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.
{'Events': {'EventCode': {'COMPUTE_LOG_UPLOAD_FAILED', 'FLEET_STATE_CREATED', 'FLEET_STATE_CREATING', 'FLEET_STATE_PENDING', 'FLEET_STATE_UPDATING', 'GAME_SERVER_CONTAINER_GROUP_CRASHED', 'GAME_SERVER_CONTAINER_GROUP_REPLACED_UNHEALTHY', 'INSTANCE_REPLACED_UNHEALTHY', 'LOCATION_STATE_ACTIVATING', 'LOCATION_STATE_ACTIVE', 'LOCATION_STATE_CREATED', 'LOCATION_STATE_CREATING', 'LOCATION_STATE_DELETED', 'LOCATION_STATE_DELETING', 'LOCATION_STATE_ERROR', 'LOCATION_STATE_PENDING', 'LOCATION_STATE_UPDATING', 'PER_INSTANCE_CONTAINER_GROUP_CRASHED', 'SERVER_PROCESS_MISCONFIGURED_CONTAINER_PORT', 'SERVER_PROCESS_SDK_INITIALIZATION_FAILED'}}}
Retrieves entries from a fleet's event log. Fleet events are initiated by changes in status, such as during fleet creation and termination, changes in capacity, etc. If a fleet has multiple locations, events are also initiated by changes to status and capacity in remote locations.
You can specify a time range to limit the result set. Use the pagination parameters to retrieve results as a set of sequential pages.
If successful, a collection of event log entries matching the request are returned.
Learn more
See also: AWS API Documentation
Request Syntax
client.describe_fleet_events( FleetId='string', StartTime=datetime(2015, 1, 1), EndTime=datetime(2015, 1, 1), Limit=123, NextToken='string' )
string
[REQUIRED]
A unique identifier for the fleet to get event logs for. You can use either the fleet ID or ARN value.
datetime
The earliest date to retrieve event logs for. If no start time is specified, this call returns entries starting from when the fleet was created to the specified end time. Format is a number expressed in Unix time as milliseconds (ex: "1469498468.057").
datetime
The most recent date to retrieve event logs for. If no end time is specified, this call returns entries from the specified start time up to the present. Format is a number expressed in Unix time as milliseconds (ex: "1469498468.057").
integer
The maximum number of results to return. Use this parameter with NextToken to get results as a set of sequential pages.
string
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.
dict
Response Syntax
{ 'Events': [ { 'EventId': 'string', 'ResourceId': 'string', 'EventCode': 'GENERIC_EVENT'|'FLEET_CREATED'|'FLEET_DELETED'|'FLEET_SCALING_EVENT'|'FLEET_STATE_DOWNLOADING'|'FLEET_STATE_VALIDATING'|'FLEET_STATE_BUILDING'|'FLEET_STATE_ACTIVATING'|'FLEET_STATE_ACTIVE'|'FLEET_STATE_ERROR'|'FLEET_STATE_PENDING'|'FLEET_STATE_CREATING'|'FLEET_STATE_CREATED'|'FLEET_STATE_UPDATING'|'FLEET_INITIALIZATION_FAILED'|'FLEET_BINARY_DOWNLOAD_FAILED'|'FLEET_VALIDATION_LAUNCH_PATH_NOT_FOUND'|'FLEET_VALIDATION_EXECUTABLE_RUNTIME_FAILURE'|'FLEET_VALIDATION_TIMED_OUT'|'FLEET_ACTIVATION_FAILED'|'FLEET_ACTIVATION_FAILED_NO_INSTANCES'|'FLEET_NEW_GAME_SESSION_PROTECTION_POLICY_UPDATED'|'SERVER_PROCESS_INVALID_PATH'|'SERVER_PROCESS_SDK_INITIALIZATION_TIMEOUT'|'SERVER_PROCESS_PROCESS_READY_TIMEOUT'|'SERVER_PROCESS_CRASHED'|'SERVER_PROCESS_TERMINATED_UNHEALTHY'|'SERVER_PROCESS_FORCE_TERMINATED'|'SERVER_PROCESS_PROCESS_EXIT_TIMEOUT'|'SERVER_PROCESS_SDK_INITIALIZATION_FAILED'|'SERVER_PROCESS_MISCONFIGURED_CONTAINER_PORT'|'GAME_SESSION_ACTIVATION_TIMEOUT'|'FLEET_CREATION_EXTRACTING_BUILD'|'FLEET_CREATION_RUNNING_INSTALLER'|'FLEET_CREATION_VALIDATING_RUNTIME_CONFIG'|'FLEET_VPC_PEERING_SUCCEEDED'|'FLEET_VPC_PEERING_FAILED'|'FLEET_VPC_PEERING_DELETED'|'INSTANCE_INTERRUPTED'|'INSTANCE_RECYCLED'|'INSTANCE_REPLACED_UNHEALTHY'|'FLEET_CREATION_COMPLETED_INSTALLER'|'FLEET_CREATION_FAILED_INSTALLER'|'COMPUTE_LOG_UPLOAD_FAILED'|'GAME_SERVER_CONTAINER_GROUP_CRASHED'|'PER_INSTANCE_CONTAINER_GROUP_CRASHED'|'GAME_SERVER_CONTAINER_GROUP_REPLACED_UNHEALTHY'|'LOCATION_STATE_PENDING'|'LOCATION_STATE_CREATING'|'LOCATION_STATE_CREATED'|'LOCATION_STATE_ACTIVATING'|'LOCATION_STATE_ACTIVE'|'LOCATION_STATE_UPDATING'|'LOCATION_STATE_ERROR'|'LOCATION_STATE_DELETING'|'LOCATION_STATE_DELETED', 'Message': 'string', 'EventTime': datetime(2015, 1, 1), 'PreSignedLogUrl': 'string', 'Count': 123 }, ], 'NextToken': 'string' }
Response Structure
(dict) --
Events (list) --
A collection of objects containing event log entries for the specified fleet.
(dict) --
Log entry describing an event that involves Amazon GameLift resources (such as a fleet). In addition to tracking activity, event codes and messages can provide additional information for troubleshooting and debugging problems.
EventId (string) --
A unique identifier for a fleet event.
ResourceId (string) --
A unique identifier for an event resource, such as a fleet ID.
EventCode (string) --
The type of event being logged.
Fleet state transition events:
FLEET_CREATED -- A fleet resource was successfully created with a status of NEW. Event messaging includes the fleet ID.
FLEET_STATE_DOWNLOADING -- Fleet status changed from NEW to DOWNLOADING. Amazon GameLift is downloading the compressed build and running install scripts.
FLEET_STATE_VALIDATING -- Fleet status changed from DOWNLOADING to VALIDATING. Amazon GameLift has successfully installed build and is now validating the build files.
FLEET_STATE_BUILDING -- Fleet status changed from VALIDATING to BUILDING. Amazon GameLift has successfully verified the build files and is now launching a fleet instance.
FLEET_STATE_ACTIVATING -- Fleet status changed from BUILDING to ACTIVATING. Amazon GameLift is launching a game server process on the fleet instance and is testing its connectivity with the Amazon GameLift service.
FLEET_STATE_ACTIVE -- The fleet's status changed from ACTIVATING to ACTIVE. The fleet is now ready to host game sessions.
FLEET_STATE_ERROR -- The Fleet's status changed to ERROR. Describe the fleet event message for more details.
Fleet creation events (ordered by fleet creation activity):
FLEET_BINARY_DOWNLOAD_FAILED -- The build failed to download to the fleet instance.
FLEET_CREATION_EXTRACTING_BUILD -- The game server build was successfully downloaded to an instance, and Amazon GameLiftis now extracting the build files from the uploaded build. Failure at this stage prevents a fleet from moving to ACTIVE status. Logs for this stage display a list of the files that are extracted and saved on the instance. Access the logs by using the URL in PreSignedLogUrl.
FLEET_CREATION_RUNNING_INSTALLER -- The game server build files were successfully extracted, and Amazon GameLift is now running the build's install script (if one is included). Failure in this stage prevents a fleet from moving to ACTIVE status. Logs for this stage list the installation steps and whether or not the install completed successfully. Access the logs by using the URL in PreSignedLogUrl.
FLEET_CREATION_COMPLETED_INSTALLER -- The game server build files were successfully installed and validation of the installation will begin soon.
FLEET_CREATION_FAILED_INSTALLER -- The installed failed while attempting to install the build files. This event indicates that the failure occurred before Amazon GameLift could start validation.
FLEET_CREATION_VALIDATING_RUNTIME_CONFIG -- The build process was successful, and the GameLift is now verifying that the game server launch paths, which are specified in the fleet's runtime configuration, exist. If any listed launch path exists, Amazon GameLift tries to launch a game server process and waits for the process to report ready. Failures in this stage prevent a fleet from moving to ACTIVE status. Logs for this stage list the launch paths in the runtime configuration and indicate whether each is found. Access the logs by using the URL in PreSignedLogUrl.
FLEET_VALIDATION_LAUNCH_PATH_NOT_FOUND -- Validation of the runtime configuration failed because the executable specified in a launch path does not exist on the instance.
FLEET_VALIDATION_EXECUTABLE_RUNTIME_FAILURE -- Validation of the runtime configuration failed because the executable specified in a launch path failed to run on the fleet instance.
FLEET_VALIDATION_TIMED_OUT -- Validation of the fleet at the end of creation timed out. Try fleet creation again.
FLEET_ACTIVATION_FAILED -- The fleet failed to successfully complete one of the steps in the fleet activation process. This event code indicates that the game build was successfully downloaded to a fleet instance, built, and validated, but was not able to start a server process. For more information, see Debug Fleet Creation Issues.
FLEET_ACTIVATION_FAILED_NO_INSTANCES -- Fleet creation was not able to obtain any instances based on the input fleet attributes. Try again at a different time or choose a different combination of fleet attributes such as fleet type, instance type, etc.
FLEET_INITIALIZATION_FAILED -- A generic exception occurred during fleet creation. Describe the fleet event message for more details.
VPC peering events:
FLEET_VPC_PEERING_SUCCEEDED -- A VPC peering connection has been established between the VPC for an Amazon GameLift fleet and a VPC in your Amazon Web Services account.
FLEET_VPC_PEERING_FAILED -- A requested VPC peering connection has failed. Event details and status information provide additional detail. A common reason for peering failure is that the two VPCs have overlapping CIDR blocks of IPv4 addresses. To resolve this, change the CIDR block for the VPC in your Amazon Web Services account. For more information on VPC peering failures, see https://docs.aws.amazon.com/AmazonVPC/latest/PeeringGuide/invalid-peering-configurations.html
FLEET_VPC_PEERING_DELETED -- A VPC peering connection has been successfully deleted.
Container group events:
CONTAINER_GROUP_REGISTRATION_FAILED – A game server container group started, but timed out before calling RegisterCompute.
CONTAINER_GROUP_CRASHED A game server container group started and terminated without calling RegisterCompute.
Spot instance events:
INSTANCE_INTERRUPTED -- A spot instance was interrupted by EC2 with a two-minute notification.
INSTANCE_RECYCLED -- A spot instance was determined to have a high risk of interruption and is scheduled to be recycled once it has no active game sessions.
Server process events:
SERVER_PROCESS_INVALID_PATH -- The game server executable or script could not be found based on the Fleet runtime configuration. Check that the launch path is correct based on the operating system of the Fleet.
SERVER_PROCESS_SDK_INITIALIZATION_TIMEOUT -- The server process did not call InitSDK() within the time expected (5 minutes). Check your game session log to see why InitSDK() was not called in time.
SERVER_PROCESS_PROCESS_READY_TIMEOUT -- The server process did not call ProcessReady() within the time expected (5 minutes) after calling InitSDK(). Check your game session log to see why ProcessReady() was not called in time.
SERVER_PROCESS_CRASHED -- The server process exited without calling ProcessEnding(). Check your game session log to see why ProcessEnding() was not called.
SERVER_PROCESS_TERMINATED_UNHEALTHY -- The server process did not report a valid health check for too long and was therefore terminated by GameLift. Check your game session log to see if the thread became stuck processing a synchronous task for too long.
SERVER_PROCESS_FORCE_TERMINATED -- The server process did not exit cleanly within the time expected after OnProcessTerminate() was sent. Check your game session log to see why termination took longer than expected.
SERVER_PROCESS_PROCESS_EXIT_TIMEOUT -- The server process did not exit cleanly within the time expected (30 seconds) after calling ProcessEnding(). Check your game session log to see why termination took longer than expected.
Game session events:
GAME_SESSION_ACTIVATION_TIMEOUT -- GameSession failed to activate within the expected time. Check your game session log to see why ActivateGameSession() took longer to complete than expected.
Other fleet events:
FLEET_SCALING_EVENT -- A change was made to the fleet's capacity settings (desired instances, minimum/maximum scaling limits). Event messaging includes the new capacity settings.
FLEET_NEW_GAME_SESSION_PROTECTION_POLICY_UPDATED -- A change was made to the fleet's game session protection policy setting. Event messaging includes both the old and new policy setting.
FLEET_DELETED -- A request to delete a fleet was initiated.
GENERIC_EVENT -- An unspecified event has occurred.
Message (string) --
Additional information related to the event.
EventTime (datetime) --
Time stamp indicating when this event occurred. Format is a number expressed in Unix time as milliseconds (for example "1469498468.057").
PreSignedLogUrl (string) --
Location of stored logs with additional detail that is related to the event. This is useful for debugging issues. The URL is valid for 15 minutes. You can also access fleet creation logs through the Amazon GameLift console.
Count (integer) --
The number of times that this event occurred.
NextToken (string) --
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.
{'FleetCapacity': {'GameServerContainerGroupCounts': {'ACTIVE': 'integer', 'IDLE': 'integer', 'PENDING': 'integer', 'TERMINATING': 'integer'}}}
Retrieves the resource capacity settings for a fleet location. The data returned includes the current capacity (number of EC2 instances) and some scaling settings for the requested fleet location. For a managed container fleet, this operation also returns counts for game server container groups.
Use this operation to retrieve capacity information for a fleet's remote location or home Region (you can also retrieve home Region capacity by calling DescribeFleetCapacity).
To retrieve capacity data, identify a fleet and location.
If successful, a FleetCapacity object is returned for the requested fleet location.
Learn more
Setting up Amazon GameLift fleets
Amazon GameLift service locations for managed hosting
See also: AWS API Documentation
Request Syntax
client.describe_fleet_location_capacity( FleetId='string', Location='string' )
string
[REQUIRED]
A unique identifier for the fleet to request location capacity for. You can use either the fleet ID or ARN value.
string
[REQUIRED]
The fleet location to retrieve capacity information for. Specify a location in the form of an Amazon Web Services Region code, such as us-west-2.
dict
Response Syntax
{ 'FleetCapacity': { 'FleetId': 'string', 'FleetArn': 'string', 'InstanceType': 't2.micro'|'t2.small'|'t2.medium'|'t2.large'|'c3.large'|'c3.xlarge'|'c3.2xlarge'|'c3.4xlarge'|'c3.8xlarge'|'c4.large'|'c4.xlarge'|'c4.2xlarge'|'c4.4xlarge'|'c4.8xlarge'|'c5.large'|'c5.xlarge'|'c5.2xlarge'|'c5.4xlarge'|'c5.9xlarge'|'c5.12xlarge'|'c5.18xlarge'|'c5.24xlarge'|'c5a.large'|'c5a.xlarge'|'c5a.2xlarge'|'c5a.4xlarge'|'c5a.8xlarge'|'c5a.12xlarge'|'c5a.16xlarge'|'c5a.24xlarge'|'r3.large'|'r3.xlarge'|'r3.2xlarge'|'r3.4xlarge'|'r3.8xlarge'|'r4.large'|'r4.xlarge'|'r4.2xlarge'|'r4.4xlarge'|'r4.8xlarge'|'r4.16xlarge'|'r5.large'|'r5.xlarge'|'r5.2xlarge'|'r5.4xlarge'|'r5.8xlarge'|'r5.12xlarge'|'r5.16xlarge'|'r5.24xlarge'|'r5a.large'|'r5a.xlarge'|'r5a.2xlarge'|'r5a.4xlarge'|'r5a.8xlarge'|'r5a.12xlarge'|'r5a.16xlarge'|'r5a.24xlarge'|'m3.medium'|'m3.large'|'m3.xlarge'|'m3.2xlarge'|'m4.large'|'m4.xlarge'|'m4.2xlarge'|'m4.4xlarge'|'m4.10xlarge'|'m5.large'|'m5.xlarge'|'m5.2xlarge'|'m5.4xlarge'|'m5.8xlarge'|'m5.12xlarge'|'m5.16xlarge'|'m5.24xlarge'|'m5a.large'|'m5a.xlarge'|'m5a.2xlarge'|'m5a.4xlarge'|'m5a.8xlarge'|'m5a.12xlarge'|'m5a.16xlarge'|'m5a.24xlarge'|'c5d.large'|'c5d.xlarge'|'c5d.2xlarge'|'c5d.4xlarge'|'c5d.9xlarge'|'c5d.12xlarge'|'c5d.18xlarge'|'c5d.24xlarge'|'c6a.large'|'c6a.xlarge'|'c6a.2xlarge'|'c6a.4xlarge'|'c6a.8xlarge'|'c6a.12xlarge'|'c6a.16xlarge'|'c6a.24xlarge'|'c6i.large'|'c6i.xlarge'|'c6i.2xlarge'|'c6i.4xlarge'|'c6i.8xlarge'|'c6i.12xlarge'|'c6i.16xlarge'|'c6i.24xlarge'|'r5d.large'|'r5d.xlarge'|'r5d.2xlarge'|'r5d.4xlarge'|'r5d.8xlarge'|'r5d.12xlarge'|'r5d.16xlarge'|'r5d.24xlarge'|'m6g.medium'|'m6g.large'|'m6g.xlarge'|'m6g.2xlarge'|'m6g.4xlarge'|'m6g.8xlarge'|'m6g.12xlarge'|'m6g.16xlarge'|'c6g.medium'|'c6g.large'|'c6g.xlarge'|'c6g.2xlarge'|'c6g.4xlarge'|'c6g.8xlarge'|'c6g.12xlarge'|'c6g.16xlarge'|'r6g.medium'|'r6g.large'|'r6g.xlarge'|'r6g.2xlarge'|'r6g.4xlarge'|'r6g.8xlarge'|'r6g.12xlarge'|'r6g.16xlarge'|'c6gn.medium'|'c6gn.large'|'c6gn.xlarge'|'c6gn.2xlarge'|'c6gn.4xlarge'|'c6gn.8xlarge'|'c6gn.12xlarge'|'c6gn.16xlarge'|'c7g.medium'|'c7g.large'|'c7g.xlarge'|'c7g.2xlarge'|'c7g.4xlarge'|'c7g.8xlarge'|'c7g.12xlarge'|'c7g.16xlarge'|'r7g.medium'|'r7g.large'|'r7g.xlarge'|'r7g.2xlarge'|'r7g.4xlarge'|'r7g.8xlarge'|'r7g.12xlarge'|'r7g.16xlarge'|'m7g.medium'|'m7g.large'|'m7g.xlarge'|'m7g.2xlarge'|'m7g.4xlarge'|'m7g.8xlarge'|'m7g.12xlarge'|'m7g.16xlarge'|'g5g.xlarge'|'g5g.2xlarge'|'g5g.4xlarge'|'g5g.8xlarge'|'g5g.16xlarge', 'InstanceCounts': { 'DESIRED': 123, 'MINIMUM': 123, 'MAXIMUM': 123, 'PENDING': 123, 'ACTIVE': 123, 'IDLE': 123, 'TERMINATING': 123 }, 'Location': 'string', 'GameServerContainerGroupCounts': { 'PENDING': 123, 'ACTIVE': 123, 'IDLE': 123, 'TERMINATING': 123 } } }
Response Structure
(dict) --
FleetCapacity (dict) --
Resource capacity information for the requested fleet location. Capacity objects are returned only for fleets and locations that currently exist. Changes in desired instance value can take up to 1 minute to be reflected.
FleetId (string) --
A unique identifier for the fleet associated with the location.
FleetArn (string) --
The Amazon Resource Name ( ARN) that is assigned to a Amazon GameLift fleet resource and uniquely identifies it. ARNs are unique across all Regions. Format is arn:aws:gamelift:<region>::fleet/fleet-a1234567-b8c9-0d1e-2fa3-b45c6d7e8912.
InstanceType (string) --
The Amazon EC2 instance type that is used for instances in a fleet. Instance type determines the computing resources in use, including CPU, memory, storage, and networking capacity. See Amazon Elastic Compute Cloud Instance Types for detailed descriptions.
InstanceCounts (dict) --
The current number of instances in the fleet, listed by instance status. Counts for pending and terminating instances might be non-zero if the fleet is adjusting to a scaling event or if access to resources is temporarily affected.
DESIRED (integer) --
Requested number of active instances. Amazon GameLift takes action as needed to maintain the desired number of instances. Capacity is scaled up or down by changing the desired instances. A change in the desired instances value can take up to 1 minute to be reflected when viewing a fleet's capacity settings.
MINIMUM (integer) --
The minimum instance count value allowed.
MAXIMUM (integer) --
The maximum instance count value allowed.
PENDING (integer) --
Number of instances that are starting but not yet active.
ACTIVE (integer) --
Actual number of instances that are ready to host game sessions.
IDLE (integer) --
Number of active instances that are not currently hosting a game session.
TERMINATING (integer) --
Number of instances that are no longer active but haven't yet been terminated.
Location (string) --
The fleet location for the instance count information, expressed as an Amazon Web Services Region code, such as us-west-2.
GameServerContainerGroupCounts (dict) --
The number and status of game server container groups deployed in a container fleet.
PENDING (integer) --
The number of container groups that are starting up but haven't yet registered.
ACTIVE (integer) --
The number of container groups that have active game sessions.
IDLE (integer) --
The number of container groups that have no active game sessions.
TERMINATING (integer) --
The number of container groups that are in the process of shutting down.
{'ContainerIdentifiers': [{'ContainerName': 'string', 'ContainerRuntimeId': 'string'}]}
Requests authorization to remotely connect to a hosting resource in a Amazon GameLift managed fleet. This operation is not used with Amazon GameLift Anywhere fleets.
Request options
To request access to a compute, specify the compute name and the fleet ID.
Results
If successful, this operation returns a set of temporary Amazon Web Services credentials, including a two-part access key and a session token.
With a managed EC2 fleet (where compute type is EC2), use these credentials with Amazon EC2 Systems Manager (SSM) to start a session with the compute. For more details, see Starting a session (CLI) in the Amazon EC2 Systems Manager User Guide.
See also: AWS API Documentation
Request Syntax
client.get_compute_access( FleetId='string', ComputeName='string' )
string
[REQUIRED]
A unique identifier for the fleet that holds the compute resource that you want to connect to. You can use either the fleet ID or ARN value.
string
[REQUIRED]
A unique identifier for the compute resource that you want to connect to. For an EC2 fleet compute, use the instance ID. Use ListCompute to retrieve compute identifiers.
dict
Response Syntax
{ 'FleetId': 'string', 'FleetArn': 'string', 'ComputeName': 'string', 'ComputeArn': 'string', 'Credentials': { 'AccessKeyId': 'string', 'SecretAccessKey': 'string', 'SessionToken': 'string' }, 'Target': 'string', 'ContainerIdentifiers': [ { 'ContainerName': 'string', 'ContainerRuntimeId': 'string' }, ] }
Response Structure
(dict) --
FleetId (string) --
The ID of the fleet that holds the compute resource to be accessed.
FleetArn (string) --
The Amazon Resource Name ( ARN) that is assigned to a Amazon GameLift fleet resource and uniquely identifies it. ARNs are unique across all Regions. Format is arn:aws:gamelift:<region>::fleet/fleet-a1234567-b8c9-0d1e-2fa3-b45c6d7e8912.
ComputeName (string) --
The identifier of the compute resource to be accessed. This value might be either a compute name or an instance ID.
ComputeArn (string) --
The Amazon Resource Name ( ARN) that is assigned to an Amazon GameLift compute resource and uniquely identifies it. ARNs are unique across all Regions. Format is arn:aws:gamelift:<region>::compute/compute-a1234567-b8c9-0d1e-2fa3-b45c6d7e8912.
Credentials (dict) --
A set of temporary Amazon Web Services credentials for use when connecting to the compute resource with Amazon EC2 Systems Manager (SSM).
AccessKeyId (string) --
The access key ID that identifies the temporary security credentials.
SecretAccessKey (string) --
The secret access key that can be used to sign requests.
SessionToken (string) --
The token that users must pass to the service API to use the temporary credentials.
Target (string) --
The instance ID where the compute resource is running.
ContainerIdentifiers (list) --
For a managed container fleet, a list of containers on the compute. Use the container runtime ID with Docker commands to connect to a specific container.
(dict) --
A unique identifier for a container in a compute on a managed container fleet instance. This information makes it possible to remotely connect to a specific container on a fleet instance.
Related to: ContainerAttribute
Use with: GetComputeAccess
ContainerName (string) --
The identifier for a container that's running in a compute.
ContainerRuntimeId (string) --
The runtime ID for the container that's running in a compute. This value is unique within the compute. It is returned as a ContainerAttribute value in a Compute object.
{'ComputeStatus': 'ACTIVE | IMPAIRED', 'ContainerGroupDefinitionName': 'string'}Response
{'ComputeList': {'ComputeStatus': {'IMPAIRED'}, 'GameServerContainerGroupDefinitionArn': 'string'}}
Retrieves information on the compute resources in an Amazon GameLift fleet. Use the pagination parameters to retrieve results in a set of sequential pages.
Request options:
Retrieve a list of all computes in a fleet. Specify a fleet ID.
Retrieve a list of all computes in a specific fleet location. Specify a fleet ID and location.
Results:
If successful, this operation returns information on a set of computes. Depending on the type of fleet, the result includes the following information:
For managed EC2 fleets (compute type EC2), this operation returns information about the EC2 instance. Compute names are EC2 instance IDs.
For Anywhere fleets (compute type ANYWHERE), this operation returns compute names and details as provided when the compute was registered with RegisterCompute. This includes GameLiftServiceSdkEndpoint or GameLiftAgentEndpoint.
See also: AWS API Documentation
Request Syntax
client.list_compute( FleetId='string', Location='string', ContainerGroupDefinitionName='string', ComputeStatus='ACTIVE'|'IMPAIRED', Limit=123, NextToken='string' )
string
[REQUIRED]
A unique identifier for the fleet to retrieve compute resources for.
string
The name of a location to retrieve compute resources for. For an Amazon GameLift Anywhere fleet, use a custom location. For a managed fleet, provide a Amazon Web Services Region or Local Zone code (for example: us-west-2 or us-west-2-lax-1).
string
For computes in a managed container fleet, the name of the deployed container group definition.
string
The status of computes in a managed container fleet, based on the success of the latest update deployment.
ACTIVE -- The compute is deployed with the correct container definitions. It is ready to process game servers and host game sessions.
IMPAIRED -- An update deployment to the compute failed, and the compute is deployed with incorrect container definitions.
integer
The maximum number of results to return. Use this parameter with NextToken to get results as a set of sequential pages.
string
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.
dict
Response Syntax
{ 'ComputeList': [ { 'FleetId': 'string', 'FleetArn': 'string', 'ComputeName': 'string', 'ComputeArn': 'string', 'IpAddress': 'string', 'DnsName': 'string', 'ComputeStatus': 'PENDING'|'ACTIVE'|'TERMINATING'|'IMPAIRED', 'Location': 'string', 'CreationTime': datetime(2015, 1, 1), 'OperatingSystem': 'WINDOWS_2012'|'AMAZON_LINUX'|'AMAZON_LINUX_2'|'WINDOWS_2016'|'AMAZON_LINUX_2023', 'Type': 't2.micro'|'t2.small'|'t2.medium'|'t2.large'|'c3.large'|'c3.xlarge'|'c3.2xlarge'|'c3.4xlarge'|'c3.8xlarge'|'c4.large'|'c4.xlarge'|'c4.2xlarge'|'c4.4xlarge'|'c4.8xlarge'|'c5.large'|'c5.xlarge'|'c5.2xlarge'|'c5.4xlarge'|'c5.9xlarge'|'c5.12xlarge'|'c5.18xlarge'|'c5.24xlarge'|'c5a.large'|'c5a.xlarge'|'c5a.2xlarge'|'c5a.4xlarge'|'c5a.8xlarge'|'c5a.12xlarge'|'c5a.16xlarge'|'c5a.24xlarge'|'r3.large'|'r3.xlarge'|'r3.2xlarge'|'r3.4xlarge'|'r3.8xlarge'|'r4.large'|'r4.xlarge'|'r4.2xlarge'|'r4.4xlarge'|'r4.8xlarge'|'r4.16xlarge'|'r5.large'|'r5.xlarge'|'r5.2xlarge'|'r5.4xlarge'|'r5.8xlarge'|'r5.12xlarge'|'r5.16xlarge'|'r5.24xlarge'|'r5a.large'|'r5a.xlarge'|'r5a.2xlarge'|'r5a.4xlarge'|'r5a.8xlarge'|'r5a.12xlarge'|'r5a.16xlarge'|'r5a.24xlarge'|'m3.medium'|'m3.large'|'m3.xlarge'|'m3.2xlarge'|'m4.large'|'m4.xlarge'|'m4.2xlarge'|'m4.4xlarge'|'m4.10xlarge'|'m5.large'|'m5.xlarge'|'m5.2xlarge'|'m5.4xlarge'|'m5.8xlarge'|'m5.12xlarge'|'m5.16xlarge'|'m5.24xlarge'|'m5a.large'|'m5a.xlarge'|'m5a.2xlarge'|'m5a.4xlarge'|'m5a.8xlarge'|'m5a.12xlarge'|'m5a.16xlarge'|'m5a.24xlarge'|'c5d.large'|'c5d.xlarge'|'c5d.2xlarge'|'c5d.4xlarge'|'c5d.9xlarge'|'c5d.12xlarge'|'c5d.18xlarge'|'c5d.24xlarge'|'c6a.large'|'c6a.xlarge'|'c6a.2xlarge'|'c6a.4xlarge'|'c6a.8xlarge'|'c6a.12xlarge'|'c6a.16xlarge'|'c6a.24xlarge'|'c6i.large'|'c6i.xlarge'|'c6i.2xlarge'|'c6i.4xlarge'|'c6i.8xlarge'|'c6i.12xlarge'|'c6i.16xlarge'|'c6i.24xlarge'|'r5d.large'|'r5d.xlarge'|'r5d.2xlarge'|'r5d.4xlarge'|'r5d.8xlarge'|'r5d.12xlarge'|'r5d.16xlarge'|'r5d.24xlarge'|'m6g.medium'|'m6g.large'|'m6g.xlarge'|'m6g.2xlarge'|'m6g.4xlarge'|'m6g.8xlarge'|'m6g.12xlarge'|'m6g.16xlarge'|'c6g.medium'|'c6g.large'|'c6g.xlarge'|'c6g.2xlarge'|'c6g.4xlarge'|'c6g.8xlarge'|'c6g.12xlarge'|'c6g.16xlarge'|'r6g.medium'|'r6g.large'|'r6g.xlarge'|'r6g.2xlarge'|'r6g.4xlarge'|'r6g.8xlarge'|'r6g.12xlarge'|'r6g.16xlarge'|'c6gn.medium'|'c6gn.large'|'c6gn.xlarge'|'c6gn.2xlarge'|'c6gn.4xlarge'|'c6gn.8xlarge'|'c6gn.12xlarge'|'c6gn.16xlarge'|'c7g.medium'|'c7g.large'|'c7g.xlarge'|'c7g.2xlarge'|'c7g.4xlarge'|'c7g.8xlarge'|'c7g.12xlarge'|'c7g.16xlarge'|'r7g.medium'|'r7g.large'|'r7g.xlarge'|'r7g.2xlarge'|'r7g.4xlarge'|'r7g.8xlarge'|'r7g.12xlarge'|'r7g.16xlarge'|'m7g.medium'|'m7g.large'|'m7g.xlarge'|'m7g.2xlarge'|'m7g.4xlarge'|'m7g.8xlarge'|'m7g.12xlarge'|'m7g.16xlarge'|'g5g.xlarge'|'g5g.2xlarge'|'g5g.4xlarge'|'g5g.8xlarge'|'g5g.16xlarge', 'GameLiftServiceSdkEndpoint': 'string', 'GameLiftAgentEndpoint': 'string', 'InstanceId': 'string', 'ContainerAttributes': [ { 'ContainerName': 'string', 'ContainerRuntimeId': 'string' }, ], 'GameServerContainerGroupDefinitionArn': 'string' }, ], 'NextToken': 'string' }
Response Structure
(dict) --
ComputeList (list) --
A list of compute resources in the specified fleet.
(dict) --
An Amazon GameLift compute resource for hosting your game servers. Computes in an Amazon GameLift fleet differs depending on the fleet's compute type property as follows:
For managed EC2 fleets, a compute is an EC2 instance.
For Anywhere fleets, a compute is a computing resource that you provide and is registered to the fleet.
FleetId (string) --
A unique identifier for the fleet that the compute belongs to.
FleetArn (string) --
The Amazon Resource Name (ARN) of the fleet that the compute belongs to.
ComputeName (string) --
A descriptive label for the compute resource. For instances in a managed EC2 fleet, the compute name is the same value as the InstanceId ID.
ComputeArn (string) --
The ARN that is assigned to a compute resource and uniquely identifies it. ARNs are unique across locations. Instances in managed EC2 fleets are not assigned a Compute ARN.
IpAddress (string) --
The IP address of a compute resource. Amazon GameLift requires a DNS name or IP address for a compute.
DnsName (string) --
The DNS name of a compute resource. Amazon GameLift requires a DNS name or IP address for a compute.
ComputeStatus (string) --
Current status of the compute. A compute must have an ACTIVE status to host game sessions.
Location (string) --
The name of the custom location you added to the fleet that this compute resource resides in.
CreationTime (datetime) --
A time stamp indicating when this data object was created. Format is a number expressed in Unix time as milliseconds (for example "1469498468.057").
OperatingSystem (string) --
The type of operating system on the compute resource.
Type (string) --
The Amazon EC2 instance type that the fleet uses. For registered computes in an Amazon GameLift Anywhere fleet, this property is empty.
GameLiftServiceSdkEndpoint (string) --
The Amazon GameLift SDK endpoint connection for a registered compute resource in an Anywhere fleet. The game servers on the compute use this endpoint to connect to the Amazon GameLift service.
GameLiftAgentEndpoint (string) --
The endpoint of the Amazon GameLift Agent.
InstanceId (string) --
The InstanceID of the EC2 instance that is hosting the compute.
ContainerAttributes (list) --
A set of attributes for each container in the compute.
(dict) --
A unique identifier for a container in a container fleet compute.
Returned by: DescribeCompute
ContainerName (string) --
The identifier for a container that's running in a compute.
ContainerRuntimeId (string) --
The runtime ID for the container that's running in a compute. This value is unique within the compute.
GameServerContainerGroupDefinitionArn (string) --
The game server container group definition for the compute.
NextToken (string) --
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.
{'ContainerGroupType': 'GAME_SERVER | PER_INSTANCE'}Response
{'ContainerGroupDefinitions': {'ContainerGroupType': 'GAME_SERVER | ' 'PER_INSTANCE', 'GameServerContainerDefinition': {'ContainerName': 'string', 'DependsOn': [{'Condition': 'START ' '| ' 'COMPLETE ' '| ' 'SUCCESS ' '| ' 'HEALTHY', 'ContainerName': 'string'}], 'EnvironmentOverride': [{'Name': 'string', 'Value': 'string'}], 'ImageUri': 'string', 'MountPoints': [{'AccessLevel': 'READ_ONLY ' '| ' 'READ_AND_WRITE', 'ContainerPath': 'string', 'InstancePath': 'string'}], 'PortConfiguration': {'ContainerPortRanges': [{'FromPort': 'integer', 'Protocol': 'TCP ' '| ' 'UDP', 'ToPort': 'integer'}]}, 'ResolvedImageDigest': 'string', 'ServerSdkVersion': 'string'}, 'SupportContainerDefinitions': [{'ContainerName': 'string', 'DependsOn': [{'Condition': 'START ' '| ' 'COMPLETE ' '| ' 'SUCCESS ' '| ' 'HEALTHY', 'ContainerName': 'string'}], 'EnvironmentOverride': [{'Name': 'string', 'Value': 'string'}], 'Essential': 'boolean', 'HealthCheck': {'Command': ['string'], 'Interval': 'integer', 'Retries': 'integer', 'StartPeriod': 'integer', 'Timeout': 'integer'}, 'ImageUri': 'string', 'MemoryHardLimitMebibytes': 'integer', 'MountPoints': [{'AccessLevel': 'READ_ONLY ' '| ' 'READ_AND_WRITE', 'ContainerPath': 'string', 'InstancePath': 'string'}], 'PortConfiguration': {'ContainerPortRanges': [{'FromPort': 'integer', 'Protocol': 'TCP ' '| ' 'UDP', 'ToPort': 'integer'}]}, 'ResolvedImageDigest': 'string', 'Vcpu': 'double'}], 'TotalMemoryLimitMebibytes': 'integer', 'TotalVcpuLimit': 'double', 'VersionDescription': 'string', 'VersionNumber': 'integer'}}
Retrieves container group definitions for the Amazon Web Services account and Amazon Web Services Region. Use the pagination parameters to retrieve results in a set of sequential pages.
This operation returns only the latest version of each definition. To retrieve all versions of a container group definition, use ListContainerGroupDefinitionVersions.
Request options:
Retrieve the most recent versions of all container group definitions.
Retrieve the most recent versions of all container group definitions, filtered by type. Specify the container group type to filter on.
Results:
If successful, this operation returns the complete properties of a set of container group definition versions that match the request.
Learn more
See also: AWS API Documentation
Request Syntax
client.list_container_group_definitions( ContainerGroupType='GAME_SERVER'|'PER_INSTANCE', Limit=123, NextToken='string' )
string
The type of container group to retrieve. Container group type determines how Amazon GameLift deploys the container group on each fleet instance.
integer
The maximum number of results to return. Use this parameter with NextToken to get results as a set of sequential pages.
string
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.
dict
Response Syntax
{ 'ContainerGroupDefinitions': [ { 'ContainerGroupDefinitionArn': 'string', 'CreationTime': datetime(2015, 1, 1), 'OperatingSystem': 'AMAZON_LINUX_2023', 'Name': 'string', 'ContainerGroupType': 'GAME_SERVER'|'PER_INSTANCE', 'TotalMemoryLimitMebibytes': 123, 'TotalVcpuLimit': 123.0, 'GameServerContainerDefinition': { 'ContainerName': 'string', 'DependsOn': [ { 'ContainerName': 'string', 'Condition': 'START'|'COMPLETE'|'SUCCESS'|'HEALTHY' }, ], 'MountPoints': [ { 'InstancePath': 'string', 'ContainerPath': 'string', 'AccessLevel': 'READ_ONLY'|'READ_AND_WRITE' }, ], 'EnvironmentOverride': [ { 'Name': 'string', 'Value': 'string' }, ], 'ImageUri': 'string', 'PortConfiguration': { 'ContainerPortRanges': [ { 'FromPort': 123, 'ToPort': 123, 'Protocol': 'TCP'|'UDP' }, ] }, 'ResolvedImageDigest': 'string', 'ServerSdkVersion': 'string' }, 'SupportContainerDefinitions': [ { 'ContainerName': 'string', 'DependsOn': [ { 'ContainerName': 'string', 'Condition': 'START'|'COMPLETE'|'SUCCESS'|'HEALTHY' }, ], 'MountPoints': [ { 'InstancePath': 'string', 'ContainerPath': 'string', 'AccessLevel': 'READ_ONLY'|'READ_AND_WRITE' }, ], 'EnvironmentOverride': [ { 'Name': 'string', 'Value': 'string' }, ], 'Essential': True|False, 'HealthCheck': { 'Command': [ 'string', ], 'Interval': 123, 'Retries': 123, 'StartPeriod': 123, 'Timeout': 123 }, 'ImageUri': 'string', 'MemoryHardLimitMebibytes': 123, 'PortConfiguration': { 'ContainerPortRanges': [ { 'FromPort': 123, 'ToPort': 123, 'Protocol': 'TCP'|'UDP' }, ] }, 'ResolvedImageDigest': 'string', 'Vcpu': 123.0 }, ], 'VersionNumber': 123, 'VersionDescription': 'string', 'Status': 'READY'|'COPYING'|'FAILED', 'StatusReason': 'string' }, ], 'NextToken': 'string' }
Response Structure
(dict) --
ContainerGroupDefinitions (list) --
A result set of container group definitions that match the request.
(dict) --
The properties that describe a container group resource. You can update all properties of a container group definition properties. Updates to a container group definition are saved as new versions.
Used with: CreateContainerGroupDefinition
Returned by: DescribeContainerGroupDefinition, ListContainerGroupDefinitions, UpdateContainerGroupDefinition
ContainerGroupDefinitionArn (string) --
The Amazon Resource Name ( ARN) that is assigned to an Amazon GameLift ContainerGroupDefinition resource. It uniquely identifies the resource across all Amazon Web Services Regions. Format is arn:aws:gamelift:[region]::containergroupdefinition/[container group definition name]:[version].
CreationTime (datetime) --
A time stamp indicating when this data object was created. Format is a number expressed in Unix time as milliseconds (for example "1469498468.057").
OperatingSystem (string) --
The platform that all containers in the container group definition run on.
Name (string) --
A descriptive identifier for the container group definition. The name value is unique in an Amazon Web Services Region.
ContainerGroupType (string) --
The type of container group. Container group type determines how Amazon GameLift deploys the container group on each fleet instance.
TotalMemoryLimitMebibytes (integer) --
The amount of memory (in MiB) on a fleet instance to allocate for the container group. All containers in the group share these resources.
You can set a limit for each container definition in the group. If individual containers have limits, this total value must be greater than any individual container's memory limit.
TotalVcpuLimit (float) --
The amount of vCPU units on a fleet instance to allocate for the container group (1 vCPU is equal to 1024 CPU units). All containers in the group share these resources. You can set a limit for each container definition in the group. If individual containers have limits, this total value must be equal to or greater than the sum of the limits for each container in the group.
GameServerContainerDefinition (dict) --
The definition for the game server container in this group. This property is used only when the container group type is GAME_SERVER. This container definition specifies a container image with the game server build.
ContainerName (string) --
The container definition identifier. Container names are unique within a container group definition.
DependsOn (list) --
Indicates that the container relies on the status of other containers in the same container group during startup and shutdown sequences. A container might have dependencies on multiple containers.
(dict) --
A container's dependency on another container in the same container group. The dependency impacts how the dependent container is able to start or shut down based the status of the other container.
For example, ContainerA is configured with the following dependency: a START dependency on ContainerB. This means that ContainerA can't start until ContainerB has started. It also means that ContainerA must shut down before ContainerB.
eiifcbfhgrdurhnucnufkgbnbnnerrvbtjvljdetkehc**Part of:** GameServerContainerDefinition, GameServerContainerDefinitionInput, SupportContainerDefinition, SupportContainerDefinitionInput
ContainerName (string) --
A descriptive label for the container definition that this container depends on.
Condition (string) --
The condition that the dependency container must reach before the dependent container can start. Valid conditions include:
START - The dependency container must have started.
COMPLETE - The dependency container has run to completion (exits). Use this condition with nonessential containers, such as those that run a script and then exit. The dependency container can't be an essential container.
SUCCESS - The dependency container has run to completion and exited with a zero status. The dependency container can't be an essential container.
HEALTHY - The dependency container has passed its Docker health check. Use this condition with dependency containers that have health checks configured. This condition is confirmed at container group startup only.
MountPoints (list) --
A mount point that binds a path inside the container to a file or directory on the host system and lets it access the file or directory.
(dict) --
A mount point that binds a container to a file or directory on the host system.
Part of: GameServerContainerDefinition, GameServerContainerDefinitionInput, SupportContainerDefinition, SupportContainerDefinitionInput
InstancePath (string) --
The path to the source file or directory.
ContainerPath (string) --
The mount path on the container. If this property isn't set, the instance path is used.
AccessLevel (string) --
The type of access for the container.
EnvironmentOverride (list) --
A set of environment variables that's passed to the container on startup. See the ContainerDefinition::environment parameter in the Amazon Elastic Container Service API Reference.
(dict) --
An environment variable to set inside a container, in the form of a key-value pair.
Part of: GameServerContainerDefinition, GameServerContainerDefinitionInput, SupportContainerDefinition, SupportContainerDefinitionInput
Name (string) --
The environment variable name.
Value (string) --
The environment variable value.
ImageUri (string) --
The URI to the image that Amazon GameLift uses when deploying this container to a container fleet. For a more specific identifier, see ResolvedImageDigest.
PortConfiguration (dict) --
The set of ports that are available to bind to processes in the container. For example, a game server process requires a container port to allow game clients to connect to it. Container ports aren't directly accessed by inbound traffic. Amazon GameLift maps these container ports to externally accessible connection ports, which are assigned as needed from the container fleet's ConnectionPortRange.
ContainerPortRanges (list) --
A set of one or more container port number ranges. The ranges can't overlap.
(dict) --
A set of one or more port numbers that can be opened on the container.
Part of: ContainerPortConfiguration
FromPort (integer) --
A starting value for the range of allowed port numbers.
ToPort (integer) --
An ending value for the range of allowed port numbers. Port numbers are end-inclusive. This value must be equal to or greater than FromPort.
Protocol (string) --
The network protocol that these ports support.
ResolvedImageDigest (string) --
A unique and immutable identifier for the container image. The digest is a SHA 256 hash of the container image manifest.
ServerSdkVersion (string) --
The Amazon GameLift server SDK version that the game server is integrated with. Only game servers using 5.2.0 or higher are compatible with container fleets.
SupportContainerDefinitions (list) --
The set of definitions for support containers in this group. A container group definition might have zero support container definitions. Support container can be used in any type of container group.
(dict) --
Describes a support container in a container group. A support container might be in a game server container group or a per-instance container group. Support containers don't run game server processes.
You can update a support container definition and deploy the updates to an existing fleet. When creating or updating a game server container group definition, use the property GameServerContainerDefinitionInput.
Part of: ContainerGroupDefinition
Returned by: DescribeContainerGroupDefinition, ListContainerGroupDefinitions, UpdateContainerGroupDefinition
ContainerName (string) --
The container definition identifier. Container names are unique within a container group definition.
DependsOn (list) --
Indicates that the container relies on the status of other containers in the same container group during its startup and shutdown sequences. A container might have dependencies on multiple containers.
(dict) --
A container's dependency on another container in the same container group. The dependency impacts how the dependent container is able to start or shut down based the status of the other container.
For example, ContainerA is configured with the following dependency: a START dependency on ContainerB. This means that ContainerA can't start until ContainerB has started. It also means that ContainerA must shut down before ContainerB.
eiifcbfhgrdurhnucnufkgbnbnnerrvbtjvljdetkehc**Part of:** GameServerContainerDefinition, GameServerContainerDefinitionInput, SupportContainerDefinition, SupportContainerDefinitionInput
ContainerName (string) --
A descriptive label for the container definition that this container depends on.
Condition (string) --
The condition that the dependency container must reach before the dependent container can start. Valid conditions include:
START - The dependency container must have started.
COMPLETE - The dependency container has run to completion (exits). Use this condition with nonessential containers, such as those that run a script and then exit. The dependency container can't be an essential container.
SUCCESS - The dependency container has run to completion and exited with a zero status. The dependency container can't be an essential container.
HEALTHY - The dependency container has passed its Docker health check. Use this condition with dependency containers that have health checks configured. This condition is confirmed at container group startup only.
MountPoints (list) --
A mount point that binds a path inside the container to a file or directory on the host system and lets it access the file or directory.
(dict) --
A mount point that binds a container to a file or directory on the host system.
Part of: GameServerContainerDefinition, GameServerContainerDefinitionInput, SupportContainerDefinition, SupportContainerDefinitionInput
InstancePath (string) --
The path to the source file or directory.
ContainerPath (string) --
The mount path on the container. If this property isn't set, the instance path is used.
AccessLevel (string) --
The type of access for the container.
EnvironmentOverride (list) --
A set of environment variables that's passed to the container on startup. See the ContainerDefinition::environment parameter in the Amazon Elastic Container Service API Reference.
(dict) --
An environment variable to set inside a container, in the form of a key-value pair.
Part of: GameServerContainerDefinition, GameServerContainerDefinitionInput, SupportContainerDefinition, SupportContainerDefinitionInput
Name (string) --
The environment variable name.
Value (string) --
The environment variable value.
Essential (boolean) --
Indicates whether the container is vital to the container group. If an essential container fails, the entire container group restarts.
HealthCheck (dict) --
A configuration for a non-terminal health check. A support container automatically restarts if it stops functioning or if it fails this health check.
Command (list) --
A string array that specifies the command that the container runs to determine if it's healthy.
(string) --
Interval (integer) --
The time period (in seconds) between each health check.
Retries (integer) --
The number of times to retry a failed health check before flagging the container unhealthy. The first run of the command does not count as a retry.
StartPeriod (integer) --
The optional grace period (in seconds) to give a container time to bootstrap before the first failed health check counts toward the number of retries.
Timeout (integer) --
The time period (in seconds) to wait for a health check to succeed before counting a failed health check.
ImageUri (string) --
The URI to the image that Amazon GameLift deploys to a container fleet. For a more specific identifier, see ResolvedImageDigest.
MemoryHardLimitMebibytes (integer) --
The amount of memory that Amazon GameLift makes available to the container. If memory limits aren't set for an individual container, the container shares the container group's total memory allocation.
Related data type: ContainerGroupDefinition$TotalMemoryLimitMebibytes
PortConfiguration (dict) --
A set of ports that allow access to the container from external users. Processes running in the container can bind to a one of these ports. Container ports aren't directly accessed by inbound traffic. Amazon GameLift maps these container ports to externally accessible connection ports, which are assigned as needed from the container fleet's ConnectionPortRange.
ContainerPortRanges (list) --
A set of one or more container port number ranges. The ranges can't overlap.
(dict) --
A set of one or more port numbers that can be opened on the container.
Part of: ContainerPortConfiguration
FromPort (integer) --
A starting value for the range of allowed port numbers.
ToPort (integer) --
An ending value for the range of allowed port numbers. Port numbers are end-inclusive. This value must be equal to or greater than FromPort.
Protocol (string) --
The network protocol that these ports support.
ResolvedImageDigest (string) --
A unique and immutable identifier for the container image. The digest is a SHA 256 hash of the container image manifest.
Vcpu (float) --
The number of vCPU units that are reserved for the container. If no resources are reserved, the container shares the total vCPU limit for the container group.
Related data type: ContainerGroupDefinition$TotalVcpuLimit
VersionNumber (integer) --
Indicates the version of a particular container group definition. This number is incremented automatically when you update a container group definition. You can view, update, or delete individual versions or the entire container group definition.
VersionDescription (string) --
An optional description that was provided for a container group definition update. Each version can have a unique description.
Status (string) --
Current status of the container group definition resource. Values include:
COPYING -- Amazon GameLift is in the process of making copies of all container images that are defined in the group. While in this state, the resource can't be used to create a container fleet.
READY -- Amazon GameLift has copied the registry images for all containers that are defined in the group. You can use a container group definition in this status to create a container fleet.
FAILED -- Amazon GameLift failed to create a valid container group definition resource. For more details on the cause of the failure, see StatusReason. A container group definition resource in failed status will be deleted within a few minutes.
StatusReason (string) --
Additional information about a container group definition that's in FAILED status. Possible reasons include:
An internal issue prevented Amazon GameLift from creating the container group definition resource. Delete the failed resource and call CreateContainerGroupDefinitionagain.
An access-denied message means that you don't have permissions to access the container image on ECR. See IAM permission examples for help setting up required IAM permissions for Amazon GameLift.
The ImageUri value for at least one of the containers in the container group definition was invalid or not found in the current Amazon Web Services account.
At least one of the container images referenced in the container group definition exceeds the allowed size. For size limits, see Amazon GameLift endpoints and quotas.
At least one of the container images referenced in the container group definition uses a different operating system than the one defined for the container group.
NextToken (string) --
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.
{'Compute': {'ComputeStatus': {'IMPAIRED'}, 'GameServerContainerGroupDefinitionArn': 'string'}}
Registers a compute resource in an Amazon GameLift Anywhere fleet.
For an Anywhere fleet that's running the Amazon GameLift Agent, the Agent handles all compute registry tasks for you. For an Anywhere fleet that doesn't use the Agent, call this operation to register fleet computes.
To register a compute, give the compute a name (must be unique within the fleet) and specify the compute resource's DNS name or IP address. Provide a fleet ID and a fleet location to associate with the compute being registered. You can optionally include the path to a TLS certificate on the compute resource.
If successful, this operation returns compute details, including an Amazon GameLift SDK endpoint or Agent endpoint. Game server processes running on the compute can use this endpoint to communicate with the Amazon GameLift service. Each server process includes the SDK endpoint in its call to the Amazon GameLift server SDK action InitSDK().
To view compute details, call DescribeCompute with the compute name.
Learn more
Server SDK reference guides (for version 5.x)
See also: AWS API Documentation
Request Syntax
client.register_compute( FleetId='string', ComputeName='string', CertificatePath='string', DnsName='string', IpAddress='string', Location='string' )
string
[REQUIRED]
A unique identifier for the fleet to register the compute to. You can use either the fleet ID or ARN value.
string
[REQUIRED]
A descriptive label for the compute resource.
string
The path to a TLS certificate on your compute resource. Amazon GameLift doesn't validate the path and certificate.
string
The DNS name of the compute resource. Amazon GameLift requires either a DNS name or IP address.
string
The IP address of the compute resource. Amazon GameLift requires either a DNS name or IP address. When registering an Anywhere fleet, an IP address is required.
string
The name of a custom location to associate with the compute resource being registered. This parameter is required when registering a compute for an Anywhere fleet.
dict
Response Syntax
{ 'Compute': { 'FleetId': 'string', 'FleetArn': 'string', 'ComputeName': 'string', 'ComputeArn': 'string', 'IpAddress': 'string', 'DnsName': 'string', 'ComputeStatus': 'PENDING'|'ACTIVE'|'TERMINATING'|'IMPAIRED', 'Location': 'string', 'CreationTime': datetime(2015, 1, 1), 'OperatingSystem': 'WINDOWS_2012'|'AMAZON_LINUX'|'AMAZON_LINUX_2'|'WINDOWS_2016'|'AMAZON_LINUX_2023', 'Type': 't2.micro'|'t2.small'|'t2.medium'|'t2.large'|'c3.large'|'c3.xlarge'|'c3.2xlarge'|'c3.4xlarge'|'c3.8xlarge'|'c4.large'|'c4.xlarge'|'c4.2xlarge'|'c4.4xlarge'|'c4.8xlarge'|'c5.large'|'c5.xlarge'|'c5.2xlarge'|'c5.4xlarge'|'c5.9xlarge'|'c5.12xlarge'|'c5.18xlarge'|'c5.24xlarge'|'c5a.large'|'c5a.xlarge'|'c5a.2xlarge'|'c5a.4xlarge'|'c5a.8xlarge'|'c5a.12xlarge'|'c5a.16xlarge'|'c5a.24xlarge'|'r3.large'|'r3.xlarge'|'r3.2xlarge'|'r3.4xlarge'|'r3.8xlarge'|'r4.large'|'r4.xlarge'|'r4.2xlarge'|'r4.4xlarge'|'r4.8xlarge'|'r4.16xlarge'|'r5.large'|'r5.xlarge'|'r5.2xlarge'|'r5.4xlarge'|'r5.8xlarge'|'r5.12xlarge'|'r5.16xlarge'|'r5.24xlarge'|'r5a.large'|'r5a.xlarge'|'r5a.2xlarge'|'r5a.4xlarge'|'r5a.8xlarge'|'r5a.12xlarge'|'r5a.16xlarge'|'r5a.24xlarge'|'m3.medium'|'m3.large'|'m3.xlarge'|'m3.2xlarge'|'m4.large'|'m4.xlarge'|'m4.2xlarge'|'m4.4xlarge'|'m4.10xlarge'|'m5.large'|'m5.xlarge'|'m5.2xlarge'|'m5.4xlarge'|'m5.8xlarge'|'m5.12xlarge'|'m5.16xlarge'|'m5.24xlarge'|'m5a.large'|'m5a.xlarge'|'m5a.2xlarge'|'m5a.4xlarge'|'m5a.8xlarge'|'m5a.12xlarge'|'m5a.16xlarge'|'m5a.24xlarge'|'c5d.large'|'c5d.xlarge'|'c5d.2xlarge'|'c5d.4xlarge'|'c5d.9xlarge'|'c5d.12xlarge'|'c5d.18xlarge'|'c5d.24xlarge'|'c6a.large'|'c6a.xlarge'|'c6a.2xlarge'|'c6a.4xlarge'|'c6a.8xlarge'|'c6a.12xlarge'|'c6a.16xlarge'|'c6a.24xlarge'|'c6i.large'|'c6i.xlarge'|'c6i.2xlarge'|'c6i.4xlarge'|'c6i.8xlarge'|'c6i.12xlarge'|'c6i.16xlarge'|'c6i.24xlarge'|'r5d.large'|'r5d.xlarge'|'r5d.2xlarge'|'r5d.4xlarge'|'r5d.8xlarge'|'r5d.12xlarge'|'r5d.16xlarge'|'r5d.24xlarge'|'m6g.medium'|'m6g.large'|'m6g.xlarge'|'m6g.2xlarge'|'m6g.4xlarge'|'m6g.8xlarge'|'m6g.12xlarge'|'m6g.16xlarge'|'c6g.medium'|'c6g.large'|'c6g.xlarge'|'c6g.2xlarge'|'c6g.4xlarge'|'c6g.8xlarge'|'c6g.12xlarge'|'c6g.16xlarge'|'r6g.medium'|'r6g.large'|'r6g.xlarge'|'r6g.2xlarge'|'r6g.4xlarge'|'r6g.8xlarge'|'r6g.12xlarge'|'r6g.16xlarge'|'c6gn.medium'|'c6gn.large'|'c6gn.xlarge'|'c6gn.2xlarge'|'c6gn.4xlarge'|'c6gn.8xlarge'|'c6gn.12xlarge'|'c6gn.16xlarge'|'c7g.medium'|'c7g.large'|'c7g.xlarge'|'c7g.2xlarge'|'c7g.4xlarge'|'c7g.8xlarge'|'c7g.12xlarge'|'c7g.16xlarge'|'r7g.medium'|'r7g.large'|'r7g.xlarge'|'r7g.2xlarge'|'r7g.4xlarge'|'r7g.8xlarge'|'r7g.12xlarge'|'r7g.16xlarge'|'m7g.medium'|'m7g.large'|'m7g.xlarge'|'m7g.2xlarge'|'m7g.4xlarge'|'m7g.8xlarge'|'m7g.12xlarge'|'m7g.16xlarge'|'g5g.xlarge'|'g5g.2xlarge'|'g5g.4xlarge'|'g5g.8xlarge'|'g5g.16xlarge', 'GameLiftServiceSdkEndpoint': 'string', 'GameLiftAgentEndpoint': 'string', 'InstanceId': 'string', 'ContainerAttributes': [ { 'ContainerName': 'string', 'ContainerRuntimeId': 'string' }, ], 'GameServerContainerGroupDefinitionArn': 'string' } }
Response Structure
(dict) --
Compute (dict) --
The details of the compute resource you registered.
FleetId (string) --
A unique identifier for the fleet that the compute belongs to.
FleetArn (string) --
The Amazon Resource Name (ARN) of the fleet that the compute belongs to.
ComputeName (string) --
A descriptive label for the compute resource. For instances in a managed EC2 fleet, the compute name is the same value as the InstanceId ID.
ComputeArn (string) --
The ARN that is assigned to a compute resource and uniquely identifies it. ARNs are unique across locations. Instances in managed EC2 fleets are not assigned a Compute ARN.
IpAddress (string) --
The IP address of a compute resource. Amazon GameLift requires a DNS name or IP address for a compute.
DnsName (string) --
The DNS name of a compute resource. Amazon GameLift requires a DNS name or IP address for a compute.
ComputeStatus (string) --
Current status of the compute. A compute must have an ACTIVE status to host game sessions.
Location (string) --
The name of the custom location you added to the fleet that this compute resource resides in.
CreationTime (datetime) --
A time stamp indicating when this data object was created. Format is a number expressed in Unix time as milliseconds (for example "1469498468.057").
OperatingSystem (string) --
The type of operating system on the compute resource.
Type (string) --
The Amazon EC2 instance type that the fleet uses. For registered computes in an Amazon GameLift Anywhere fleet, this property is empty.
GameLiftServiceSdkEndpoint (string) --
The Amazon GameLift SDK endpoint connection for a registered compute resource in an Anywhere fleet. The game servers on the compute use this endpoint to connect to the Amazon GameLift service.
GameLiftAgentEndpoint (string) --
The endpoint of the Amazon GameLift Agent.
InstanceId (string) --
The InstanceID of the EC2 instance that is hosting the compute.
ContainerAttributes (list) --
A set of attributes for each container in the compute.
(dict) --
A unique identifier for a container in a container fleet compute.
Returned by: DescribeCompute
ContainerName (string) --
The identifier for a container that's running in a compute.
ContainerRuntimeId (string) --
The runtime ID for the container that's running in a compute. This value is unique within the compute.
GameServerContainerGroupDefinitionArn (string) --
The game server container group definition for the compute.