Skip to content

Commit c2bed73

Browse files
authored
fix: expose api gateway utility constructs (#169)
* fix: expose Lambda API Gateway constructs * mark interface attributes as readonly to appease JSII3008
1 parent 7bdc3c8 commit c2bed73

File tree

2 files changed

+14
-12
lines changed

2 files changed

+14
-12
lines changed

lib/index.ts

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,12 @@
11
export * from "./bastion-host";
22
export * from "./database";
33
export * from "./ingestor-api";
4-
export * from "./stactools-item-generator";
5-
export * from "./stac-loader";
4+
export * from "./lambda-api-gateway-private";
5+
export * from "./lambda-api-gateway";
66
export * from "./stac-api";
7-
export * from "./titiler-pgstac-api";
87
export * from "./stac-browser";
8+
export * from "./stac-loader";
9+
export * from "./stactools-item-generator";
910
export * from "./tipg-api";
11+
export * from "./titiler-pgstac-api";
1012
export * from "./utils";

lib/lambda-api-gateway-private/index.ts

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -10,56 +10,56 @@ export interface PrivateLambdaApiGatewayProps {
1010
/**
1111
* Lambda function to integrate with the API Gateway.
1212
*/
13-
lambdaFunction: lambda.IFunction;
13+
readonly lambdaFunction: lambda.IFunction;
1414

1515
/**
1616
* Lambda integration options for the API Gateway.
1717
*/
18-
lambdaIntegrationOptions?: apigateway.LambdaIntegrationOptions;
18+
readonly lambdaIntegrationOptions?: apigateway.LambdaIntegrationOptions;
1919

2020
/**
2121
* VPC to create the API Gateway in.
2222
*/
23-
vpc: ec2.IVpc;
23+
readonly vpc: ec2.IVpc;
2424

2525
/**
2626
* Whether to create a VPC endpoint for the API Gateway.
2727
*
2828
* @default - true
2929
*/
30-
createVpcEndpoint?: boolean;
30+
readonly createVpcEndpoint?: boolean;
3131

3232
/**
3333
* The subnets in which to create a VPC endpoint network interface. At most one per availability zone.
3434
3535
*/
36-
vpcEndpointSubnetSelection?: ec2.SubnetSelection;
36+
readonly vpcEndpointSubnetSelection?: ec2.SubnetSelection;
3737

3838
/**
3939
* Name for the API Gateway.
4040
*
4141
* @default - `${scope.node.id}-private-api`
4242
*/
43-
restApiName?: string;
43+
readonly restApiName?: string;
4444

4545
/**
4646
* Description for the API Gateway.
4747
*
4848
* @default - "Private REST API Gateway"
4949
*/
50-
description?: string;
50+
readonly description?: string;
5151

5252
/**
5353
* Deploy options for the API Gateway.
5454
*/
55-
deployOptions?: apigateway.StageOptions;
55+
readonly deployOptions?: apigateway.StageOptions;
5656

5757
/**
5858
* Policy for the API Gateway.
5959
*
6060
* @default - Policy that allows any principal with the same VPC to invoke the API.
6161
*/
62-
policy?: iam.PolicyDocument;
62+
readonly policy?: iam.PolicyDocument;
6363
}
6464

6565
export class PrivateLambdaApiGateway extends Construct {

0 commit comments

Comments
 (0)