Class CfnDaemonTaskDefinition.DaemonContainerDefinitionProperty.Builder
- All Implemented Interfaces:
software.amazon.jsii.Builder<CfnDaemonTaskDefinition.DaemonContainerDefinitionProperty>
- Enclosing interface:
CfnDaemonTaskDefinition.DaemonContainerDefinitionProperty
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbuild()Builds the configured instance.Sets the value ofCfnDaemonTaskDefinition.DaemonContainerDefinitionProperty.getCommand()Sets the value ofCfnDaemonTaskDefinition.DaemonContainerDefinitionProperty.getCpu()Sets the value ofCfnDaemonTaskDefinition.DaemonContainerDefinitionProperty.getDependsOn()dependsOn(IResolvable dependsOn) Sets the value ofCfnDaemonTaskDefinition.DaemonContainerDefinitionProperty.getDependsOn()entryPoint(List<String> entryPoint) environment(List<? extends Object> environment) environment(IResolvable environment) environmentFiles(List<? extends Object> environmentFiles) environmentFiles(IResolvable environmentFiles) Sets the value ofCfnDaemonTaskDefinition.DaemonContainerDefinitionProperty.getEssential()essential(IResolvable essential) Sets the value ofCfnDaemonTaskDefinition.DaemonContainerDefinitionProperty.getEssential()firelensConfiguration(IResolvable firelensConfiguration) firelensConfiguration(CfnDaemonTaskDefinition.FirelensConfigurationProperty firelensConfiguration) healthCheck(IResolvable healthCheck) healthCheck(CfnDaemonTaskDefinition.HealthCheckProperty healthCheck) Sets the value ofCfnDaemonTaskDefinition.DaemonContainerDefinitionProperty.getImage()interactive(Boolean interactive) interactive(IResolvable interactive) linuxParameters(IResolvable linuxParameters) linuxParameters(CfnDaemonTaskDefinition.LinuxParametersProperty linuxParameters) logConfiguration(IResolvable logConfiguration) logConfiguration(CfnDaemonTaskDefinition.LogConfigurationProperty logConfiguration) Sets the value ofCfnDaemonTaskDefinition.DaemonContainerDefinitionProperty.getMemory()memoryReservation(Number memoryReservation) mountPoints(List<? extends Object> mountPoints) mountPoints(IResolvable mountPoints) Sets the value ofCfnDaemonTaskDefinition.DaemonContainerDefinitionProperty.getName()privileged(Boolean privileged) privileged(IResolvable privileged) pseudoTerminal(Boolean pseudoTerminal) pseudoTerminal(IResolvable pseudoTerminal) readonlyRootFilesystem(Boolean readonlyRootFilesystem) readonlyRootFilesystem(IResolvable readonlyRootFilesystem) repositoryCredentials(IResolvable repositoryCredentials) repositoryCredentials(CfnDaemonTaskDefinition.RepositoryCredentialsProperty repositoryCredentials) restartPolicy(IResolvable restartPolicy) restartPolicy(CfnDaemonTaskDefinition.RestartPolicyProperty restartPolicy) Sets the value ofCfnDaemonTaskDefinition.DaemonContainerDefinitionProperty.getSecrets()secrets(IResolvable secrets) Sets the value ofCfnDaemonTaskDefinition.DaemonContainerDefinitionProperty.getSecrets()startTimeout(Number startTimeout) stopTimeout(Number stopTimeout) systemControls(List<? extends Object> systemControls) systemControls(IResolvable systemControls) Sets the value ofCfnDaemonTaskDefinition.DaemonContainerDefinitionProperty.getUlimits()ulimits(IResolvable ulimits) Sets the value ofCfnDaemonTaskDefinition.DaemonContainerDefinitionProperty.getUlimits()Sets the value ofCfnDaemonTaskDefinition.DaemonContainerDefinitionProperty.getUser()workingDirectory(String workingDirectory)
-
Constructor Details
-
Builder
public Builder()
-
-
Method Details
-
image
@Stability(Stable) public CfnDaemonTaskDefinition.DaemonContainerDefinitionProperty.Builder image(String image) Sets the value ofCfnDaemonTaskDefinition.DaemonContainerDefinitionProperty.getImage()- Parameters:
image- The image used to start the container. This parameter is required. This string is passed directly to the Docker daemon. Images in the Docker Hub registry are available by default. Other repositories are specified with eitherrepository-url/image:tagorrepository-url/image@digest.- Returns:
this
-
name
@Stability(Stable) public CfnDaemonTaskDefinition.DaemonContainerDefinitionProperty.Builder name(String name) Sets the value ofCfnDaemonTaskDefinition.DaemonContainerDefinitionProperty.getName()- Parameters:
name- The name of the container. This parameter is required. Up to 255 letters (uppercase and lowercase), numbers, underscores, and hyphens are allowed.- Returns:
this
-
command
@Stability(Stable) public CfnDaemonTaskDefinition.DaemonContainerDefinitionProperty.Builder command(List<String> command) Sets the value ofCfnDaemonTaskDefinition.DaemonContainerDefinitionProperty.getCommand()- Parameters:
command- The command that's passed to the container.- Returns:
this
-
cpu
@Stability(Stable) public CfnDaemonTaskDefinition.DaemonContainerDefinitionProperty.Builder cpu(Number cpu) Sets the value ofCfnDaemonTaskDefinition.DaemonContainerDefinitionProperty.getCpu()- Parameters:
cpu- The number ofcpuunits reserved for the container.- Returns:
this
-
dependsOn
@Stability(Stable) public CfnDaemonTaskDefinition.DaemonContainerDefinitionProperty.Builder dependsOn(IResolvable dependsOn) Sets the value ofCfnDaemonTaskDefinition.DaemonContainerDefinitionProperty.getDependsOn()- Parameters:
dependsOn- The dependencies defined for container startup and shutdown. A container can contain multiple dependencies on other containers in a task definition.- Returns:
this
-
dependsOn
@Stability(Stable) public CfnDaemonTaskDefinition.DaemonContainerDefinitionProperty.Builder dependsOn(List<? extends Object> dependsOn) Sets the value ofCfnDaemonTaskDefinition.DaemonContainerDefinitionProperty.getDependsOn()- Parameters:
dependsOn- The dependencies defined for container startup and shutdown. A container can contain multiple dependencies on other containers in a task definition.- Returns:
this
-
entryPoint
@Stability(Stable) public CfnDaemonTaskDefinition.DaemonContainerDefinitionProperty.Builder entryPoint(List<String> entryPoint) - Parameters:
entryPoint- The entry point that's passed to the container.- Returns:
this
-
environment
@Stability(Stable) public CfnDaemonTaskDefinition.DaemonContainerDefinitionProperty.Builder environment(IResolvable environment) - Parameters:
environment- The environment variables to pass to a container.- Returns:
this
-
environment
@Stability(Stable) public CfnDaemonTaskDefinition.DaemonContainerDefinitionProperty.Builder environment(List<? extends Object> environment) - Parameters:
environment- The environment variables to pass to a container.- Returns:
this
-
environmentFiles
@Stability(Stable) public CfnDaemonTaskDefinition.DaemonContainerDefinitionProperty.Builder environmentFiles(IResolvable environmentFiles) - Parameters:
environmentFiles- A list of files containing the environment variables to pass to a container.- Returns:
this
-
environmentFiles
@Stability(Stable) public CfnDaemonTaskDefinition.DaemonContainerDefinitionProperty.Builder environmentFiles(List<? extends Object> environmentFiles) - Parameters:
environmentFiles- A list of files containing the environment variables to pass to a container.- Returns:
this
-
essential
@Stability(Stable) public CfnDaemonTaskDefinition.DaemonContainerDefinitionProperty.Builder essential(Boolean essential) Sets the value ofCfnDaemonTaskDefinition.DaemonContainerDefinitionProperty.getEssential()- Parameters:
essential- If theessentialparameter of a container is marked astrue, and that container fails or stops for any reason, all other containers that are part of the task are stopped.- Returns:
this
-
essential
@Stability(Stable) public CfnDaemonTaskDefinition.DaemonContainerDefinitionProperty.Builder essential(IResolvable essential) Sets the value ofCfnDaemonTaskDefinition.DaemonContainerDefinitionProperty.getEssential()- Parameters:
essential- If theessentialparameter of a container is marked astrue, and that container fails or stops for any reason, all other containers that are part of the task are stopped.- Returns:
this
-
firelensConfiguration
@Stability(Stable) public CfnDaemonTaskDefinition.DaemonContainerDefinitionProperty.Builder firelensConfiguration(IResolvable firelensConfiguration) Sets the value ofCfnDaemonTaskDefinition.DaemonContainerDefinitionProperty.getFirelensConfiguration()- Parameters:
firelensConfiguration- The FireLens configuration for the container. This is used to specify and configure a log router for container logs. For more information, see Custom log routing in the Amazon Elastic Container Service Developer Guide.- Returns:
this
-
firelensConfiguration
@Stability(Stable) public CfnDaemonTaskDefinition.DaemonContainerDefinitionProperty.Builder firelensConfiguration(CfnDaemonTaskDefinition.FirelensConfigurationProperty firelensConfiguration) Sets the value ofCfnDaemonTaskDefinition.DaemonContainerDefinitionProperty.getFirelensConfiguration()- Parameters:
firelensConfiguration- The FireLens configuration for the container. This is used to specify and configure a log router for container logs. For more information, see Custom log routing in the Amazon Elastic Container Service Developer Guide.- Returns:
this
-
healthCheck
@Stability(Stable) public CfnDaemonTaskDefinition.DaemonContainerDefinitionProperty.Builder healthCheck(IResolvable healthCheck) - Parameters:
healthCheck- An object representing a container health check. Health check parameters that are specified in a container definition override any Docker health checks that exist in the container image (such as those specified in a parent image or from the image's Dockerfile). This configuration maps to theHEALTHCHECKparameter of docker run. The Amazon ECS container agent only monitors and reports on the health checks specified in the task definition. Amazon ECS does not monitor Docker health checks that are embedded in a container image and not specified in the container definition. Health check parameters that are specified in a container definition override any Docker health checks that exist in the container image. You can view the health status of both individual containers and a task with the DescribeTasks API operation or when viewing the task details in the console. The health check is designed to make sure that your containers survive agent restarts, upgrades, or temporary unavailability. Amazon ECS performs health checks on containers with the default that launched the container instance or the task. The following describes the possiblehealthStatusvalues for a container:HEALTHY-The container health check has passed successfully.UNHEALTHY-The container health check has failed.UNKNOWN-The container health check is being evaluated, there's no container health check defined, or Amazon ECS doesn't have the health status of the container.
The following describes the possible
healthStatusvalues based on the container health checker status of essential containers in the task with the following priority order (high to low):UNHEALTHY-One or more essential containers have failed their health check.UNKNOWN-Any essential container running within the task is in anUNKNOWNstate and no other essential containers have anUNHEALTHYstate.HEALTHY-All essential containers within the task have passed their health checks.
Consider the following task health example with 2 containers.
- If Container1 is
UNHEALTHYand Container2 isUNKNOWN, the task health isUNHEALTHY. - If Container1 is
UNHEALTHYand Container2 isHEALTHY, the task health isUNHEALTHY. - If Container1 is
HEALTHYand Container2 isUNKNOWN, the task health isUNKNOWN. - If Container1 is
HEALTHYand Container2 isHEALTHY, the task health isHEALTHY.
Consider the following task health example with 3 containers.
- If Container1 is
UNHEALTHYand Container2 isUNKNOWN, and Container3 isUNKNOWN, the task health isUNHEALTHY. - If Container1 is
UNHEALTHYand Container2 isUNKNOWN, and Container3 isHEALTHY, the task health isUNHEALTHY. - If Container1 is
UNHEALTHYand Container2 isHEALTHY, and Container3 isHEALTHY, the task health isUNHEALTHY. - If Container1 is
HEALTHYand Container2 isUNKNOWN, and Container3 isHEALTHY, the task health isUNKNOWN. - If Container1 is
HEALTHYand Container2 isUNKNOWN, and Container3 isUNKNOWN, the task health isUNKNOWN. - If Container1 is
HEALTHYand Container2 isHEALTHY, and Container3 isHEALTHY, the task health isHEALTHY.
If a task is run manually, and not as part of a service, the task will continue its lifecycle regardless of its health status. For tasks that are part of a service, if the task reports as unhealthy then the task will be stopped and the service scheduler will replace it. When a container health check fails for a task that is part of a service, the following process occurs:
- The task is marked as
UNHEALTHY. - The unhealthy task will be stopped, and during the stopping process, it will go through the following states:
DEACTIVATING- In this state, Amazon ECS performs additional steps before stopping the task. For example, for tasks that are part of services configured to use Elastic Load Balancing target groups, target groups will be deregistered in this state.STOPPING- The task is in the process of being stopped.DEPROVISIONING- Resources associated with the task are being cleaned up.STOPPED- The task has been completely stopped.
- After the old task stops, a new task will be launched to ensure service operation, and the new task will go through the following lifecycle:
PROVISIONING- Resources required for the task are being provisioned.PENDING- The task is waiting to be placed on a container instance.ACTIVATING- In this state, Amazon ECS pulls container images, creates containers, configures task networking, registers load balancer target groups, and configures service discovery status.RUNNING- The task is running and performing its work.
For more detailed information about task lifecycle states, see Task lifecycle in the Amazon Elastic Container Service Developer Guide. The following are notes about container health check support:
- If the Amazon ECS container agent becomes disconnected from the Amazon ECS service, this won't cause a container to transition to an
UNHEALTHYstatus. This is by design, to ensure that containers remain running during agent restarts or temporary unavailability. The health check status is the "last heard from" response from the Amazon ECS agent, so if the container was consideredHEALTHYprior to the disconnect, that status will remain until the agent reconnects and another health check occurs. There are no assumptions made about the status of the container health checks. - Container health checks require version
1.17.0or greater of the Amazon ECS container agent. For more information, see Updating the Amazon ECS container agent. - Container health checks are supported for Fargate tasks if you're using platform version
1.1.0or greater. For more information, see platform versions. - Container health checks aren't supported for tasks that are part of a service that's configured to use a Classic Load Balancer.
For an example of how to specify a task definition with multiple containers where container dependency is specified, see Container dependency in the Amazon Elastic Container Service Developer Guide.
- Returns:
this
-
healthCheck
@Stability(Stable) public CfnDaemonTaskDefinition.DaemonContainerDefinitionProperty.Builder healthCheck(CfnDaemonTaskDefinition.HealthCheckProperty healthCheck) - Parameters:
healthCheck- An object representing a container health check. Health check parameters that are specified in a container definition override any Docker health checks that exist in the container image (such as those specified in a parent image or from the image's Dockerfile). This configuration maps to theHEALTHCHECKparameter of docker run. The Amazon ECS container agent only monitors and reports on the health checks specified in the task definition. Amazon ECS does not monitor Docker health checks that are embedded in a container image and not specified in the container definition. Health check parameters that are specified in a container definition override any Docker health checks that exist in the container image. You can view the health status of both individual containers and a task with the DescribeTasks API operation or when viewing the task details in the console. The health check is designed to make sure that your containers survive agent restarts, upgrades, or temporary unavailability. Amazon ECS performs health checks on containers with the default that launched the container instance or the task. The following describes the possiblehealthStatusvalues for a container:HEALTHY-The container health check has passed successfully.UNHEALTHY-The container health check has failed.UNKNOWN-The container health check is being evaluated, there's no container health check defined, or Amazon ECS doesn't have the health status of the container.
The following describes the possible
healthStatusvalues based on the container health checker status of essential containers in the task with the following priority order (high to low):UNHEALTHY-One or more essential containers have failed their health check.UNKNOWN-Any essential container running within the task is in anUNKNOWNstate and no other essential containers have anUNHEALTHYstate.HEALTHY-All essential containers within the task have passed their health checks.
Consider the following task health example with 2 containers.
- If Container1 is
UNHEALTHYand Container2 isUNKNOWN, the task health isUNHEALTHY. - If Container1 is
UNHEALTHYand Container2 isHEALTHY, the task health isUNHEALTHY. - If Container1 is
HEALTHYand Container2 isUNKNOWN, the task health isUNKNOWN. - If Container1 is
HEALTHYand Container2 isHEALTHY, the task health isHEALTHY.
Consider the following task health example with 3 containers.
- If Container1 is
UNHEALTHYand Container2 isUNKNOWN, and Container3 isUNKNOWN, the task health isUNHEALTHY. - If Container1 is
UNHEALTHYand Container2 isUNKNOWN, and Container3 isHEALTHY, the task health isUNHEALTHY. - If Container1 is
UNHEALTHYand Container2 isHEALTHY, and Container3 isHEALTHY, the task health isUNHEALTHY. - If Container1 is
HEALTHYand Container2 isUNKNOWN, and Container3 isHEALTHY, the task health isUNKNOWN. - If Container1 is
HEALTHYand Container2 isUNKNOWN, and Container3 isUNKNOWN, the task health isUNKNOWN. - If Container1 is
HEALTHYand Container2 isHEALTHY, and Container3 isHEALTHY, the task health isHEALTHY.
If a task is run manually, and not as part of a service, the task will continue its lifecycle regardless of its health status. For tasks that are part of a service, if the task reports as unhealthy then the task will be stopped and the service scheduler will replace it. When a container health check fails for a task that is part of a service, the following process occurs:
- The task is marked as
UNHEALTHY. - The unhealthy task will be stopped, and during the stopping process, it will go through the following states:
DEACTIVATING- In this state, Amazon ECS performs additional steps before stopping the task. For example, for tasks that are part of services configured to use Elastic Load Balancing target groups, target groups will be deregistered in this state.STOPPING- The task is in the process of being stopped.DEPROVISIONING- Resources associated with the task are being cleaned up.STOPPED- The task has been completely stopped.
- After the old task stops, a new task will be launched to ensure service operation, and the new task will go through the following lifecycle:
PROVISIONING- Resources required for the task are being provisioned.PENDING- The task is waiting to be placed on a container instance.ACTIVATING- In this state, Amazon ECS pulls container images, creates containers, configures task networking, registers load balancer target groups, and configures service discovery status.RUNNING- The task is running and performing its work.
For more detailed information about task lifecycle states, see Task lifecycle in the Amazon Elastic Container Service Developer Guide. The following are notes about container health check support:
- If the Amazon ECS container agent becomes disconnected from the Amazon ECS service, this won't cause a container to transition to an
UNHEALTHYstatus. This is by design, to ensure that containers remain running during agent restarts or temporary unavailability. The health check status is the "last heard from" response from the Amazon ECS agent, so if the container was consideredHEALTHYprior to the disconnect, that status will remain until the agent reconnects and another health check occurs. There are no assumptions made about the status of the container health checks. - Container health checks require version
1.17.0or greater of the Amazon ECS container agent. For more information, see Updating the Amazon ECS container agent. - Container health checks are supported for Fargate tasks if you're using platform version
1.1.0or greater. For more information, see platform versions. - Container health checks aren't supported for tasks that are part of a service that's configured to use a Classic Load Balancer.
For an example of how to specify a task definition with multiple containers where container dependency is specified, see Container dependency in the Amazon Elastic Container Service Developer Guide.
- Returns:
this
-
interactive
@Stability(Stable) public CfnDaemonTaskDefinition.DaemonContainerDefinitionProperty.Builder interactive(Boolean interactive) - Parameters:
interactive- When this parameter istrue, you can deploy containerized applications that requirestdinor attyto be allocated.- Returns:
this
-
interactive
@Stability(Stable) public CfnDaemonTaskDefinition.DaemonContainerDefinitionProperty.Builder interactive(IResolvable interactive) - Parameters:
interactive- When this parameter istrue, you can deploy containerized applications that requirestdinor attyto be allocated.- Returns:
this
-
linuxParameters
@Stability(Stable) public CfnDaemonTaskDefinition.DaemonContainerDefinitionProperty.Builder linuxParameters(IResolvable linuxParameters) - Parameters:
linuxParameters- The Linux-specific options that are applied to the container, such as Linux KernelCapabilities.- Returns:
this
-
linuxParameters
@Stability(Stable) public CfnDaemonTaskDefinition.DaemonContainerDefinitionProperty.Builder linuxParameters(CfnDaemonTaskDefinition.LinuxParametersProperty linuxParameters) - Parameters:
linuxParameters- The Linux-specific options that are applied to the container, such as Linux KernelCapabilities.- Returns:
this
-
logConfiguration
@Stability(Stable) public CfnDaemonTaskDefinition.DaemonContainerDefinitionProperty.Builder logConfiguration(IResolvable logConfiguration) - Parameters:
logConfiguration- The log configuration for the container. This parameter maps toLogConfigin the docker container create command and the--log-driveroption to docker run. By default, containers use the same logging driver that the Docker daemon uses. However, the container might use a different logging driver than the Docker daemon by specifying a log driver configuration in the container definition. Understand the following when specifying a log configuration for your containers.- Amazon ECS currently supports a subset of the logging drivers available to the Docker daemon. Additional log drivers may be available in future releases of the Amazon ECS container agent.
For tasks on FARGATElong, the supported log drivers are
awslogs,splunk, andawsfirelens. For tasks hosted on Amazon EC2 instances, the supported log drivers areawslogs,fluentd,gelf,json-file,journald,syslog,splunk, andawsfirelens. - This parameter requires version 1.18 of the Docker Remote API or greater on your container instance.
- For tasks that are hosted on Amazon EC2 instances, the Amazon ECS container agent must register the available logging drivers with the
ECS_AVAILABLE_LOGGING_DRIVERSenvironment variable before containers placed on that instance can use these log configuration options. For more information, see Amazon ECS container agent configuration in the Amazon Elastic Container Service Developer Guide. - For tasks that are on FARGATElong, because you don't have access to the underlying infrastructure your tasks are hosted on, any additional software needed must be installed outside of the task. For example, the Fluentd output aggregators or a remote host running Logstash to send Gelf logs to.
- Amazon ECS currently supports a subset of the logging drivers available to the Docker daemon. Additional log drivers may be available in future releases of the Amazon ECS container agent.
For tasks on FARGATElong, the supported log drivers are
- Returns:
this
-
logConfiguration
@Stability(Stable) public CfnDaemonTaskDefinition.DaemonContainerDefinitionProperty.Builder logConfiguration(CfnDaemonTaskDefinition.LogConfigurationProperty logConfiguration) - Parameters:
logConfiguration- The log configuration for the container. This parameter maps toLogConfigin the docker container create command and the--log-driveroption to docker run. By default, containers use the same logging driver that the Docker daemon uses. However, the container might use a different logging driver than the Docker daemon by specifying a log driver configuration in the container definition. Understand the following when specifying a log configuration for your containers.- Amazon ECS currently supports a subset of the logging drivers available to the Docker daemon. Additional log drivers may be available in future releases of the Amazon ECS container agent.
For tasks on FARGATElong, the supported log drivers are
awslogs,splunk, andawsfirelens. For tasks hosted on Amazon EC2 instances, the supported log drivers areawslogs,fluentd,gelf,json-file,journald,syslog,splunk, andawsfirelens. - This parameter requires version 1.18 of the Docker Remote API or greater on your container instance.
- For tasks that are hosted on Amazon EC2 instances, the Amazon ECS container agent must register the available logging drivers with the
ECS_AVAILABLE_LOGGING_DRIVERSenvironment variable before containers placed on that instance can use these log configuration options. For more information, see Amazon ECS container agent configuration in the Amazon Elastic Container Service Developer Guide. - For tasks that are on FARGATElong, because you don't have access to the underlying infrastructure your tasks are hosted on, any additional software needed must be installed outside of the task. For example, the Fluentd output aggregators or a remote host running Logstash to send Gelf logs to.
- Amazon ECS currently supports a subset of the logging drivers available to the Docker daemon. Additional log drivers may be available in future releases of the Amazon ECS container agent.
For tasks on FARGATElong, the supported log drivers are
- Returns:
this
-
memory
@Stability(Stable) public CfnDaemonTaskDefinition.DaemonContainerDefinitionProperty.Builder memory(Number memory) Sets the value ofCfnDaemonTaskDefinition.DaemonContainerDefinitionProperty.getMemory()- Parameters:
memory- The amount (in MiB) of memory to present to the container. If the container attempts to exceed the memory specified here, the container is killed.- Returns:
this
-
memoryReservation
@Stability(Stable) public CfnDaemonTaskDefinition.DaemonContainerDefinitionProperty.Builder memoryReservation(Number memoryReservation) - Parameters:
memoryReservation- The soft limit (in MiB) of memory to reserve for the container.- Returns:
this
-
mountPoints
@Stability(Stable) public CfnDaemonTaskDefinition.DaemonContainerDefinitionProperty.Builder mountPoints(IResolvable mountPoints) - Parameters:
mountPoints- The mount points for data volumes in your container.- Returns:
this
-
mountPoints
@Stability(Stable) public CfnDaemonTaskDefinition.DaemonContainerDefinitionProperty.Builder mountPoints(List<? extends Object> mountPoints) - Parameters:
mountPoints- The mount points for data volumes in your container.- Returns:
this
-
privileged
@Stability(Stable) public CfnDaemonTaskDefinition.DaemonContainerDefinitionProperty.Builder privileged(Boolean privileged) - Parameters:
privileged- When this parameter is true, the container is given elevated privileges on the host container instance (similar to therootuser).- Returns:
this
-
privileged
@Stability(Stable) public CfnDaemonTaskDefinition.DaemonContainerDefinitionProperty.Builder privileged(IResolvable privileged) - Parameters:
privileged- When this parameter is true, the container is given elevated privileges on the host container instance (similar to therootuser).- Returns:
this
-
pseudoTerminal
@Stability(Stable) public CfnDaemonTaskDefinition.DaemonContainerDefinitionProperty.Builder pseudoTerminal(Boolean pseudoTerminal) - Parameters:
pseudoTerminal- When this parameter istrue, a TTY is allocated.- Returns:
this
-
pseudoTerminal
@Stability(Stable) public CfnDaemonTaskDefinition.DaemonContainerDefinitionProperty.Builder pseudoTerminal(IResolvable pseudoTerminal) - Parameters:
pseudoTerminal- When this parameter istrue, a TTY is allocated.- Returns:
this
-
readonlyRootFilesystem
@Stability(Stable) public CfnDaemonTaskDefinition.DaemonContainerDefinitionProperty.Builder readonlyRootFilesystem(Boolean readonlyRootFilesystem) Sets the value ofCfnDaemonTaskDefinition.DaemonContainerDefinitionProperty.getReadonlyRootFilesystem()- Parameters:
readonlyRootFilesystem- When this parameter is true, the container is given read-only access to its root file system.- Returns:
this
-
readonlyRootFilesystem
@Stability(Stable) public CfnDaemonTaskDefinition.DaemonContainerDefinitionProperty.Builder readonlyRootFilesystem(IResolvable readonlyRootFilesystem) Sets the value ofCfnDaemonTaskDefinition.DaemonContainerDefinitionProperty.getReadonlyRootFilesystem()- Parameters:
readonlyRootFilesystem- When this parameter is true, the container is given read-only access to its root file system.- Returns:
this
-
repositoryCredentials
@Stability(Stable) public CfnDaemonTaskDefinition.DaemonContainerDefinitionProperty.Builder repositoryCredentials(IResolvable repositoryCredentials) Sets the value ofCfnDaemonTaskDefinition.DaemonContainerDefinitionProperty.getRepositoryCredentials()- Parameters:
repositoryCredentials- The repository credentials for private registry authentication.- Returns:
this
-
repositoryCredentials
@Stability(Stable) public CfnDaemonTaskDefinition.DaemonContainerDefinitionProperty.Builder repositoryCredentials(CfnDaemonTaskDefinition.RepositoryCredentialsProperty repositoryCredentials) Sets the value ofCfnDaemonTaskDefinition.DaemonContainerDefinitionProperty.getRepositoryCredentials()- Parameters:
repositoryCredentials- The repository credentials for private registry authentication.- Returns:
this
-
restartPolicy
@Stability(Stable) public CfnDaemonTaskDefinition.DaemonContainerDefinitionProperty.Builder restartPolicy(IResolvable restartPolicy) - Parameters:
restartPolicy- the value to be set.- Returns:
this
-
restartPolicy
@Stability(Stable) public CfnDaemonTaskDefinition.DaemonContainerDefinitionProperty.Builder restartPolicy(CfnDaemonTaskDefinition.RestartPolicyProperty restartPolicy) - Parameters:
restartPolicy- the value to be set.- Returns:
this
-
secrets
@Stability(Stable) public CfnDaemonTaskDefinition.DaemonContainerDefinitionProperty.Builder secrets(IResolvable secrets) Sets the value ofCfnDaemonTaskDefinition.DaemonContainerDefinitionProperty.getSecrets()- Parameters:
secrets- The secrets to pass to the container.- Returns:
this
-
secrets
@Stability(Stable) public CfnDaemonTaskDefinition.DaemonContainerDefinitionProperty.Builder secrets(List<? extends Object> secrets) Sets the value ofCfnDaemonTaskDefinition.DaemonContainerDefinitionProperty.getSecrets()- Parameters:
secrets- The secrets to pass to the container.- Returns:
this
-
startTimeout
@Stability(Stable) public CfnDaemonTaskDefinition.DaemonContainerDefinitionProperty.Builder startTimeout(Number startTimeout) - Parameters:
startTimeout- Time duration (in seconds) to wait before giving up on resolving dependencies for a container.- Returns:
this
-
stopTimeout
@Stability(Stable) public CfnDaemonTaskDefinition.DaemonContainerDefinitionProperty.Builder stopTimeout(Number stopTimeout) - Parameters:
stopTimeout- Time duration (in seconds) to wait before the container is forcefully killed if it doesn't exit normally on its own.- Returns:
this
-
systemControls
@Stability(Stable) public CfnDaemonTaskDefinition.DaemonContainerDefinitionProperty.Builder systemControls(IResolvable systemControls) - Parameters:
systemControls- A list of namespaced kernel parameters to set in the container.- Returns:
this
-
systemControls
@Stability(Stable) public CfnDaemonTaskDefinition.DaemonContainerDefinitionProperty.Builder systemControls(List<? extends Object> systemControls) - Parameters:
systemControls- A list of namespaced kernel parameters to set in the container.- Returns:
this
-
ulimits
@Stability(Stable) public CfnDaemonTaskDefinition.DaemonContainerDefinitionProperty.Builder ulimits(IResolvable ulimits) Sets the value ofCfnDaemonTaskDefinition.DaemonContainerDefinitionProperty.getUlimits()- Parameters:
ulimits- A list ofulimitsto set in the container.- Returns:
this
-
ulimits
@Stability(Stable) public CfnDaemonTaskDefinition.DaemonContainerDefinitionProperty.Builder ulimits(List<? extends Object> ulimits) Sets the value ofCfnDaemonTaskDefinition.DaemonContainerDefinitionProperty.getUlimits()- Parameters:
ulimits- A list ofulimitsto set in the container.- Returns:
this
-
user
@Stability(Stable) public CfnDaemonTaskDefinition.DaemonContainerDefinitionProperty.Builder user(String user) Sets the value ofCfnDaemonTaskDefinition.DaemonContainerDefinitionProperty.getUser()- Parameters:
user- The user to use inside the container.- Returns:
this
-
workingDirectory
@Stability(Stable) public CfnDaemonTaskDefinition.DaemonContainerDefinitionProperty.Builder workingDirectory(String workingDirectory) - Parameters:
workingDirectory- The working directory to run commands inside the container in.- Returns:
this
-
build
Builds the configured instance.- Specified by:
buildin interfacesoftware.amazon.jsii.Builder<CfnDaemonTaskDefinition.DaemonContainerDefinitionProperty>- Returns:
- a new instance of
CfnDaemonTaskDefinition.DaemonContainerDefinitionProperty - Throws:
NullPointerException- if any required attribute was not provided
-