Class ApplicationLoadBalancedFargateService
A Fargate service running on an ECS cluster fronted by an application load balancer.
Inherited Members
Namespace: Amazon.CDK.AWS.ECS.Patterns
Assembly: Amazon.CDK.Lib.dll
Syntax (csharp)
public class ApplicationLoadBalancedFargateService : ApplicationLoadBalancedServiceBase
Syntax (vb)
Public Class ApplicationLoadBalancedFargateService
Inherits ApplicationLoadBalancedServiceBase
Remarks
ExampleMetadata: infused
Examples
Cluster cluster;
var loadBalancedFargateService = new ApplicationLoadBalancedFargateService(this, "Service", new ApplicationLoadBalancedFargateServiceProps {
Cluster = cluster,
MemoryLimitMiB = 1024,
DesiredCount = 1,
Cpu = 512,
TaskImageOptions = new ApplicationLoadBalancedTaskImageOptions {
Image = ContainerImage.FromRegistry("amazon/amazon-ecs-sample")
},
TaskSubnets = new SubnetSelection {
Subnets = new [] { Subnet.FromSubnetId(this, "subnet", "VpcISOLATEDSubnet1Subnet80F07FA0") }
},
LoadBalancerName = "application-lb-name"
});
Synopsis
Constructors
ApplicationLoadBalancedFargateService(ByRefValue) | Used by jsii to construct an instance of this class from a Javascript-owned object reference |
ApplicationLoadBalancedFargateService(DeputyBase.DeputyProps) | Used by jsii to construct an instance of this class from DeputyProps |
ApplicationLoadBalancedFargateService(Construct, String, IApplicationLoadBalancedFargateServiceProps) | Constructs a new instance of the ApplicationLoadBalancedFargateService class. |
Properties
AssignPublicIp | Determines whether the service will be assigned a public IP address. |
Service | The Fargate service in this construct. |
TaskDefinition | The Fargate task definition in this construct. |
Constructors
ApplicationLoadBalancedFargateService(ByRefValue)
Used by jsii to construct an instance of this class from a Javascript-owned object reference
protected ApplicationLoadBalancedFargateService(ByRefValue reference)
Parameters
- reference Amazon.JSII.Runtime.Deputy.ByRefValue
The Javascript-owned object reference
ApplicationLoadBalancedFargateService(DeputyBase.DeputyProps)
Used by jsii to construct an instance of this class from DeputyProps
protected ApplicationLoadBalancedFargateService(DeputyBase.DeputyProps props)
Parameters
- props Amazon.JSII.Runtime.Deputy.DeputyBase.DeputyProps
The deputy props
ApplicationLoadBalancedFargateService(Construct, String, IApplicationLoadBalancedFargateServiceProps)
Constructs a new instance of the ApplicationLoadBalancedFargateService class.
public ApplicationLoadBalancedFargateService(Construct scope, string id, IApplicationLoadBalancedFargateServiceProps props = null)
Parameters
- scope Constructs.Construct
- id System.String
- props IApplicationLoadBalancedFargateServiceProps
Properties
AssignPublicIp
Determines whether the service will be assigned a public IP address.
public virtual bool AssignPublicIp { get; }
Property Value
System.Boolean
Service
The Fargate service in this construct.
public virtual FargateService Service { get; }
Property Value
TaskDefinition
The Fargate task definition in this construct.
public virtual FargateTaskDefinition TaskDefinition { get; }
Property Value