Здравствуйте, коллеги!
Использую следующую схему работы NGINX Reverse Proxy Server:
Ни как не могу добиться передачи сертификата от конечных Web Server'ов, у меня постоянно приходит сертификат от главного NGINX Reverse Proxy Server'a.
Использую следующие записи:
server {
listen 12.77.0.221:80;
server_name crm.at5.su www.crm.at5.su;
access_log /var/www/httpd-logs/crm.at5.su.access.log;
error_log /var/www/httpd-logs/crm.at5.su.error.log notice;
location ~* {
proxy_ignore_client_abort on;
proxy_pass https://12.77.0.213:80;
proxy_redirect https://12.77.0.213:80 ~*;
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-Port $server_port;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto $scheme;
}
}
server {
listen 12.77.0.221:443;
server_name crm.at5.su www.crm.at5.su;
access_log /var/www/httpd-logs/crm.at5.su.access.log;
error_log /var/www/httpd-logs/crm.at5.su.error.log notice;
location ~* {
proxy_ignore_client_abort on;
proxy_pass https://12.77.0.213:443;
proxy_redirect https://12.77.0.213:443 ~*;
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-Port $server_port;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto $scheme;
proxy_set_header HTTPS YES;
}
}
server {
listen 12.77.0.221:8893;
server_name crm.at5.su www.crm.at5.su;
access_log /var/www/httpd-logs/crm.at5.su.access.log;
error_log /var/www/httpd-logs/crm.at5.su.error.log notice;
location ~* {
proxy_ignore_client_abort on;
proxy_pass https://12.77.0.213:8893;
proxy_redirect https://12.77.0.213:8893 ~*;
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-Port $server_port;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto $scheme;
proxy_set_header HTTPS YES;
}
}
server {
listen 12.77.0.221:8894;
server_name crm.at5.su www.crm.at5.su;
access_log /var/www/httpd-logs/crm.at5.su.access.log;
error_log /var/www/httpd-logs/crm.at5.su.error.log notice;
location ~* {
proxy_ignore_client_abort on;
proxy_pass https://12.77.0.213:8894;
proxy_redirect https://12.77.0.213:8894 ~*;
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-Port $server_port;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto $scheme;
proxy_set_header HTTPS YES;
}
}