Class CfnJobDefinition.EcsTaskPropertiesProperty.Builder
- All Implemented Interfaces:
software.amazon.jsii.Builder<CfnJobDefinition.EcsTaskPropertiesProperty>
- Enclosing interface:
CfnJobDefinition.EcsTaskPropertiesProperty
CfnJobDefinition.EcsTaskPropertiesProperty
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionbuild()
Builds the configured instance.containers
(List<? extends Object> containers) Sets the value ofCfnJobDefinition.EcsTaskPropertiesProperty.getContainers()
containers
(IResolvable containers) Sets the value ofCfnJobDefinition.EcsTaskPropertiesProperty.getContainers()
ephemeralStorage
(IResolvable ephemeralStorage) Sets the value ofCfnJobDefinition.EcsTaskPropertiesProperty.getEphemeralStorage()
ephemeralStorage
(CfnJobDefinition.EphemeralStorageProperty ephemeralStorage) Sets the value ofCfnJobDefinition.EcsTaskPropertiesProperty.getEphemeralStorage()
executionRoleArn
(String executionRoleArn) Sets the value ofCfnJobDefinition.EcsTaskPropertiesProperty.getExecutionRoleArn()
Sets the value ofCfnJobDefinition.EcsTaskPropertiesProperty.getIpcMode()
networkConfiguration
(IResolvable networkConfiguration) Sets the value ofCfnJobDefinition.EcsTaskPropertiesProperty.getNetworkConfiguration()
networkConfiguration
(CfnJobDefinition.NetworkConfigurationProperty networkConfiguration) Sets the value ofCfnJobDefinition.EcsTaskPropertiesProperty.getNetworkConfiguration()
Sets the value ofCfnJobDefinition.EcsTaskPropertiesProperty.getPidMode()
platformVersion
(String platformVersion) Sets the value ofCfnJobDefinition.EcsTaskPropertiesProperty.getPlatformVersion()
runtimePlatform
(IResolvable runtimePlatform) Sets the value ofCfnJobDefinition.EcsTaskPropertiesProperty.getRuntimePlatform()
runtimePlatform
(CfnJobDefinition.RuntimePlatformProperty runtimePlatform) Sets the value ofCfnJobDefinition.EcsTaskPropertiesProperty.getRuntimePlatform()
taskRoleArn
(String taskRoleArn) Sets the value ofCfnJobDefinition.EcsTaskPropertiesProperty.getTaskRoleArn()
Sets the value ofCfnJobDefinition.EcsTaskPropertiesProperty.getVolumes()
volumes
(IResolvable volumes) Sets the value ofCfnJobDefinition.EcsTaskPropertiesProperty.getVolumes()
-
Constructor Details
-
Builder
public Builder()
-
-
Method Details
-
containers
@Stability(Stable) public CfnJobDefinition.EcsTaskPropertiesProperty.Builder containers(IResolvable containers) Sets the value ofCfnJobDefinition.EcsTaskPropertiesProperty.getContainers()
- Parameters:
containers
- This object is a list of containers.- Returns:
this
-
containers
@Stability(Stable) public CfnJobDefinition.EcsTaskPropertiesProperty.Builder containers(List<? extends Object> containers) Sets the value ofCfnJobDefinition.EcsTaskPropertiesProperty.getContainers()
- Parameters:
containers
- This object is a list of containers.- Returns:
this
-
ephemeralStorage
@Stability(Stable) public CfnJobDefinition.EcsTaskPropertiesProperty.Builder ephemeralStorage(IResolvable ephemeralStorage) Sets the value ofCfnJobDefinition.EcsTaskPropertiesProperty.getEphemeralStorage()
- Parameters:
ephemeralStorage
- The amount of ephemeral storage to allocate for the task. This parameter is used to expand the total amount of ephemeral storage available, beyond the default amount, for tasks hosted on AWS Fargate .- Returns:
this
-
ephemeralStorage
@Stability(Stable) public CfnJobDefinition.EcsTaskPropertiesProperty.Builder ephemeralStorage(CfnJobDefinition.EphemeralStorageProperty ephemeralStorage) Sets the value ofCfnJobDefinition.EcsTaskPropertiesProperty.getEphemeralStorage()
- Parameters:
ephemeralStorage
- The amount of ephemeral storage to allocate for the task. This parameter is used to expand the total amount of ephemeral storage available, beyond the default amount, for tasks hosted on AWS Fargate .- Returns:
this
-
executionRoleArn
@Stability(Stable) public CfnJobDefinition.EcsTaskPropertiesProperty.Builder executionRoleArn(String executionRoleArn) Sets the value ofCfnJobDefinition.EcsTaskPropertiesProperty.getExecutionRoleArn()
- Parameters:
executionRoleArn
- The Amazon Resource Name (ARN) of the execution role that AWS Batch can assume. For jobs that run on Fargate resources, you must provide an execution role. For more information, see AWS Batch execution IAM role in the AWS Batch User Guide .- Returns:
this
-
ipcMode
@Stability(Stable) public CfnJobDefinition.EcsTaskPropertiesProperty.Builder ipcMode(String ipcMode) Sets the value ofCfnJobDefinition.EcsTaskPropertiesProperty.getIpcMode()
- Parameters:
ipcMode
- The IPC resource namespace to use for the containers in the task. The valid values arehost
,task
, ornone
.If
host
is specified, all containers within the tasks that specified thehost
IPC mode on the same container instance share the same IPC resources with the host Amazon EC2 instance.If
task
is specified, all containers within the specifiedtask
share the same IPC resources.If
none
is specified, the IPC resources within the containers of a task are private, and are not shared with other containers in a task or on the container instance.If no value is specified, then the IPC resource namespace sharing depends on the Docker daemon setting on the container instance. For more information, see IPC settings in the Docker run reference.
- Returns:
this
-
networkConfiguration
@Stability(Stable) public CfnJobDefinition.EcsTaskPropertiesProperty.Builder networkConfiguration(IResolvable networkConfiguration) Sets the value ofCfnJobDefinition.EcsTaskPropertiesProperty.getNetworkConfiguration()
- Parameters:
networkConfiguration
- The network configuration for jobs that are running on Fargate resources. Jobs that are running on Amazon EC2 resources must not specify this parameter.- Returns:
this
-
networkConfiguration
@Stability(Stable) public CfnJobDefinition.EcsTaskPropertiesProperty.Builder networkConfiguration(CfnJobDefinition.NetworkConfigurationProperty networkConfiguration) Sets the value ofCfnJobDefinition.EcsTaskPropertiesProperty.getNetworkConfiguration()
- Parameters:
networkConfiguration
- The network configuration for jobs that are running on Fargate resources. Jobs that are running on Amazon EC2 resources must not specify this parameter.- Returns:
this
-
pidMode
@Stability(Stable) public CfnJobDefinition.EcsTaskPropertiesProperty.Builder pidMode(String pidMode) Sets the value ofCfnJobDefinition.EcsTaskPropertiesProperty.getPidMode()
- Parameters:
pidMode
- The process namespace to use for the containers in the task. The valid values arehost
ortask
. For example, monitoring sidecars might needpidMode
to access information about other containers running in the same task.If
host
is specified, all containers within the tasks that specified thehost
PID mode on the same container instance share the process namespace with the host Amazon EC2 instance.If
task
is specified, all containers within the specified task share the same process namespace.If no value is specified, the default is a private namespace for each container. For more information, see PID settings in the Docker run reference.
- Returns:
this
-
platformVersion
@Stability(Stable) public CfnJobDefinition.EcsTaskPropertiesProperty.Builder platformVersion(String platformVersion) Sets the value ofCfnJobDefinition.EcsTaskPropertiesProperty.getPlatformVersion()
- Parameters:
platformVersion
- The Fargate platform version where the jobs are running. A platform version is specified only for jobs that are running on Fargate resources. If one isn't specified, theLATEST
platform version is used by default. This uses a recent, approved version of the Fargate platform for compute resources. For more information, see AWS Fargate platform versions in the Amazon Elastic Container Service Developer Guide .- Returns:
this
-
runtimePlatform
@Stability(Stable) public CfnJobDefinition.EcsTaskPropertiesProperty.Builder runtimePlatform(IResolvable runtimePlatform) Sets the value ofCfnJobDefinition.EcsTaskPropertiesProperty.getRuntimePlatform()
- Parameters:
runtimePlatform
- An object that represents the compute environment architecture for AWS Batch jobs on Fargate.- Returns:
this
-
runtimePlatform
@Stability(Stable) public CfnJobDefinition.EcsTaskPropertiesProperty.Builder runtimePlatform(CfnJobDefinition.RuntimePlatformProperty runtimePlatform) Sets the value ofCfnJobDefinition.EcsTaskPropertiesProperty.getRuntimePlatform()
- Parameters:
runtimePlatform
- An object that represents the compute environment architecture for AWS Batch jobs on Fargate.- Returns:
this
-
taskRoleArn
@Stability(Stable) public CfnJobDefinition.EcsTaskPropertiesProperty.Builder taskRoleArn(String taskRoleArn) Sets the value ofCfnJobDefinition.EcsTaskPropertiesProperty.getTaskRoleArn()
- Parameters:
taskRoleArn
- The Amazon Resource Name (ARN) that's associated with the Amazon ECS task.This is object is comparable to ContainerProperties:jobRoleArn .
- Returns:
this
-
volumes
@Stability(Stable) public CfnJobDefinition.EcsTaskPropertiesProperty.Builder volumes(IResolvable volumes) Sets the value ofCfnJobDefinition.EcsTaskPropertiesProperty.getVolumes()
- Parameters:
volumes
- A list of volumes that are associated with the job.- Returns:
this
-
volumes
@Stability(Stable) public CfnJobDefinition.EcsTaskPropertiesProperty.Builder volumes(List<? extends Object> volumes) Sets the value ofCfnJobDefinition.EcsTaskPropertiesProperty.getVolumes()
- Parameters:
volumes
- A list of volumes that are associated with the job.- Returns:
this
-
build
Builds the configured instance.- Specified by:
build
in interfacesoftware.amazon.jsii.Builder<CfnJobDefinition.EcsTaskPropertiesProperty>
- Returns:
- a new instance of
CfnJobDefinition.EcsTaskPropertiesProperty
- Throws:
NullPointerException
- if any required attribute was not provided
-