SecurityGroupEgress
This class encapsulates and extends the ROS resource type ALIYUN::ECS::SecurityGroupEgress, which is used to create an outbound access rule for a security group.
Initializers
import ros_cdk_ecs
ros_cdk_ecs.SecurityGroupEgress(
scope: Construct,
id: str,
ip_protocol: typing.Union[str, IResolvable],
port_range: typing.Union[str, IResolvable],
description: typing.Union[str, IResolvable] = None,
dest_cidr_ip: typing.Union[str, IResolvable] = None,
dest_group_id: typing.Union[str, IResolvable] = None,
dest_group_owner_id: typing.Union[str, IResolvable] = None,
dest_prefix_list_id: typing.Union[str, IResolvable] = None,
ipv6_dest_cidr_ip: typing.Union[str, IResolvable] = None,
nic_type: typing.Union[str, IResolvable] = None,
policy: typing.Union[str, IResolvable] = None,
priority: typing.Union[typing.Union[int, float], IResolvable] = None,
security_group_id: typing.Union[str, IResolvable] = None,
enable_resource_property_constraint: bool = None
)
| Name | Type | Description |
|---|---|---|
scope |
ros_cdk_core.Construct |
No description. |
id |
str |
No description. |
ip_protocol |
typing.Union[str, ros_cdk_core.IResolvable] |
Property ipProtocol: Ip protocol for in rule. |
port_range |
typing.Union[str, ros_cdk_core.IResolvable] |
Property portRange: Ip protocol relative port range. |
description |
typing.Union[str, ros_cdk_core.IResolvable] |
Property description: Description of the security group rule, [1, 512] characters. |
dest_cidr_ip |
typing.Union[str, ros_cdk_core.IResolvable] |
Property destCidrIp: The destination IPv4 CIDR block to which you want to control access. |
dest_group_id |
typing.Union[str, ros_cdk_core.IResolvable] |
Property destGroupId: The destination security group ID to which access permissions need to be set. |
dest_group_owner_id |
typing.Union[str, ros_cdk_core.IResolvable] |
Property destGroupOwnerId: When setting security group rules across accounts, the Ali Cloud account ID of the destination security group. |
dest_prefix_list_id |
typing.Union[str, ros_cdk_core.IResolvable] |
Property destPrefixListId: The ID of the destination prefix list to which you want to control access. |
ipv6_dest_cidr_ip |
typing.Union[str, ros_cdk_core.IResolvable] |
Property ipv6DestCidrIp: Destination IPv6 CIDR address block for which access rights need to be set. |
nic_type |
typing.Union[str, ros_cdk_core.IResolvable] |
Property nicType: Network type, could be 'internet' or 'intranet'. |
policy |
typing.Union[str, ros_cdk_core.IResolvable] |
Property policy: Authorization policies, parameter values can be: accept (accepted access), drop (denied access). |
priority |
typing.Union[typing.Union[int, float], ros_cdk_core.IResolvable] |
Property priority: Authorization policies priority range[1, 100]. |
security_group_id |
typing.Union[str, ros_cdk_core.IResolvable] |
Property securityGroupId: Id of the security group. |
enable_resource_property_constraint |
bool |
No description. |
scopeRequired
- Type: ros_cdk_core.Construct
idRequired
- Type: str
ip_protocolRequired
- Type: typing.Union[str, ros_cdk_core.IResolvable]
Property ipProtocol: Ip protocol for in rule.
port_rangeRequired
- Type: typing.Union[str, ros_cdk_core.IResolvable]
Property portRange: Ip protocol relative port range.
For tcp and udp, the port rang is [1,65535], using format '1/200'For icmp|gre|all protocel, the port range should be '-1/-1'
descriptionOptional
- Type: typing.Union[str, ros_cdk_core.IResolvable]
Property description: Description of the security group rule, [1, 512] characters.
The default is empty.
dest_cidr_ipOptional
- Type: typing.Union[str, ros_cdk_core.IResolvable]
Property destCidrIp: The destination IPv4 CIDR block to which you want to control access.
CIDR blocks and IPv4 addresses are supported.
dest_group_idOptional
- Type: typing.Union[str, ros_cdk_core.IResolvable]
Property destGroupId: The destination security group ID to which access permissions need to be set.
Set at least one of the DestGroupId, DestCidrIp, Ipv6DestCidrIp, or DestPrefixListId parameters.
- If DestGroupId is specified without the DestCidrIp parameter, the NicType parameter can only take the value intranet.
- If both DestGroupId and DestCidrIp are specified, DestCidrIp is assumed to prevail. You should pay attention to:
- Enterprise Security groups do not support authorized security group access.
- The maximum number of authorized security groups supported by ordinary security groups is 20.
dest_group_owner_idOptional
- Type: typing.Union[str, ros_cdk_core.IResolvable]
Property destGroupOwnerId: When setting security group rules across accounts, the Ali Cloud account ID of the destination security group.
- If neither DestGroupOwnerId nor DestGroupOwnerAccount is set, it is considered to set the access rights of your other security group.
- If you have set the parameter DestCidrIp, the parameter DestGroupOwnerId is invalid.
dest_prefix_list_idOptional
- Type: typing.Union[str, ros_cdk_core.IResolvable]
Property destPrefixListId: The ID of the destination prefix list to which you want to control access.
You can call the DescribePrefixLists operation to query the IDs of available prefix lists.Take note of the following items: If a security group is in the classic network, you cannot configure prefix lists in the security group rules. For information about the limits on security groups and prefix lists, see the "Security group limits" in Limits. If you specify DestCidrIp, Ipv6DestCidrIp, or DestGroupId, DestPrefixListId is ignored.
ipv6_dest_cidr_ipOptional
- Type: typing.Union[str, ros_cdk_core.IResolvable]
Property ipv6DestCidrIp: Destination IPv6 CIDR address block for which access rights need to be set.
CIDR format and IPv6 format IP address range are supported.
nic_typeOptional
- Type: typing.Union[str, ros_cdk_core.IResolvable]
Property nicType: Network type, could be 'internet' or 'intranet'.
Default value is internet.
policyOptional
- Type: typing.Union[str, ros_cdk_core.IResolvable]
Property policy: Authorization policies, parameter values can be: accept (accepted access), drop (denied access).
Default value is accept.
priorityOptional
- Type: typing.Union[typing.Union[int, float], ros_cdk_core.IResolvable]
Property priority: Authorization policies priority range[1, 100].
security_group_idOptional
- Type: typing.Union[str, ros_cdk_core.IResolvable]
Property securityGroupId: Id of the security group.
enable_resource_property_constraintOptional
- Type: bool
Methods
| Name | Description |
|---|---|
to_string |
Returns a string representation of this construct. |
synthesize |
Allows this construct to emit artifacts into the cloud assembly during synthesis. |
add_condition |
No description. |
add_count |
No description. |
add_dependency |
No description. |
add_resource_desc |
No description. |
apply_removal_policy |
No description. |
get_att |
No description. |
set_metadata |
No description. |
to_string
def to_string() -> str
Returns a string representation of this construct.
synthesize
def synthesize(
session: ISynthesisSession
) -> None
Allows this construct to emit artifacts into the cloud assembly during synthesis.
This method is usually implemented by framework-level constructs such as Stack and Asset
as they participate in synthesizing the cloud assembly.
- Type: ros_cdk_core.ISynthesisSession
The synthesis session.
add_condition
def add_condition(
condition: RosCondition
) -> None
- Type: ros_cdk_core.RosCondition
add_count
def add_count(
count: typing.Union[typing.Union[int, float], IResolvable]
) -> None
- Type: typing.Union[typing.Union[int, float], ros_cdk_core.IResolvable]
add_dependency
def add_dependency(
resource: Resource
) -> None
- Type: ros_cdk_core.Resource
add_resource_desc
def add_resource_desc(
desc: str
) -> None
- Type: str
apply_removal_policy
def apply_removal_policy(
policy: RemovalPolicy
) -> None
- Type: ros_cdk_core.RemovalPolicy
get_att
def get_att(
name: str
) -> IResolvable
- Type: str
set_metadata
def set_metadata(
key: str,
value: typing.Any
) -> None
- Type: str
- Type: typing.Any
Static Functions
| Name | Description |
|---|---|
is_construct |
Return whether the given object is a Construct. |
is_construct
import ros_cdk_ecs
ros_cdk_ecs.SecurityGroupEgress.is_construct(
x: typing.Any
)
Return whether the given object is a Construct.
- Type: typing.Any
Properties
| Name | Type | Description |
|---|---|---|
node |
ros_cdk_core.ConstructNode |
The construct tree node associated with this construct. |
ref |
str |
No description. |
stack |
ros_cdk_core.Stack |
The stack in which this resource is defined. |
resource |
ros_cdk_core.RosResource |
No description. |
nodeRequired
node: ConstructNode
- Type: ros_cdk_core.ConstructNode
The construct tree node associated with this construct.
refRequired
ref: str
- Type: str
stackRequired
stack: Stack
- Type: ros_cdk_core.Stack
The stack in which this resource is defined.
resourceOptional
resource: RosResource
- Type: ros_cdk_core.RosResource