Skip to content
IROSG.
Articles

Production reverse proxying with NGINX: headers, timeouts, TLS and trust

An original source-backed IROSG IT guide.

Production reverse proxying with NGINX: headers, timeouts, TLS and trust

Scope

This original IROSG guide covers طراحی Reverse Proxy production با NGINX using the cited primary documentation.

Core model

Reverse proxy بین client و upstream قرار می‌گیرد و می‌تواند TLS termination، routing، buffering و header transformation انجام دهد. همین نقش آن را به مرز اعتماد تبدیل می‌کند؛ application باید بداند کدام header را از چه proxyای باور کند.

Practical workflow

Host، X-Forwarded-For/Proto و timeoutها را آگاهانه تنظیم کنید. health check و upstream failure را از status code application جدا ببینید. log request ID در هر دو لایه correlation را آسان می‌کند.

Failure modes

اعتماد مستقیم به X-Forwarded-For ورودی از اینترنت می‌تواند IP spoofing منطقی ایجاد کند. timeout خیلی بلند resource را نگه می‌دارد و خیلی کوتاه workload سالم را قطع می‌کند.

Lab

دو upstream بسازید، NGINX را جلوی آن‌ها قرار دهید، headerها و timeout را تست کنید و یک upstream را عمداً خاموش کنید. رفتار error و logها را ثبت کنید.

Production method

Capture a baseline, change one variable at a time, test positive and negative paths, keep evidence, and rehearse rollback before broad rollout.

TRACEABLE KNOWLEDGE

Sources & further reading

01
NGINX — مرجع فنیhttps://docs.nginx.com/nginx/admin-guide/web-server/reverse-proxy

Editorial review date:

IROSG / EDITORIAL

News and pioneer profiles use original writing with source attribution. Image credits and licenses are kept in each page’s sources section instead of beneath the images. CVE reference data credits its primary sources.

Editorial and image policy ↗

Keep exploring.

Articles ↗
VyOS network operating systemArticles
Networking

VyOS network operating system

Original Persian technical editorial based on the official sources below. It covers the subject, architecture, practical use cases, important limitations and defensive considerations.

1 min readRead story
Routinator RPKI validatorArticles
Networking

Routinator RPKI validator

Original Persian technical editorial based on the official sources below. It covers the subject, architecture, practical use cases, important limitations and defensive considerations.

1 min readRead story
ISC Kea DHCP High AvailabilityArticles
Networking

ISC Kea DHCP High Availability

Original Persian technical editorial based on the official sources below. It covers the subject, architecture, practical use cases, important limitations and defensive considerations.

1 min readRead story