-
Notifications
You must be signed in to change notification settings - Fork 21
Description
I wanna allow two presto urls from nginx. bellow is the configuration of nginx.
presto-1 IP :172.18.0.14
presto-2 IP :172.18.0.12
but only one presto coordinator is running at a time. I wanna allow both presto working.
Below is the content of this file /etc/nginx/conf.d/ssl.conf :
server {
listen 443 ssl;
server_name _;
ssl_certificate /root/server.crt;
ssl_certificate_key /root/server.key;
ssl_protocols TLSv1 TLSv1.1 TLSv1.2;
ssl_ciphers HIGH:!aNULL:!MD5;
# Load configuration files for the default server block.
include /etc/nginx/default.d/*.conf;
location /presto-1/{
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection "upgrade";
proxy_pass https://172.18.0.14:8443/;
}
location /presto-2/{
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection "upgrade";
proxy_pass https://172.18.0.12:8443/;
}
location /v1/query/{
proxy_pass https://172.18.0.14:8443/v1/query/;
}
location /v1/cluster/{
proxy_pass https://172.18.0.14:8443/v1/cluster/;
}
location /v1/info/{
proxy_pass http://172.18.0.14:9090/v1/info;
}
}