Skip to content

Commit

Permalink
feat: increase keep-alive and idle timeouts
Browse files Browse the repository at this point in the history
- Updated KEEP_ALIVE_TIMEOUT in gateway and web Dockerfiles from 121000 to 601000.
- Updated server.ts to use the new keep-alive timeout value.
- Updated idleTimeout in alb.ts from 120 to 600.
  • Loading branch information
geclos committed Dec 10, 2024
1 parent e9efb72 commit 3d7d3c0
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion apps/gateway/docker/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ ARG PORT=8080

ENV PORT $PORT
ENV NODE_ENV=production
ENV KEEP_ALIVE_TIMEOUT 121000
ENV KEEP_ALIVE_TIMEOUT 601000

EXPOSE $PORT

Expand Down
2 changes: 1 addition & 1 deletion apps/gateway/src/server.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ serve(
serverOptions: {
keepAliveTimeout: process.env.KEEP_ALIVE_TIMEOUT
? Number(process.env.KEEP_ALIVE_TIMEOUT)
: 121000,
: 601000,
},
},
(info) => {
Expand Down
2 changes: 1 addition & 1 deletion apps/infra/src/core/alb.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ const alb = new aws.lb.LoadBalancer('alb', {
securityGroups: [shared.albSecurityGroup],
subnets: subnets.euCentral.public,
enableDeletionProtection: true,
idleTimeout: 120,
idleTimeout: 600,
accessLogs: {
bucket: albLogsBucket.id,
enabled: true,
Expand Down
2 changes: 1 addition & 1 deletion apps/web/docker/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,7 @@ ENV HOSTNAME $HOSTNAME
ENV PORT $PORT
ENV NODE_ENV=production
ENV NEXT_TELEMETRY_DISABLED=1
ENV KEEP_ALIVE_TIMEOUT 121000
ENV KEEP_ALIVE_TIMEOUT 601000

EXPOSE $PORT

Expand Down

0 comments on commit 3d7d3c0

Please sign in to comment.