大网数据广告活动
服务器运维问答

Is reverse proxy still required between AWS ALB and application server?

· 52CE 我爱测

Context Web application with application server, i.e. Ruby on Rails with puma. Running within a container on AWS ECS with Fargate. Traffic is routed by AWS Application Load Balancer directly to application server running within c…

问题原文

原帖链接 · Leszek Zalewski · CC BY-SA 4.0

Context

Web application with application server, i.e. Ruby on Rails with puma. Running within a container on AWS ECS with Fargate. Traffic is routed by AWS Application Load Balancer directly to application server running within container.

Question

Is reverse proxy still required between ALB and application itself, i.e. as sidecar container? What would be the benefit?

已采纳解答

原帖链接 · Garreth McDaid · CC BY-SA 4.0

A reverse proxy isn't required, but the web servers that ship with Rails have minimal functionality, so for any application that is public facing and can potentially grow, its a good idea to integrate a reverse proxy (eg Nginx) early on.

For example, this would give you advanced rate-limiting capability, caching and the ability to do end to end SSL termination with a lot less fuss that other web server implementations. Logging also becomes a lot easier, and stuff like TCP retries can be a life saver if your application is under load.

You don't need a sidecar. You can install Nginx on the same box as your application. Its super efficient and will not impact your application performance.

We use multiple Nginx proxies in front of Rails, and we serve billions of http requests per day.

Massive reverse proxying implementations such as Cloudflare are also built on Nginx.

摘自公开归档,保留原文语言,版式经整理,外部媒体与邮箱地址已移除。

资料来源与适用范围

资料来源
Server Fault
适用范围
以原帖系统、软件版本与发布日期为准(2020-01-16)
内容语言
中文;命令、路径和错误标识保留技术原文
本地收录日期
2026-11-15
授权说明
CC BY-SA 4.0

正文与所需资源由本站本地存储。查看来源及更新记录 ↗

请按适用版本和实际日志确认原因;本站没有对每一种系统或设备逐项执行文中的操作。