import * as core from "@terrascript/core"; export interface AccessLogsArgs extends core.SchemaArgs { bucket: string | core.StringOut; bucketPrefix?: string | core.StringOut; enabled?: boolean | core.BooleanOut; interval?: number | core.NumberOut; } export class AccessLogs extends core.Schema { @core.attr(String) public bucket!: string | core.StringOut; @core.attr(String) public bucketPrefix?: string | core.StringOut; @core.attr(Boolean) public enabled?: boolean | core.BooleanOut; @core.attr(Number) public interval?: number | core.NumberOut; } export interface HealthCheckArgs extends core.SchemaArgs { healthyThreshold: number | core.NumberOut; interval: number | core.NumberOut; target: string | core.StringOut; timeout: number | core.NumberOut; unhealthyThreshold: number | core.NumberOut; } export class HealthCheck extends core.Schema { @core.attr(Number) public healthyThreshold!: number | core.NumberOut; @core.attr(Number) public interval!: number | core.NumberOut; @core.attr(String) public target!: string | core.StringOut; @core.attr(Number) public timeout!: number | core.NumberOut; @core.attr(Number) public unhealthyThreshold!: number | core.NumberOut; } export interface ListenerArgs extends core.SchemaArgs { instancePort: number | core.NumberOut; instanceProtocol: string | core.StringOut; lbPort: number | core.NumberOut; lbProtocol: string | core.StringOut; sslCertificateId?: string | core.StringOut; } export class Listener extends core.Schema { @core.attr(Number) public instancePort!: number | core.NumberOut; @core.attr(String) public instanceProtocol!: string | core.StringOut; @core.attr(Number) public lbPort!: number | core.NumberOut; @core.attr(String) public lbProtocol!: string | core.StringOut; @core.attr(String) public sslCertificateId?: string | core.StringOut; } export interface MainArgs extends core.ResourceArgs { /** * (Optional) An Access Logs block. Access Logs documented below. */ accessLogs?: AccessLogs; /** * (Required for an EC2-classic ELB) The AZ's to serve traffic in. */ availabilityZones?: core.Array | core.ArrayOut; /** * (Optional) Boolean to enable connection draining. Default: `false` */ connectionDraining?: boolean | core.BooleanOut; /** * (Optional) The time in seconds to allow for connections to drain. Default: `300` */ connectionDrainingTimeout?: number | core.NumberOut; /** * (Optional) Enable cross-zone load balancing. Default: `true` */ crossZoneLoadBalancing?: boolean | core.BooleanOut; /** * (Optional) Determines how the load balancer handles requests that might pose a security risk to an a * pplication due to HTTP desync. Valid values are `monitor`, `defensive` (default), `strictest`. */ desyncMitigationMode?: string | core.StringOut; /** * (Optional) A health_check block. Health Check documented below. */ healthCheck?: HealthCheck; /** * (Optional) The time in seconds that the connection is allowed to be idle. Default: `60` */ idleTimeout?: number | core.NumberOut; /** * (Optional) A list of instance ids to place in the ELB pool. */ instances?: core.Array | core.ArrayOut; /** * (Optional) If true, ELB will be an internal ELB. */ internal?: boolean | core.BooleanOut; /** * (Required) A list of listener blocks. Listeners documented below. */ listener: core.Array | core.ArrayOut; /** * (Optional) The name of the ELB. By default generated by Terraform. */ name?: string | core.StringOut; /** * (Optional, Forces new resource) Creates a unique name beginning with the specified */ namePrefix?: string | core.StringOut; /** * (Optional) A list of security group IDs to assign to the ELB. */ securityGroups?: core.Array | core.ArrayOut; /** * The name of the security group that you can use as */ sourceSecurityGroup?: string | core.StringOut; /** * (Required for a VPC ELB) A list of subnet IDs to attach to the ELB. */ subnets?: core.Array | core.ArrayOut; /** * (Optional) A map of tags to assign to the resource. If configured with a provider [`default_tags` co * nfiguration block](https://registry.terraform.io/providers/hashicorp/aws/latest/docs#default_tags-co * nfiguration-block) present, tags with matching keys will overwrite those defined at the provider-lev * el. */ tags?: core.Map | core.MapOut; /** * A map of tags assigned to the resource, including those inherited from the provider [`default_tags` * configuration block](https://registry.terraform.io/providers/hashicorp/aws/latest/docs#default_tags- * configuration-block). */ tagsAll?: core.Map | core.MapOut; } export class Main extends core.Resource { /** * (Optional) An Access Logs block. Access Logs documented below. */ @core.attr(AccessLogs) public accessLogs?: AccessLogs; /** * The ARN of the ELB */ @core.attr(String, { computed: true }) public arn!: string | core.StringOut; /** * (Required for an EC2-classic ELB) The AZ's to serve traffic in. */ @core.attr(String, { computed: true, kind: "array" }) public availabilityZones?: core.Array | core.ArrayOut; /** * (Optional) Boolean to enable connection draining. Default: `false` */ @core.attr(Boolean) public connectionDraining?: boolean | core.BooleanOut; /** * (Optional) The time in seconds to allow for connections to drain. Default: `300` */ @core.attr(Number) public connectionDrainingTimeout?: number | core.NumberOut; /** * (Optional) Enable cross-zone load balancing. Default: `true` */ @core.attr(Boolean) public crossZoneLoadBalancing?: boolean | core.BooleanOut; /** * (Optional) Determines how the load balancer handles requests that might pose a security risk to an a * pplication due to HTTP desync. Valid values are `monitor`, `defensive` (default), `strictest`. */ @core.attr(String) public desyncMitigationMode?: string | core.StringOut; /** * The DNS name of the ELB */ @core.attr(String, { computed: true }) public dnsName!: string | core.StringOut; /** * (Optional) A health_check block. Health Check documented below. */ @core.attr(HealthCheck, { computed: true }) public healthCheck?: HealthCheck; /** * The name of the ELB */ @core.attr(String, { computed: true }) public id!: string | core.StringOut; /** * (Optional) The time in seconds that the connection is allowed to be idle. Default: `60` */ @core.attr(Number) public idleTimeout?: number | core.NumberOut; /** * (Optional) A list of instance ids to place in the ELB pool. */ @core.attr(String, { computed: true, kind: "array" }) public instances?: core.Array | core.ArrayOut; /** * (Optional) If true, ELB will be an internal ELB. */ @core.attr(Boolean, { computed: true }) public internal?: boolean | core.BooleanOut; /** * (Required) A list of listener blocks. Listeners documented below. */ @core.attr(Listener, { kind: "array" }) public listener!: core.Array | core.ArrayOut; /** * (Optional) The name of the ELB. By default generated by Terraform. */ @core.attr(String, { computed: true }) public name?: string | core.StringOut; /** * (Optional, Forces new resource) Creates a unique name beginning with the specified */ @core.attr(String) public namePrefix?: string | core.StringOut; /** * (Optional) A list of security group IDs to assign to the ELB. */ @core.attr(String, { computed: true, kind: "array" }) public securityGroups?: core.Array | core.ArrayOut; /** * The name of the security group that you can use as */ @core.attr(String, { computed: true }) public sourceSecurityGroup?: string | core.StringOut; /** * The ID of the security group that you can use as */ @core.attr(String, { computed: true }) public sourceSecurityGroupId!: string | core.StringOut; /** * (Required for a VPC ELB) A list of subnet IDs to attach to the ELB. */ @core.attr(String, { computed: true, kind: "array" }) public subnets?: core.Array | core.ArrayOut; /** * (Optional) A map of tags to assign to the resource. If configured with a provider [`default_tags` co * nfiguration block](https://registry.terraform.io/providers/hashicorp/aws/latest/docs#default_tags-co * nfiguration-block) present, tags with matching keys will overwrite those defined at the provider-lev * el. */ @core.attr(String, { kind: "map" }) public tags?: core.Map | core.MapOut; /** * A map of tags assigned to the resource, including those inherited from the provider [`default_tags` * configuration block](https://registry.terraform.io/providers/hashicorp/aws/latest/docs#default_tags- * configuration-block). */ @core.attr(String, { computed: true, kind: "map" }) public tagsAll?: core.Map | core.MapOut; /** * The canonical hosted zone ID of the ELB (to be used in a Route 53 Alias record) */ @core.attr(String, { computed: true }) public zoneId!: string | core.StringOut; constructor(name: string, args?: MainArgs) { super(name, "aws_elb", args); } public override getNamespace(): string { return "aws_elb"; } }