amazonka-ecs-2.0: Amazon EC2 Container Service SDK.
Copyright(c) 2013-2023 Brendan Hay
LicenseMozilla Public License, v. 2.0.
MaintainerBrendan Hay
Stabilityauto-generated
Portabilitynon-portable (GHC extensions)
Safe HaskellSafe-Inferred
LanguageHaskell2010

Amazonka.ECS.Types.ResourceRequirement

Description

 
Synopsis

Documentation

data ResourceRequirement Source #

The type and amount of a resource to assign to a container. The supported resource types are GPUs and Elastic Inference accelerators. For more information, see Working with GPUs on Amazon ECS or Working with Amazon Elastic Inference on Amazon ECS in the Amazon Elastic Container Service Developer Guide

See: newResourceRequirement smart constructor.

Constructors

ResourceRequirement' 

Fields

  • value :: Text

    The value for the specified resource type.

    If the GPU type is used, the value is the number of physical GPUs the Amazon ECS container agent reserves for the container. The number of GPUs that's reserved for all containers in a task can't exceed the number of available GPUs on the container instance that the task is launched on.

    If the InferenceAccelerator type is used, the value matches the deviceName for an InferenceAccelerator specified in a task definition.

  • type' :: ResourceType

    The type of resource to assign to a container. The supported values are GPU or InferenceAccelerator.

Instances

Instances details
FromJSON ResourceRequirement Source # 
Instance details

Defined in Amazonka.ECS.Types.ResourceRequirement

ToJSON ResourceRequirement Source # 
Instance details

Defined in Amazonka.ECS.Types.ResourceRequirement

Generic ResourceRequirement Source # 
Instance details

Defined in Amazonka.ECS.Types.ResourceRequirement

Associated Types

type Rep ResourceRequirement :: Type -> Type #

Read ResourceRequirement Source # 
Instance details

Defined in Amazonka.ECS.Types.ResourceRequirement

Show ResourceRequirement Source # 
Instance details

Defined in Amazonka.ECS.Types.ResourceRequirement

NFData ResourceRequirement Source # 
Instance details

Defined in Amazonka.ECS.Types.ResourceRequirement

Methods

rnf :: ResourceRequirement -> () #

Eq ResourceRequirement Source # 
Instance details

Defined in Amazonka.ECS.Types.ResourceRequirement

Hashable ResourceRequirement Source # 
Instance details

Defined in Amazonka.ECS.Types.ResourceRequirement

type Rep ResourceRequirement Source # 
Instance details

Defined in Amazonka.ECS.Types.ResourceRequirement

type Rep ResourceRequirement = D1 ('MetaData "ResourceRequirement" "Amazonka.ECS.Types.ResourceRequirement" "amazonka-ecs-2.0-3xFxVqi9x5nBZ44jBEC5G8" 'False) (C1 ('MetaCons "ResourceRequirement'" 'PrefixI 'True) (S1 ('MetaSel ('Just "value") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 Text) :*: S1 ('MetaSel ('Just "type'") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 ResourceType)))

newResourceRequirement Source #

Create a value of ResourceRequirement with all optional fields omitted.

Use generic-lens or optics to modify other optional fields.

The following record fields are available, with the corresponding lenses provided for backwards compatibility:

$sel:value:ResourceRequirement', resourceRequirement_value - The value for the specified resource type.

If the GPU type is used, the value is the number of physical GPUs the Amazon ECS container agent reserves for the container. The number of GPUs that's reserved for all containers in a task can't exceed the number of available GPUs on the container instance that the task is launched on.

If the InferenceAccelerator type is used, the value matches the deviceName for an InferenceAccelerator specified in a task definition.

$sel:type':ResourceRequirement', resourceRequirement_type - The type of resource to assign to a container. The supported values are GPU or InferenceAccelerator.

resourceRequirement_value :: Lens' ResourceRequirement Text Source #

The value for the specified resource type.

If the GPU type is used, the value is the number of physical GPUs the Amazon ECS container agent reserves for the container. The number of GPUs that's reserved for all containers in a task can't exceed the number of available GPUs on the container instance that the task is launched on.

If the InferenceAccelerator type is used, the value matches the deviceName for an InferenceAccelerator specified in a task definition.

resourceRequirement_type :: Lens' ResourceRequirement ResourceType Source #

The type of resource to assign to a container. The supported values are GPU or InferenceAccelerator.