@cdktf/provider-aws
Version:
Prebuilt aws Provider for Terraform CDK (cdktf)
420 lines (419 loc) • 19.6 kB
TypeScript
/**
* Copyright (c) HashiCorp, Inc.
* SPDX-License-Identifier: MPL-2.0
*/
import { Construct } from 'constructs';
import * as cdktf from 'cdktf';
export interface SecurityGroupConfig extends cdktf.TerraformMetaArguments {
/**
* Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/aws/5.84.0/docs/resources/security_group#description SecurityGroup#description}
*/
readonly description?: string;
/**
* Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/aws/5.84.0/docs/resources/security_group#egress SecurityGroup#egress}
*/
readonly egress?: SecurityGroupEgress[] | cdktf.IResolvable;
/**
* Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/aws/5.84.0/docs/resources/security_group#id SecurityGroup#id}
*
* Please be aware that the id field is automatically added to all resources in Terraform providers using a Terraform provider SDK version below 2.
* If you experience problems setting this value it might not be settable. Please take a look at the provider documentation to ensure it should be settable.
*/
readonly id?: string;
/**
* Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/aws/5.84.0/docs/resources/security_group#ingress SecurityGroup#ingress}
*/
readonly ingress?: SecurityGroupIngress[] | cdktf.IResolvable;
/**
* Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/aws/5.84.0/docs/resources/security_group#name SecurityGroup#name}
*/
readonly name?: string;
/**
* Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/aws/5.84.0/docs/resources/security_group#name_prefix SecurityGroup#name_prefix}
*/
readonly namePrefix?: string;
/**
* Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/aws/5.84.0/docs/resources/security_group#revoke_rules_on_delete SecurityGroup#revoke_rules_on_delete}
*/
readonly revokeRulesOnDelete?: boolean | cdktf.IResolvable;
/**
* Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/aws/5.84.0/docs/resources/security_group#tags SecurityGroup#tags}
*/
readonly tags?: {
[key: string]: string;
};
/**
* Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/aws/5.84.0/docs/resources/security_group#tags_all SecurityGroup#tags_all}
*/
readonly tagsAll?: {
[key: string]: string;
};
/**
* Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/aws/5.84.0/docs/resources/security_group#vpc_id SecurityGroup#vpc_id}
*/
readonly vpcId?: string;
/**
* timeouts block
*
* Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/aws/5.84.0/docs/resources/security_group#timeouts SecurityGroup#timeouts}
*/
readonly timeouts?: SecurityGroupTimeouts;
}
export interface SecurityGroupEgress {
/**
* Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/aws/5.84.0/docs/resources/security_group#cidr_blocks SecurityGroup#cidr_blocks}
*/
readonly cidrBlocks?: string[];
/**
* Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/aws/5.84.0/docs/resources/security_group#description SecurityGroup#description}
*/
readonly description?: string;
/**
* Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/aws/5.84.0/docs/resources/security_group#from_port SecurityGroup#from_port}
*/
readonly fromPort?: number;
/**
* Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/aws/5.84.0/docs/resources/security_group#ipv6_cidr_blocks SecurityGroup#ipv6_cidr_blocks}
*/
readonly ipv6CidrBlocks?: string[];
/**
* Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/aws/5.84.0/docs/resources/security_group#prefix_list_ids SecurityGroup#prefix_list_ids}
*/
readonly prefixListIds?: string[];
/**
* Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/aws/5.84.0/docs/resources/security_group#protocol SecurityGroup#protocol}
*/
readonly protocol?: string;
/**
* Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/aws/5.84.0/docs/resources/security_group#security_groups SecurityGroup#security_groups}
*/
readonly securityGroups?: string[];
/**
* Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/aws/5.84.0/docs/resources/security_group#self SecurityGroup#self}
*/
readonly selfAttribute?: boolean | cdktf.IResolvable;
/**
* Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/aws/5.84.0/docs/resources/security_group#to_port SecurityGroup#to_port}
*/
readonly toPort?: number;
}
export declare function securityGroupEgressToTerraform(struct?: SecurityGroupEgress | cdktf.IResolvable): any;
export declare function securityGroupEgressToHclTerraform(struct?: SecurityGroupEgress | cdktf.IResolvable): any;
export declare class SecurityGroupEgressOutputReference extends cdktf.ComplexObject {
private isEmptyObject;
private resolvableValue?;
/**
* @param terraformResource The parent resource
* @param terraformAttribute The attribute on the parent resource this class is referencing
* @param complexObjectIndex the index of this item in the list
* @param complexObjectIsFromSet whether the list is wrapping a set (will add tolist() to be able to access an item via an index)
*/
constructor(terraformResource: cdktf.IInterpolatingParent, terraformAttribute: string, complexObjectIndex: number, complexObjectIsFromSet: boolean);
get internalValue(): SecurityGroupEgress | cdktf.IResolvable | undefined;
set internalValue(value: SecurityGroupEgress | cdktf.IResolvable | undefined);
private _cidrBlocks?;
get cidrBlocks(): string[];
set cidrBlocks(value: string[]);
resetCidrBlocks(): void;
get cidrBlocksInput(): string[] | undefined;
private _description?;
get description(): string;
set description(value: string);
resetDescription(): void;
get descriptionInput(): string | undefined;
private _fromPort?;
get fromPort(): number;
set fromPort(value: number);
resetFromPort(): void;
get fromPortInput(): number | undefined;
private _ipv6CidrBlocks?;
get ipv6CidrBlocks(): string[];
set ipv6CidrBlocks(value: string[]);
resetIpv6CidrBlocks(): void;
get ipv6CidrBlocksInput(): string[] | undefined;
private _prefixListIds?;
get prefixListIds(): string[];
set prefixListIds(value: string[]);
resetPrefixListIds(): void;
get prefixListIdsInput(): string[] | undefined;
private _protocol?;
get protocol(): string;
set protocol(value: string);
resetProtocol(): void;
get protocolInput(): string | undefined;
private _securityGroups?;
get securityGroups(): string[];
set securityGroups(value: string[]);
resetSecurityGroups(): void;
get securityGroupsInput(): string[] | undefined;
private _self?;
get selfAttribute(): boolean | cdktf.IResolvable;
set selfAttribute(value: boolean | cdktf.IResolvable);
resetSelfAttribute(): void;
get selfAttributeInput(): boolean | cdktf.IResolvable | undefined;
private _toPort?;
get toPort(): number;
set toPort(value: number);
resetToPort(): void;
get toPortInput(): number | undefined;
}
export declare class SecurityGroupEgressList extends cdktf.ComplexList {
protected terraformResource: cdktf.IInterpolatingParent;
protected terraformAttribute: string;
protected wrapsSet: boolean;
internalValue?: SecurityGroupEgress[] | cdktf.IResolvable;
/**
* @param terraformResource The parent resource
* @param terraformAttribute The attribute on the parent resource this class is referencing
* @param wrapsSet whether the list is wrapping a set (will add tolist() to be able to access an item via an index)
*/
constructor(terraformResource: cdktf.IInterpolatingParent, terraformAttribute: string, wrapsSet: boolean);
/**
* @param index the index of the item to return
*/
get(index: number): SecurityGroupEgressOutputReference;
}
export interface SecurityGroupIngress {
/**
* Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/aws/5.84.0/docs/resources/security_group#cidr_blocks SecurityGroup#cidr_blocks}
*/
readonly cidrBlocks?: string[];
/**
* Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/aws/5.84.0/docs/resources/security_group#description SecurityGroup#description}
*/
readonly description?: string;
/**
* Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/aws/5.84.0/docs/resources/security_group#from_port SecurityGroup#from_port}
*/
readonly fromPort?: number;
/**
* Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/aws/5.84.0/docs/resources/security_group#ipv6_cidr_blocks SecurityGroup#ipv6_cidr_blocks}
*/
readonly ipv6CidrBlocks?: string[];
/**
* Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/aws/5.84.0/docs/resources/security_group#prefix_list_ids SecurityGroup#prefix_list_ids}
*/
readonly prefixListIds?: string[];
/**
* Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/aws/5.84.0/docs/resources/security_group#protocol SecurityGroup#protocol}
*/
readonly protocol?: string;
/**
* Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/aws/5.84.0/docs/resources/security_group#security_groups SecurityGroup#security_groups}
*/
readonly securityGroups?: string[];
/**
* Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/aws/5.84.0/docs/resources/security_group#self SecurityGroup#self}
*/
readonly selfAttribute?: boolean | cdktf.IResolvable;
/**
* Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/aws/5.84.0/docs/resources/security_group#to_port SecurityGroup#to_port}
*/
readonly toPort?: number;
}
export declare function securityGroupIngressToTerraform(struct?: SecurityGroupIngress | cdktf.IResolvable): any;
export declare function securityGroupIngressToHclTerraform(struct?: SecurityGroupIngress | cdktf.IResolvable): any;
export declare class SecurityGroupIngressOutputReference extends cdktf.ComplexObject {
private isEmptyObject;
private resolvableValue?;
/**
* @param terraformResource The parent resource
* @param terraformAttribute The attribute on the parent resource this class is referencing
* @param complexObjectIndex the index of this item in the list
* @param complexObjectIsFromSet whether the list is wrapping a set (will add tolist() to be able to access an item via an index)
*/
constructor(terraformResource: cdktf.IInterpolatingParent, terraformAttribute: string, complexObjectIndex: number, complexObjectIsFromSet: boolean);
get internalValue(): SecurityGroupIngress | cdktf.IResolvable | undefined;
set internalValue(value: SecurityGroupIngress | cdktf.IResolvable | undefined);
private _cidrBlocks?;
get cidrBlocks(): string[];
set cidrBlocks(value: string[]);
resetCidrBlocks(): void;
get cidrBlocksInput(): string[] | undefined;
private _description?;
get description(): string;
set description(value: string);
resetDescription(): void;
get descriptionInput(): string | undefined;
private _fromPort?;
get fromPort(): number;
set fromPort(value: number);
resetFromPort(): void;
get fromPortInput(): number | undefined;
private _ipv6CidrBlocks?;
get ipv6CidrBlocks(): string[];
set ipv6CidrBlocks(value: string[]);
resetIpv6CidrBlocks(): void;
get ipv6CidrBlocksInput(): string[] | undefined;
private _prefixListIds?;
get prefixListIds(): string[];
set prefixListIds(value: string[]);
resetPrefixListIds(): void;
get prefixListIdsInput(): string[] | undefined;
private _protocol?;
get protocol(): string;
set protocol(value: string);
resetProtocol(): void;
get protocolInput(): string | undefined;
private _securityGroups?;
get securityGroups(): string[];
set securityGroups(value: string[]);
resetSecurityGroups(): void;
get securityGroupsInput(): string[] | undefined;
private _self?;
get selfAttribute(): boolean | cdktf.IResolvable;
set selfAttribute(value: boolean | cdktf.IResolvable);
resetSelfAttribute(): void;
get selfAttributeInput(): boolean | cdktf.IResolvable | undefined;
private _toPort?;
get toPort(): number;
set toPort(value: number);
resetToPort(): void;
get toPortInput(): number | undefined;
}
export declare class SecurityGroupIngressList extends cdktf.ComplexList {
protected terraformResource: cdktf.IInterpolatingParent;
protected terraformAttribute: string;
protected wrapsSet: boolean;
internalValue?: SecurityGroupIngress[] | cdktf.IResolvable;
/**
* @param terraformResource The parent resource
* @param terraformAttribute The attribute on the parent resource this class is referencing
* @param wrapsSet whether the list is wrapping a set (will add tolist() to be able to access an item via an index)
*/
constructor(terraformResource: cdktf.IInterpolatingParent, terraformAttribute: string, wrapsSet: boolean);
/**
* @param index the index of the item to return
*/
get(index: number): SecurityGroupIngressOutputReference;
}
export interface SecurityGroupTimeouts {
/**
* Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/aws/5.84.0/docs/resources/security_group#create SecurityGroup#create}
*/
readonly create?: string;
/**
* Docs at Terraform Registry: {@link https://registry.terraform.io/providers/hashicorp/aws/5.84.0/docs/resources/security_group#delete SecurityGroup#delete}
*/
readonly delete?: string;
}
export declare function securityGroupTimeoutsToTerraform(struct?: SecurityGroupTimeouts | cdktf.IResolvable): any;
export declare function securityGroupTimeoutsToHclTerraform(struct?: SecurityGroupTimeouts | cdktf.IResolvable): any;
export declare class SecurityGroupTimeoutsOutputReference extends cdktf.ComplexObject {
private isEmptyObject;
private resolvableValue?;
/**
* @param terraformResource The parent resource
* @param terraformAttribute The attribute on the parent resource this class is referencing
*/
constructor(terraformResource: cdktf.IInterpolatingParent, terraformAttribute: string);
get internalValue(): SecurityGroupTimeouts | cdktf.IResolvable | undefined;
set internalValue(value: SecurityGroupTimeouts | cdktf.IResolvable | undefined);
private _create?;
get create(): string;
set create(value: string);
resetCreate(): void;
get createInput(): string | undefined;
private _delete?;
get delete(): string;
set delete(value: string);
resetDelete(): void;
get deleteInput(): string | undefined;
}
/**
* Represents a {@link https://registry.terraform.io/providers/hashicorp/aws/5.84.0/docs/resources/security_group aws_security_group}
*/
export declare class SecurityGroup extends cdktf.TerraformResource {
static readonly tfResourceType = "aws_security_group";
/**
* Generates CDKTF code for importing a SecurityGroup resource upon running "cdktf plan <stack-name>"
* @param scope The scope in which to define this construct
* @param importToId The construct id used in the generated config for the SecurityGroup to import
* @param importFromId The id of the existing SecurityGroup that should be imported. Refer to the {@link https://registry.terraform.io/providers/hashicorp/aws/5.84.0/docs/resources/security_group#import import section} in the documentation of this resource for the id to use
* @param provider? Optional instance of the provider where the SecurityGroup to import is found
*/
static generateConfigForImport(scope: Construct, importToId: string, importFromId: string, provider?: cdktf.TerraformProvider): cdktf.ImportableResource;
/**
* Create a new {@link https://registry.terraform.io/providers/hashicorp/aws/5.84.0/docs/resources/security_group aws_security_group} Resource
*
* @param scope The scope in which to define this construct
* @param id The scoped construct ID. Must be unique amongst siblings in the same scope
* @param options SecurityGroupConfig = {}
*/
constructor(scope: Construct, id: string, config?: SecurityGroupConfig);
get arn(): string;
private _description?;
get description(): string;
set description(value: string);
resetDescription(): void;
get descriptionInput(): string | undefined;
private _egress;
get egress(): SecurityGroupEgressList;
putEgress(value: SecurityGroupEgress[] | cdktf.IResolvable): void;
resetEgress(): void;
get egressInput(): cdktf.IResolvable | SecurityGroupEgress[] | undefined;
private _id?;
get id(): string;
set id(value: string);
resetId(): void;
get idInput(): string | undefined;
private _ingress;
get ingress(): SecurityGroupIngressList;
putIngress(value: SecurityGroupIngress[] | cdktf.IResolvable): void;
resetIngress(): void;
get ingressInput(): cdktf.IResolvable | SecurityGroupIngress[] | undefined;
private _name?;
get name(): string;
set name(value: string);
resetName(): void;
get nameInput(): string | undefined;
private _namePrefix?;
get namePrefix(): string;
set namePrefix(value: string);
resetNamePrefix(): void;
get namePrefixInput(): string | undefined;
get ownerId(): string;
private _revokeRulesOnDelete?;
get revokeRulesOnDelete(): boolean | cdktf.IResolvable;
set revokeRulesOnDelete(value: boolean | cdktf.IResolvable);
resetRevokeRulesOnDelete(): void;
get revokeRulesOnDeleteInput(): boolean | cdktf.IResolvable | undefined;
private _tags?;
get tags(): {
[key: string]: string;
};
set tags(value: {
[key: string]: string;
});
resetTags(): void;
get tagsInput(): {
[key: string]: string;
} | undefined;
private _tagsAll?;
get tagsAll(): {
[key: string]: string;
};
set tagsAll(value: {
[key: string]: string;
});
resetTagsAll(): void;
get tagsAllInput(): {
[key: string]: string;
} | undefined;
private _vpcId?;
get vpcId(): string;
set vpcId(value: string);
resetVpcId(): void;
get vpcIdInput(): string | undefined;
private _timeouts;
get timeouts(): SecurityGroupTimeoutsOutputReference;
putTimeouts(value: SecurityGroupTimeouts): void;
resetTimeouts(): void;
get timeoutsInput(): cdktf.IResolvable | SecurityGroupTimeouts | undefined;
protected synthesizeAttributes(): {
[name: string]: any;
};
protected synthesizeHclAttributes(): {
[name: string]: any;
};
}