i figured it out myself -- it can be done and it's pretty easy!
[code]
server {
listen 443;
server_name ....devcenter.int;
ssl on;
ssl_certificate /etc/nginx/....crt;
ssl_certificate_key /etc/nginx/....key;
proxy_redirect off;
proxy_set_header Host $host;
proxy_set_header X-Real-IP $remote_addr;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
location / {
if ($http_cookie ~* "(; )?devredirect=aurora") {
proxy_pass https://10.0.0.20;
break;
}
if ($http_cookie ~* "(; )?devredirect=...") {
proxy_pass https://10.0.0.22;
break;
}
...
}
}
[/code]