CfnContainerGroupDefinitionPropsMixin

class aws_cdk.mixins_preview.aws_gamelift.mixins.CfnContainerGroupDefinitionPropsMixin(props, *, strategy=None)

Bases: Mixin

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

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-gamelift-containergroupdefinition.html

CloudformationResource:

AWS::GameLift::ContainerGroupDefinition

Mixin:

true

ExampleMetadata:

fixture=_generated

Example:

# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk.mixins_preview import mixins
from aws_cdk.mixins_preview.aws_gamelift import mixins as gamelift_mixins

cfn_container_group_definition_props_mixin = gamelift_mixins.CfnContainerGroupDefinitionPropsMixin(gamelift_mixins.CfnContainerGroupDefinitionMixinProps(
    container_group_type="containerGroupType",
    game_server_container_definition=gamelift_mixins.CfnContainerGroupDefinitionPropsMixin.GameServerContainerDefinitionProperty(
        container_name="containerName",
        depends_on=[gamelift_mixins.CfnContainerGroupDefinitionPropsMixin.ContainerDependencyProperty(
            condition="condition",
            container_name="containerName"
        )],
        environment_override=[gamelift_mixins.CfnContainerGroupDefinitionPropsMixin.ContainerEnvironmentProperty(
            name="name",
            value="value"
        )],
        image_uri="imageUri",
        mount_points=[gamelift_mixins.CfnContainerGroupDefinitionPropsMixin.ContainerMountPointProperty(
            access_level="accessLevel",
            container_path="containerPath",
            instance_path="instancePath"
        )],
        port_configuration=gamelift_mixins.CfnContainerGroupDefinitionPropsMixin.PortConfigurationProperty(
            container_port_ranges=[gamelift_mixins.CfnContainerGroupDefinitionPropsMixin.ContainerPortRangeProperty(
                from_port=123,
                protocol="protocol",
                to_port=123
            )]
        ),
        resolved_image_digest="resolvedImageDigest",
        server_sdk_version="serverSdkVersion"
    ),
    name="name",
    operating_system="operatingSystem",
    source_version_number=123,
    support_container_definitions=[gamelift_mixins.CfnContainerGroupDefinitionPropsMixin.SupportContainerDefinitionProperty(
        container_name="containerName",
        depends_on=[gamelift_mixins.CfnContainerGroupDefinitionPropsMixin.ContainerDependencyProperty(
            condition="condition",
            container_name="containerName"
        )],
        environment_override=[gamelift_mixins.CfnContainerGroupDefinitionPropsMixin.ContainerEnvironmentProperty(
            name="name",
            value="value"
        )],
        essential=False,
        health_check=gamelift_mixins.CfnContainerGroupDefinitionPropsMixin.ContainerHealthCheckProperty(
            command=["command"],
            interval=123,
            retries=123,
            start_period=123,
            timeout=123
        ),
        image_uri="imageUri",
        memory_hard_limit_mebibytes=123,
        mount_points=[gamelift_mixins.CfnContainerGroupDefinitionPropsMixin.ContainerMountPointProperty(
            access_level="accessLevel",
            container_path="containerPath",
            instance_path="instancePath"
        )],
        port_configuration=gamelift_mixins.CfnContainerGroupDefinitionPropsMixin.PortConfigurationProperty(
            container_port_ranges=[gamelift_mixins.CfnContainerGroupDefinitionPropsMixin.ContainerPortRangeProperty(
                from_port=123,
                protocol="protocol",
                to_port=123
            )]
        ),
        resolved_image_digest="resolvedImageDigest",
        vcpu=123
    )],
    tags=[CfnTag(
        key="key",
        value="value"
    )],
    total_memory_limit_mebibytes=123,
    total_vcpu_limit=123,
    version_description="versionDescription"
),
    strategy=mixins.PropertyMergeStrategy.OVERRIDE
)

Create a mixin to apply properties to AWS::GameLift::ContainerGroupDefinition.

Parameters:

Methods

apply_to(construct)

Apply the mixin properties to the construct.

Parameters:

construct (IConstruct)

Return type:

IConstruct

supports(construct)

Check if this mixin supports the given construct.

Parameters:

construct (IConstruct)

Return type:

bool

Attributes

CFN_PROPERTY_KEYS = ['containerGroupType', 'gameServerContainerDefinition', 'name', 'operatingSystem', 'sourceVersionNumber', 'supportContainerDefinitions', 'tags', 'totalMemoryLimitMebibytes', 'totalVcpuLimit', 'versionDescription']

Static Methods

classmethod is_mixin(x)

(experimental) Checks if x is a Mixin.

Parameters:

x (Any) – Any object.

Return type:

bool

Returns:

true if x is an object created from a class which extends Mixin.

Stability:

experimental

ContainerDependencyProperty

class CfnContainerGroupDefinitionPropsMixin.ContainerDependencyProperty(*, condition=None, container_name=None)

Bases: object

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 .

Part of: GameServerContainerDefinition , GameServerContainerDefinitionInput , SupportContainerDefinition , SupportContainerDefinitionInput

Parameters:
  • condition (Optional[str]) – 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.

  • container_name (Optional[str]) – A descriptive label for the container definition that this container depends on.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-gamelift-containergroupdefinition-containerdependency.html

ExampleMetadata:

fixture=_generated

Example:

# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk.mixins_preview.aws_gamelift import mixins as gamelift_mixins

container_dependency_property = gamelift_mixins.CfnContainerGroupDefinitionPropsMixin.ContainerDependencyProperty(
    condition="condition",
    container_name="containerName"
)

Attributes

condition

.

  • 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.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-gamelift-containergroupdefinition-containerdependency.html#cfn-gamelift-containergroupdefinition-containerdependency-condition

Type:

The condition that the dependency container must reach before the dependent container can start. Valid conditions include

container_name

A descriptive label for the container definition that this container depends on.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-gamelift-containergroupdefinition-containerdependency.html#cfn-gamelift-containergroupdefinition-containerdependency-containername

ContainerEnvironmentProperty

class CfnContainerGroupDefinitionPropsMixin.ContainerEnvironmentProperty(*, name=None, value=None)

Bases: object

An environment variable to set inside a container, in the form of a key-value pair.

Part of: GameServerContainerDefinition , GameServerContainerDefinitionInput , SupportContainerDefinition , SupportContainerDefinitionInput

Parameters:
  • name (Optional[str]) – The environment variable name.

  • value (Optional[str]) – The environment variable value.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-gamelift-containergroupdefinition-containerenvironment.html

ExampleMetadata:

fixture=_generated

Example:

# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk.mixins_preview.aws_gamelift import mixins as gamelift_mixins

container_environment_property = gamelift_mixins.CfnContainerGroupDefinitionPropsMixin.ContainerEnvironmentProperty(
    name="name",
    value="value"
)

Attributes

name

The environment variable name.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-gamelift-containergroupdefinition-containerenvironment.html#cfn-gamelift-containergroupdefinition-containerenvironment-name

value

The environment variable value.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-gamelift-containergroupdefinition-containerenvironment.html#cfn-gamelift-containergroupdefinition-containerenvironment-value

ContainerHealthCheckProperty

class CfnContainerGroupDefinitionPropsMixin.ContainerHealthCheckProperty(*, command=None, interval=None, retries=None, start_period=None, timeout=None)

Bases: object

Instructions on when and how to check the health of a support container in a container fleet.

These properties override any Docker health checks that are set in the container image. For more information on container health checks, see HealthCheck command in the Amazon Elastic Container Service API . Game server containers don’t have a health check parameter; Amazon GameLift Servers automatically handles health checks for these containers.

The following example instructs the container to initiate a health check command every 60 seconds and wait 10 seconds for it to succeed. If it fails, retry the command 3 times before flagging the container as unhealthy. It also tells the container to wait 100 seconds after launch before counting failed health checks.

{"Command": [ "CMD-SHELL", "ps cax | grep "processmanager" || exit 1" ], "Interval": 60, "Timeout": 10, "Retries": 3, "StartPeriod": 100 }

Part of: SupportContainerDefinition , SupportContainerDefinitionInput

Parameters:
  • command (Optional[Sequence[str]]) – A string array that specifies the command that the container runs to determine if it’s healthy.

  • interval (Union[int, float, None]) – The time period (in seconds) between each health check.

  • retries (Union[int, float, None]) – 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.

  • start_period (Union[int, float, None]) – 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 (Union[int, float, None]) – The time period (in seconds) to wait for a health check to succeed before counting a failed health check.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-gamelift-containergroupdefinition-containerhealthcheck.html

ExampleMetadata:

fixture=_generated

Example:

# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk.mixins_preview.aws_gamelift import mixins as gamelift_mixins

container_health_check_property = gamelift_mixins.CfnContainerGroupDefinitionPropsMixin.ContainerHealthCheckProperty(
    command=["command"],
    interval=123,
    retries=123,
    start_period=123,
    timeout=123
)

Attributes

command

A string array that specifies the command that the container runs to determine if it’s healthy.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-gamelift-containergroupdefinition-containerhealthcheck.html#cfn-gamelift-containergroupdefinition-containerhealthcheck-command

interval

The time period (in seconds) between each health check.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-gamelift-containergroupdefinition-containerhealthcheck.html#cfn-gamelift-containergroupdefinition-containerhealthcheck-interval

retries

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.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-gamelift-containergroupdefinition-containerhealthcheck.html#cfn-gamelift-containergroupdefinition-containerhealthcheck-retries

start_period

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.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-gamelift-containergroupdefinition-containerhealthcheck.html#cfn-gamelift-containergroupdefinition-containerhealthcheck-startperiod

timeout

The time period (in seconds) to wait for a health check to succeed before counting a failed health check.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-gamelift-containergroupdefinition-containerhealthcheck.html#cfn-gamelift-containergroupdefinition-containerhealthcheck-timeout

ContainerMountPointProperty

class CfnContainerGroupDefinitionPropsMixin.ContainerMountPointProperty(*, access_level=None, container_path=None, instance_path=None)

Bases: object

A mount point that binds a container to a file or directory on the host system.

Part of: GameServerContainerDefinition , ` <https://docs.aws.amazon.com/gamelift/latest/apireference/API_GameServerContainerDefinitionInput.html>`_ , SupportContainerDefinition , ` <https://docs.aws.amazon.com/gamelift/latest/apireference/API_SupportContainerDefinitionInput.html>`_

Parameters:
  • access_level (Optional[str]) – The type of access for the container.

  • container_path (Optional[str]) – The mount path on the container. If this property isn’t set, the instance path is used.

  • instance_path (Optional[str]) – The path to the source file or directory.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-gamelift-containergroupdefinition-containermountpoint.html

ExampleMetadata:

fixture=_generated

Example:

# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk.mixins_preview.aws_gamelift import mixins as gamelift_mixins

container_mount_point_property = gamelift_mixins.CfnContainerGroupDefinitionPropsMixin.ContainerMountPointProperty(
    access_level="accessLevel",
    container_path="containerPath",
    instance_path="instancePath"
)

Attributes

access_level

The type of access for the container.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-gamelift-containergroupdefinition-containermountpoint.html#cfn-gamelift-containergroupdefinition-containermountpoint-accesslevel

container_path

The mount path on the container.

If this property isn’t set, the instance path is used.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-gamelift-containergroupdefinition-containermountpoint.html#cfn-gamelift-containergroupdefinition-containermountpoint-containerpath

instance_path

The path to the source file or directory.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-gamelift-containergroupdefinition-containermountpoint.html#cfn-gamelift-containergroupdefinition-containermountpoint-instancepath

ContainerPortRangeProperty

class CfnContainerGroupDefinitionPropsMixin.ContainerPortRangeProperty(*, from_port=None, protocol=None, to_port=None)

Bases: object

A set of one or more port numbers that can be opened on the container, and the supported network protocol.

Part of: ContainerPortConfiguration

Parameters:
  • from_port (Union[int, float, None]) – A starting value for the range of allowed port numbers.

  • protocol (Optional[str]) – The network protocol that these ports support.

  • to_port (Union[int, float, None]) – 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 .

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-gamelift-containergroupdefinition-containerportrange.html

ExampleMetadata:

fixture=_generated

Example:

# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk.mixins_preview.aws_gamelift import mixins as gamelift_mixins

container_port_range_property = gamelift_mixins.CfnContainerGroupDefinitionPropsMixin.ContainerPortRangeProperty(
    from_port=123,
    protocol="protocol",
    to_port=123
)

Attributes

from_port

A starting value for the range of allowed port numbers.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-gamelift-containergroupdefinition-containerportrange.html#cfn-gamelift-containergroupdefinition-containerportrange-fromport

protocol

The network protocol that these ports support.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-gamelift-containergroupdefinition-containerportrange.html#cfn-gamelift-containergroupdefinition-containerportrange-protocol

to_port

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 .

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-gamelift-containergroupdefinition-containerportrange.html#cfn-gamelift-containergroupdefinition-containerportrange-toport

GameServerContainerDefinitionProperty

class CfnContainerGroupDefinitionPropsMixin.GameServerContainerDefinitionProperty(*, container_name=None, depends_on=None, environment_override=None, image_uri=None, mount_points=None, port_configuration=None, resolved_image_digest=None, server_sdk_version=None)

Bases: object

Describes the game server container in an existing game server container group.

A game server container identifies a container image with your game server build. A game server container is automatically considered essential; if an essential container fails, the entire container group restarts.

You can update a container definition and deploy the updates to an existing fleet. When creating or updating a game server container group definition, use the property ` <https://docs.aws.amazon.com/gamelift/latest/apireference/API_GameServerContainerDefinitionInput>`_ .

Part of: ContainerGroupDefinition

Returned by: DescribeContainerGroupDefinition , ListContainerGroupDefinitions , UpdateContainerGroupDefinition

Parameters:
  • container_name (Optional[str]) – The container definition identifier. Container names are unique within a container group definition.

  • depends_on (Union[IResolvable, Sequence[Union[IResolvable, ContainerDependencyProperty, Dict[str, Any]]], None]) – 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.

  • environment_override (Union[IResolvable, Sequence[Union[IResolvable, ContainerEnvironmentProperty, Dict[str, Any]]], None]) – 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 .

  • image_uri (Optional[str]) – The URI to the image that Amazon GameLift Servers uses when deploying this container to a container fleet. For a more specific identifier, see ResolvedImageDigest .

  • mount_points (Union[IResolvable, Sequence[Union[IResolvable, ContainerMountPointProperty, Dict[str, Any]]], None]) – 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.

  • port_configuration (Union[IResolvable, PortConfigurationProperty, Dict[str, Any], None]) – 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 Servers maps these container ports to externally accessible connection ports, which are assigned as needed from the container fleet’s ConnectionPortRange .

  • resolved_image_digest (Optional[str]) – A unique and immutable identifier for the container image. The digest is a SHA 256 hash of the container image manifest.

  • server_sdk_version (Optional[str]) – The Amazon GameLift Servers server SDK version that the game server is integrated with. Only game servers using 5.2.0 or higher are compatible with container fleets.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-gamelift-containergroupdefinition-gameservercontainerdefinition.html

ExampleMetadata:

fixture=_generated

Example:

# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk.mixins_preview.aws_gamelift import mixins as gamelift_mixins

game_server_container_definition_property = gamelift_mixins.CfnContainerGroupDefinitionPropsMixin.GameServerContainerDefinitionProperty(
    container_name="containerName",
    depends_on=[gamelift_mixins.CfnContainerGroupDefinitionPropsMixin.ContainerDependencyProperty(
        condition="condition",
        container_name="containerName"
    )],
    environment_override=[gamelift_mixins.CfnContainerGroupDefinitionPropsMixin.ContainerEnvironmentProperty(
        name="name",
        value="value"
    )],
    image_uri="imageUri",
    mount_points=[gamelift_mixins.CfnContainerGroupDefinitionPropsMixin.ContainerMountPointProperty(
        access_level="accessLevel",
        container_path="containerPath",
        instance_path="instancePath"
    )],
    port_configuration=gamelift_mixins.CfnContainerGroupDefinitionPropsMixin.PortConfigurationProperty(
        container_port_ranges=[gamelift_mixins.CfnContainerGroupDefinitionPropsMixin.ContainerPortRangeProperty(
            from_port=123,
            protocol="protocol",
            to_port=123
        )]
    ),
    resolved_image_digest="resolvedImageDigest",
    server_sdk_version="serverSdkVersion"
)

Attributes

container_name

The container definition identifier.

Container names are unique within a container group definition.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-gamelift-containergroupdefinition-gameservercontainerdefinition.html#cfn-gamelift-containergroupdefinition-gameservercontainerdefinition-containername

depends_on

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.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-gamelift-containergroupdefinition-gameservercontainerdefinition.html#cfn-gamelift-containergroupdefinition-gameservercontainerdefinition-dependson

environment_override

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 .

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-gamelift-containergroupdefinition-gameservercontainerdefinition.html#cfn-gamelift-containergroupdefinition-gameservercontainerdefinition-environmentoverride

image_uri

The URI to the image that Amazon GameLift Servers uses when deploying this container to a container fleet.

For a more specific identifier, see ResolvedImageDigest .

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-gamelift-containergroupdefinition-gameservercontainerdefinition.html#cfn-gamelift-containergroupdefinition-gameservercontainerdefinition-imageuri

mount_points

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.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-gamelift-containergroupdefinition-gameservercontainerdefinition.html#cfn-gamelift-containergroupdefinition-gameservercontainerdefinition-mountpoints

port_configuration

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 Servers maps these container ports to externally accessible connection ports, which are assigned as needed from the container fleet’s ConnectionPortRange .

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-gamelift-containergroupdefinition-gameservercontainerdefinition.html#cfn-gamelift-containergroupdefinition-gameservercontainerdefinition-portconfiguration

resolved_image_digest

A unique and immutable identifier for the container image.

The digest is a SHA 256 hash of the container image manifest.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-gamelift-containergroupdefinition-gameservercontainerdefinition.html#cfn-gamelift-containergroupdefinition-gameservercontainerdefinition-resolvedimagedigest

server_sdk_version

The Amazon GameLift Servers server SDK version that the game server is integrated with.

Only game servers using 5.2.0 or higher are compatible with container fleets.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-gamelift-containergroupdefinition-gameservercontainerdefinition.html#cfn-gamelift-containergroupdefinition-gameservercontainerdefinition-serversdkversion

PortConfigurationProperty

class CfnContainerGroupDefinitionPropsMixin.PortConfigurationProperty(*, container_port_ranges=None)

Bases: object

Defines the ports on a container.

Parameters:

container_port_ranges (Union[IResolvable, Sequence[Union[IResolvable, ContainerPortRangeProperty, Dict[str, Any]]], None]) – Specifies one or more ranges of ports on a container.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-gamelift-containergroupdefinition-portconfiguration.html

ExampleMetadata:

fixture=_generated

Example:

# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk.mixins_preview.aws_gamelift import mixins as gamelift_mixins

port_configuration_property = gamelift_mixins.CfnContainerGroupDefinitionPropsMixin.PortConfigurationProperty(
    container_port_ranges=[gamelift_mixins.CfnContainerGroupDefinitionPropsMixin.ContainerPortRangeProperty(
        from_port=123,
        protocol="protocol",
        to_port=123
    )]
)

Attributes

container_port_ranges

Specifies one or more ranges of ports on a container.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-gamelift-containergroupdefinition-portconfiguration.html#cfn-gamelift-containergroupdefinition-portconfiguration-containerportranges

SupportContainerDefinitionProperty

class CfnContainerGroupDefinitionPropsMixin.SupportContainerDefinitionProperty(*, container_name=None, depends_on=None, environment_override=None, essential=None, health_check=None, image_uri=None, memory_hard_limit_mebibytes=None, mount_points=None, port_configuration=None, resolved_image_digest=None, vcpu=None)

Bases: object

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

Parameters:
  • container_name (Optional[str]) – The container definition identifier. Container names are unique within a container group definition.

  • depends_on (Union[IResolvable, Sequence[Union[IResolvable, ContainerDependencyProperty, Dict[str, Any]]], None]) – 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.

  • environment_override (Union[IResolvable, Sequence[Union[IResolvable, ContainerEnvironmentProperty, Dict[str, Any]]], None]) –

    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 .

  • essential (Union[bool, IResolvable, None]) – Indicates whether the container is vital to the container group. If an essential container fails, the entire container group restarts.

  • health_check (Union[IResolvable, ContainerHealthCheckProperty, Dict[str, Any], None]) – A configuration for a non-terminal health check. A support container automatically restarts if it stops functioning or if it fails this health check.

  • image_uri (Optional[str]) – The URI to the image that Amazon GameLift Servers deploys to a container fleet. For a more specific identifier, see ResolvedImageDigest .

  • memory_hard_limit_mebibytes (Union[int, float, None]) – The amount of memory that Amazon GameLift Servers 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

  • mount_points (Union[IResolvable, Sequence[Union[IResolvable, ContainerMountPointProperty, Dict[str, Any]]], None]) – 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.

  • port_configuration (Union[IResolvable, PortConfigurationProperty, Dict[str, Any], None]) – 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 Servers maps these container ports to externally accessible connection ports, which are assigned as needed from the container fleet’s ConnectionPortRange .

  • resolved_image_digest (Optional[str]) – A unique and immutable identifier for the container image. The digest is a SHA 256 hash of the container image manifest.

  • vcpu (Union[int, float, None]) – 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

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-gamelift-containergroupdefinition-supportcontainerdefinition.html

ExampleMetadata:

fixture=_generated

Example:

# The code below shows an example of how to instantiate this type.
# The values are placeholders you should change.
from aws_cdk.mixins_preview.aws_gamelift import mixins as gamelift_mixins

support_container_definition_property = gamelift_mixins.CfnContainerGroupDefinitionPropsMixin.SupportContainerDefinitionProperty(
    container_name="containerName",
    depends_on=[gamelift_mixins.CfnContainerGroupDefinitionPropsMixin.ContainerDependencyProperty(
        condition="condition",
        container_name="containerName"
    )],
    environment_override=[gamelift_mixins.CfnContainerGroupDefinitionPropsMixin.ContainerEnvironmentProperty(
        name="name",
        value="value"
    )],
    essential=False,
    health_check=gamelift_mixins.CfnContainerGroupDefinitionPropsMixin.ContainerHealthCheckProperty(
        command=["command"],
        interval=123,
        retries=123,
        start_period=123,
        timeout=123
    ),
    image_uri="imageUri",
    memory_hard_limit_mebibytes=123,
    mount_points=[gamelift_mixins.CfnContainerGroupDefinitionPropsMixin.ContainerMountPointProperty(
        access_level="accessLevel",
        container_path="containerPath",
        instance_path="instancePath"
    )],
    port_configuration=gamelift_mixins.CfnContainerGroupDefinitionPropsMixin.PortConfigurationProperty(
        container_port_ranges=[gamelift_mixins.CfnContainerGroupDefinitionPropsMixin.ContainerPortRangeProperty(
            from_port=123,
            protocol="protocol",
            to_port=123
        )]
    ),
    resolved_image_digest="resolvedImageDigest",
    vcpu=123
)

Attributes

container_name

The container definition identifier.

Container names are unique within a container group definition.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-gamelift-containergroupdefinition-supportcontainerdefinition.html#cfn-gamelift-containergroupdefinition-supportcontainerdefinition-containername

depends_on

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.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-gamelift-containergroupdefinition-supportcontainerdefinition.html#cfn-gamelift-containergroupdefinition-supportcontainerdefinition-dependson

environment_override

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 .

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-gamelift-containergroupdefinition-supportcontainerdefinition.html#cfn-gamelift-containergroupdefinition-supportcontainerdefinition-environmentoverride

essential

Indicates whether the container is vital to the container group.

If an essential container fails, the entire container group restarts.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-gamelift-containergroupdefinition-supportcontainerdefinition.html#cfn-gamelift-containergroupdefinition-supportcontainerdefinition-essential

health_check

A configuration for a non-terminal health check.

A support container automatically restarts if it stops functioning or if it fails this health check.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-gamelift-containergroupdefinition-supportcontainerdefinition.html#cfn-gamelift-containergroupdefinition-supportcontainerdefinition-healthcheck

image_uri

The URI to the image that Amazon GameLift Servers deploys to a container fleet.

For a more specific identifier, see ResolvedImageDigest .

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-gamelift-containergroupdefinition-supportcontainerdefinition.html#cfn-gamelift-containergroupdefinition-supportcontainerdefinition-imageuri

memory_hard_limit_mebibytes

The amount of memory that Amazon GameLift Servers 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

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-gamelift-containergroupdefinition-supportcontainerdefinition.html#cfn-gamelift-containergroupdefinition-supportcontainerdefinition-memoryhardlimitmebibytes

mount_points

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.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-gamelift-containergroupdefinition-supportcontainerdefinition.html#cfn-gamelift-containergroupdefinition-supportcontainerdefinition-mountpoints

port_configuration

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 Servers maps these container ports to externally accessible connection ports, which are assigned as needed from the container fleet’s ConnectionPortRange .

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-gamelift-containergroupdefinition-supportcontainerdefinition.html#cfn-gamelift-containergroupdefinition-supportcontainerdefinition-portconfiguration

resolved_image_digest

A unique and immutable identifier for the container image.

The digest is a SHA 256 hash of the container image manifest.

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-gamelift-containergroupdefinition-supportcontainerdefinition.html#cfn-gamelift-containergroupdefinition-supportcontainerdefinition-resolvedimagedigest

vcpu

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

See:

http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-gamelift-containergroupdefinition-supportcontainerdefinition.html#cfn-gamelift-containergroupdefinition-supportcontainerdefinition-vcpu