1 | import * as appscaling from '@aws-cdk/aws-applicationautoscaling';
|
2 | import * as ec2 from '@aws-cdk/aws-ec2';
|
3 | import * as elbv2 from '@aws-cdk/aws-elasticloadbalancingv2';
|
4 | import * as cloudmap from '@aws-cdk/aws-servicediscovery';
|
5 | import { Construct } from 'constructs';
|
6 | import { AssociateCloudMapServiceOptions, BaseService, BaseServiceOptions, CloudMapOptions, EcsTarget, IBaseService, IEcsLoadBalancerTarget, IService } from '../base/base-service';
|
7 | import { ScalableTaskCount } from '../base/scalable-task-count';
|
8 | import { LoadBalancerTargetOptions, TaskDefinition } from '../base/task-definition';
|
9 | import { ICluster } from '../cluster';
|
10 |
|
11 |
|
12 |
|
13 | export interface ExternalServiceProps extends BaseServiceOptions {
|
14 | |
15 |
|
16 |
|
17 |
|
18 |
|
19 | readonly taskDefinition: TaskDefinition;
|
20 | |
21 |
|
22 |
|
23 |
|
24 |
|
25 |
|
26 | readonly securityGroups?: ec2.ISecurityGroup[];
|
27 | }
|
28 |
|
29 |
|
30 |
|
31 | export interface IExternalService extends IService {
|
32 | }
|
33 |
|
34 |
|
35 |
|
36 | export interface ExternalServiceAttributes {
|
37 | |
38 |
|
39 |
|
40 | readonly cluster: ICluster;
|
41 | |
42 |
|
43 |
|
44 |
|
45 |
|
46 | readonly serviceArn?: string;
|
47 | |
48 |
|
49 |
|
50 |
|
51 |
|
52 | readonly serviceName?: string;
|
53 | }
|
54 |
|
55 |
|
56 |
|
57 |
|
58 |
|
59 | export declare class ExternalService extends BaseService implements IExternalService {
|
60 | |
61 |
|
62 |
|
63 | static fromExternalServiceArn(scope: Construct, id: string, externalServiceArn: string): IExternalService;
|
64 | |
65 |
|
66 |
|
67 | static fromExternalServiceAttributes(scope: Construct, id: string, attrs: ExternalServiceAttributes): IBaseService;
|
68 | |
69 |
|
70 |
|
71 | constructor(scope: Construct, id: string, props: ExternalServiceProps);
|
72 | /**
|
73 | * Overriden method to throw error as `attachToApplicationTargetGroup` is not supported for external service
|
74 | */
|
75 | attachToApplicationTargetGroup(_targetGroup: elbv2.IApplicationTargetGroup): elbv2.LoadBalancerTargetProps;
|
76 | /**
|
77 | * Overriden method to throw error as `loadBalancerTarget` is not supported for external service
|
78 | */
|
79 | loadBalancerTarget(_options: LoadBalancerTargetOptions): IEcsLoadBalancerTarget;
|
80 | /**
|
81 | * Overriden method to throw error as `registerLoadBalancerTargets` is not supported for external service
|
82 | */
|
83 | registerLoadBalancerTargets(..._targets: EcsTarget[]): void;
|
84 | /**
|
85 | * Overriden method to throw error as `configureAwsVpcNetworkingWithSecurityGroups` is not supported for external service
|
86 | */
|
87 | protected configureAwsVpcNetworkingWithSecurityGroups(_vpc: ec2.IVpc, _assignPublicIp?: boolean, _vpcSubnets?: ec2.SubnetSelection, _securityGroups?: ec2.ISecurityGroup[]): void;
|
88 | /**
|
89 | * Overriden method to throw error as `autoScaleTaskCount` is not supported for external service
|
90 | */
|
91 | autoScaleTaskCount(_props: appscaling.EnableScalingProps): ScalableTaskCount;
|
92 | /**
|
93 | * Overriden method to throw error as `enableCloudMap` is not supported for external service
|
94 | */
|
95 | enableCloudMap(_options: CloudMapOptions): cloudmap.Service;
|
96 | /**
|
97 | * Overriden method to throw error as `associateCloudMapService` is not supported for external service
|
98 | */
|
99 | associateCloudMapService(_options: AssociateCloudMapServiceOptions): void;
|
100 | }
|