LinuxParameters
- class aws_cdk.aws_ecs.LinuxParameters(scope, id, *, init_process_enabled=None, shared_memory_size=None)
Bases:
Construct
Linux-specific options that are applied to the container.
- ExampleMetadata:
fixture=_generated
Example:
# The code below shows an example of how to instantiate this type. # The values are placeholders you should change. import aws_cdk.aws_ecs as ecs linux_parameters = ecs.LinuxParameters(self, "MyLinuxParameters", init_process_enabled=False, shared_memory_size=123 )
Constructs a new instance of the LinuxParameters class.
- Parameters:
scope (
Construct
)id (
str
)init_process_enabled (
Optional
[bool
]) – Specifies whether to run an init process inside the container that forwards signals and reaps processes. Default: falseshared_memory_size (
Union
[int
,float
,None
]) – The value for the size (in MiB) of the /dev/shm volume. Default: No shared memory.
Methods
- add_capabilities(*cap)
Adds one or more Linux capabilities to the Docker configuration of a container.
Only works with EC2 launch type.
- Parameters:
cap (
Capability
)- Return type:
None
- add_devices(*device)
Adds one or more host devices to a container.
- Parameters:
device (
Device
)- Return type:
None
- add_tmpfs(*tmpfs)
Specifies the container path, mount options, and size (in MiB) of the tmpfs mount for a container.
Only works with EC2 launch type.
- Parameters:
tmpfs (
Tmpfs
)- Return type:
None
- drop_capabilities(*cap)
Removes one or more Linux capabilities to the Docker configuration of a container.
Only works with EC2 launch type.
- Parameters:
cap (
Capability
)- Return type:
None
- render_linux_parameters()
Renders the Linux parameters to a CloudFormation object.
- Return type:
- to_string()
Returns a string representation of this construct.
- Return type:
str
Attributes
- node
The construct tree node associated with this construct.
Static Methods
- classmethod is_construct(x)
Return whether the given object is a Construct.
- Parameters:
x (
Any
)- Return type:
bool