AWS Fundamentals Logo
AWS Fundamentals
L1 ConstructAWS::GameLift::ContainerGroupDefinition

CfnContainerGroupDefinition

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](https://docs.aws.amazon.com/gamelift/latest/apireference/API_CreateContainerGroupDefinition.html) *Returned by:* [DescribeContainerGroupDefinition](https://docs.aws.amazon.com/gamelift/latest/apireference/API_DescribeContainerGroupDefinition.html) , [ListContainerGroupDefinitions](https://docs.aws.amazon.com/gamelift/latest/apireference/API_ListContainerGroupDefinitions.html) , [UpdateContainerGroupDefinition](https://docs.aws.amazon.com/gamelift/latest/apireference/API_UpdateContainerGroupDefinition.html)

Import

import { CfnContainerGroupDefinition } from 'aws-cdk-lib/aws-gamelift';

Or use the module namespace:

import * as gamelift from 'aws-cdk-lib/aws-gamelift';
// gamelift.CfnContainerGroupDefinition

Properties

Configuration passed to the constructor as CfnContainerGroupDefinitionProps.

nameRequired
string

A descriptive identifier for the container group definition. The name value is unique in an AWS Region.

operatingSystemRequired
string

The platform that all containers in the container group definition run on. > Amazon Linux 2 (AL2) will reach end of support on 6/30/2026. See more details in the [Amazon Linux 2 FAQs](https://docs.aws.amazon.com/amazon-linux-2/faqs/) . For game servers that are hosted on AL2 and use server SDK version 4.x for Amazon GameLift Servers, first update the game server build to server SDK 5.x, and then deploy to AL2023 instances. See [Migrate to server SDK version 5.](https://docs.aws.amazon.com/gamelift/latest/developerguide/reference-serversdk5-migration.html)

totalMemoryLimitMebibytesRequired
number

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.

totalVcpuLimitRequired
number

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.

containerGroupTypeOptional
string

The type of container group. Container group type determines how Amazon GameLift Servers deploys the container group on each fleet instance.

gameServerContainerDefinitionOptional
IResolvable | GameServerContainerDefinitionProperty

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.

sourceVersionNumberOptional
number

A specific ContainerGroupDefinition version to be updated.

supportContainerDefinitionsOptional
IResolvable | IResolvable | SupportContainerDefinitionProperty[]

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.

tagsOptional
CfnTag[]

An array of key-value pairs to apply to this resource.

versionDescriptionOptional
string

An optional description that was provided for a container group definition update. Each version can have a unique description.

CloudFormation Resource

This L1 construct maps directly to the following CloudFormation resource type.

Learn AWS the Practical Way

Our bi-weekly newsletter teaches hands-on AWS fundamentals. No certification fluff - just practical knowledge.

Subscribe to Newsletter