@Generated(value="jsii-pacmak/1.58.0 (build f8ba112)",
date="2022-05-20T22:19:59.569Z")
public interface SecurityGroupProps
Vpc vpc; SecurityGroup securityGroup1 = SecurityGroup.Builder.create(this, "SecurityGroup1").vpc(vpc).build(); ApplicationLoadBalancer lb = ApplicationLoadBalancer.Builder.create(this, "LB") .vpc(vpc) .internetFacing(true) .securityGroup(securityGroup1) .build(); SecurityGroup securityGroup2 = SecurityGroup.Builder.create(this, "SecurityGroup2").vpc(vpc).build(); lb.addSecurityGroup(securityGroup2);
Modifier and Type | Interface and Description |
---|---|
static class |
SecurityGroupProps.Builder
A builder for
SecurityGroupProps |
static class |
SecurityGroupProps.Jsii$Proxy
An implementation for
SecurityGroupProps |
Modifier and Type | Method and Description |
---|---|
static SecurityGroupProps.Builder |
builder() |
default java.lang.Boolean |
getAllowAllOutbound()
Whether to allow all outbound traffic by default.
|
default java.lang.String |
getDescription()
A description of the security group.
|
default java.lang.Boolean |
getDisableInlineRules()
Whether to disable inline ingress and egress rule optimization.
|
default java.lang.String |
getSecurityGroupName()
The name of the security group.
|
IVpc |
getVpc()
The VPC in which to create the security group.
|
IVpc getVpc()
default java.lang.Boolean getAllowAllOutbound()
If this is set to true, there will only be a single egress rule which allows all outbound traffic. If this is set to false, no outbound traffic will be allowed by default and all egress traffic must be explicitly authorized.
Default: true
default java.lang.String getDescription()
Default: The default name will be the construct's CDK path.
default java.lang.Boolean getDisableInlineRules()
If this is set to true, ingress and egress rules will not be declared under the SecurityGroup in cloudformation, but will be separate elements.
Inlining rules is an optimization for producing smaller stack templates. Sometimes this is not desirable, for example when security group access is managed via tags.
The default value can be overriden globally by setting the context variable '@aws-cdk/aws-ec2.securityGroupDisableInlineRules'.
Default: false
default java.lang.String getSecurityGroupName()
For valid values, see the GroupName parameter of the CreateSecurityGroup action in the Amazon EC2 API Reference.
It is not recommended to use an explicit group name.
Default: If you don't specify a GroupName, AWS CloudFormation generates a unique physical ID and uses that ID for the group name.
static SecurityGroupProps.Builder builder()
SecurityGroupProps.Builder
of SecurityGroupProps