0
**Servers:**
**1. Nginx server (Global ip 111.111.111.1111, get all connections. Have local IP (192.168.0.1))

2. Nginx Proxy Manager(Docker container, Have ONLY local IP(192.168.0.2))**



**№1 SERVER **hawe worked (HTTP) record in nginx:
`server {
    listen       192.168.0.1:80;
    server_name  sitename1.com;
    server_name  sitename1.com;

    location / {
        proxy_set_header X-Real-IP $remote_addr;
        proxy_set_header Host $host;
        proxy_pass http://192.168.0.2;
    }
}`



**№2 SERVER** have docker Nginx Proxy Manager with url(sitename1.com, sitename2.com) rewrides and SSL HTTPS!


**TASK: 
how to take certificates from server 2, whereas the request goes initially to server 1?**

found option proxy_ssl_certificate_key but CERT on another server. And Cert directory typed:

WARNING: DO NOT MOVE OR RENAME THESE FILES!
         Certbot expects these files to remain in this location in order
         to function properly!

On the 1st server, you need to write everything manually, and on the 2nd server there is a proxy manager and everything can be done by clicking. Therefore, I want to redirect some sites. And on the 1st you can't change anything globally

0 Answers0