/home/suroeste/public_html/payments.transportessuroeste.com/docker/nginx
Edit: /home/suroeste/public_html/payments.transportessuroeste.com/docker/nginx/nginx.conf (3337B)
# ============================================================================
# TRANSPORTES SUROESTE - Nginx Main Configuration
# ============================================================================
# Production-optimized and security-hardened
# ============================================================================
user nginx;
worker_processes auto;
worker_rlimit_nofile 8192;
pid /var/run/nginx.pid;
error_log /var/log/nginx/error.log warn;
events {
worker_connections 2048;
multi_accept on;
use epoll;
}
http {
# ========================================================================
# Basic settings
# ========================================================================
include /etc/nginx/mime.types;
default_type application/octet-stream;
# Hide server version
server_tokens off;
more_clear_headers Server;
# Charset
charset utf-8;
charset_types text/plain text/css application/json application/javascript text/xml;
# ========================================================================
# Logging
# ========================================================================
log_format main '$remote_addr - $remote_user [$time_local] '
'"$request" $status $body_bytes_sent '
'"$http_referer" "$http_user_agent" '
'$request_time $upstream_response_time';
access_log /var/log/nginx/access.log main;
error_log /var/log/nginx/error.log warn;
# ========================================================================
# Performance
# ========================================================================
sendfile on;
tcp_nopush on;
tcp_nodelay on;
keepalive_timeout 65;
keepalive_requests 100;
types_hash_max_size 2048;
client_max_body_size 8m;
client_body_buffer_size 16k;
client_header_buffer_size 1k;
large_client_header_buffers 4 8k;
# ========================================================================
# Gzip compression
# ========================================================================
gzip on;
gzip_vary on;
gzip_proxied any;
gzip_comp_level 4;
gzip_min_length 256;
gzip_types
text/plain
text/css
text/xml
text/javascript
application/json
application/javascript
application/xml
application/rss+xml
image/svg+xml;
# ========================================================================
# Rate limiting zones
# ========================================================================
limit_req_zone $binary_remote_addr zone=api:10m rate=30r/s;
limit_req_zone $binary_remote_addr zone=payment:10m rate=5r/s;
limit_req_zone $binary_remote_addr zone=login:10m rate=3r/s;
limit_conn_zone $binary_remote_addr zone=conn_limit:10m;
# ========================================================================
# Upstream (PHP-FPM)
# ========================================================================
upstream php-fpm {
server php:9000;
keepalive 16;
}
# Include site configs
include /etc/nginx/conf.d/*.conf;
}