Quantcast
Channel: Nginx Forum - How to...
Viewing all articles
Browse latest Browse all 4759

Re: ftp proxy with nginx

$
0
0
I see this interesting module, it's seems to work with ftp but ...

https://www.nginx.com/resources/admin-guide/tcp-load-balancing/

but... I don't know how to configure it for using different subdomains in source

the server_name directive is not allowed inside stream module


so at the moment I have this

stream {
server {
listen 21;
proxy_pass ip_vm_1:21;
}
server {
listen 20;
proxy_pass ip_vm_1:20;
}
}

when I introduce this it doesn't work

stream {
server {
listen 21;
server_name preprod.domain.fr
proxy_pass ip_vm_1:21;
}
server {
listen 20;
server_name preprod.domain.fr
proxy_pass ip_vm_1:20;
}
server {
listen 21;
server_name prod.domain.fr
proxy_pass ip_vm_2:21;
}
server {
listen 20;
server_name prod.domain.fr
proxy_pass ip_vm_2:20;
}


== server_name is not allowed here --> KO

How can I differanciate the source subdomain ?

Viewing all articles
Browse latest Browse all 4759

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>