From 022e55d509a42aeefa3b9fb147296dc55384bc7f Mon Sep 17 00:00:00 2001 From: Piotr S Date: Wed, 15 May 2024 13:44:33 +0200 Subject: [PATCH] feat: ASAP-416 Add throttling configuration to public API (#4275) --- apps/gp2-server/serverless.ts | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/apps/gp2-server/serverless.ts b/apps/gp2-server/serverless.ts index 79d81a0343..25e8694990 100644 --- a/apps/gp2-server/serverless.ts +++ b/apps/gp2-server/serverless.ts @@ -1014,6 +1014,18 @@ const serverlessConfig: AWS = { ], }, }, + HttpApiStage: { + Type: 'AWS::ApiGatewayV2::Stage', + DependsOn: ['HttpApiRouteGetPublicProxyVar'], + Properties: { + RouteSettings: { + 'GET /public/{proxy+}': { + ThrottlingBurstLimit: 30, + ThrottlingRateLimit: 100, + }, + }, + }, + }, FrontendBucket: { Type: 'AWS::S3::Bucket', DeletionPolicy: 'Delete',