import { ContainerImage, FargateService, FargateTaskDefinition, ICluster } from 'aws-cdk-lib/aws-ecs'; import { IRepository } from 'aws-cdk-lib/aws-ecr'; import BaseModule, { BaseDefaults, BaseSettings } from './base-module'; import { TaskEnvironment } from '../utilities/environment'; import { ISecurityGroup, SubnetSelection } from 'aws-cdk-lib/aws-ec2'; import ConvertivBaseStack from '../stacks/base-stack'; import { Secret } from 'aws-cdk-lib/aws-ecs'; export interface QueueServiceSettings extends BaseSettings { name: string; cluster: ICluster; desired: number; containerPort?: number | null; elbPort?: number | null; cpu: number; memory: number; gracePeriod?: number; min?: number; max?: number; environment?: TaskEnvironment; secrets?: { [key: string]: Secret; }; securityGroups?: ISecurityGroup[]; tag: string; image: string | null; imageArn: string | null; vpcSubnets?: SubnetSelection; } export interface QueueServiceDefaults extends BaseDefaults { name: string; desired: number; cpu: number; memory: number; min: number; max: number; environment: TaskEnvironment; tag: string; } /** * A Fargate service running on an ECS cluster fronted by an application load balancer. */ export declare class QueueService extends BaseModule { settings: QueueServiceSettings; /** * Define the defaults for the service */ defaults: QueueServiceDefaults; /** * Expose the task definition */ taskDefinition: FargateTaskDefinition; /** * Expose the service definition */ service: FargateService; repo: IRepository; image: ContainerImage; /** * Run the base validator, and then allow the class to * perform additional validation * @param settings */ validate(settings: QueueServiceSettings): void; /** * Constructs a new instance of the ApplicationLoadBalancedFargateService class. */ constructor(scope: ConvertivBaseStack, settings: QueueServiceSettings); }