How to configure Nginx for redirect not hosted domain names in Hestia to another webserver?

task
hestia2

i try

/etc/nginx/conf.d/ip.conf
server {
listen 80;
#TCP traffic will be forwarded to the specified server
proxy_pass 192.168.0.36:80;
}
server {
listen 443;
#TCP traffic will be forwarded to the specified server
proxy_pass 192.168.0.36:443;
}

err:
proxy_pass" directive is not allowed here
and
stream" directive is not allowed here to

I think it should be…
server {
listen 192.168.0.36:80 default_server;
server_name _;
access_log off;
error_log /dev/null;

location / {
proxy_pass http://192.168.0.37:80;
}
}

BUT , I’m not sure. Maybe someone else could help :thinking: