Complete Lab 5 for Grade 4

This commit is contained in:
paflove
2026-11-23 17:20:36 +03:00
parent 276dbdad8a
commit 93744ea8d0
26 changed files with 2568 additions and 15 deletions
+36
View File
@@ -0,0 +1,36 @@
events {
worker_connections 1024;
}
http {
client_max_body_size 15m;
upstream api_cluster {
server api:8000 max_fails=2 fail_timeout=5s;
keepalive 64;
}
server {
listen 8080;
location / {
proxy_pass http://api_cluster;
proxy_http_version 1.1;
proxy_set_header Connection "";
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Request-Id $http_x_request_id;
proxy_next_upstream error timeout http_502 http_503 http_504 non_idempotent;
proxy_next_upstream_timeout 10s;
proxy_next_upstream_tries 3;
proxy_connect_timeout 2s;
proxy_read_timeout 10s;
}
}
}