IgZiStO IgZiStO - 1 year ago 92
Apache Configuration Question

Running Apache Zeppelin with nginx as reverse proxy

In our current architecture we have two apache front servers, in front of them, we have an nginx load balancer. And in front of that an nginx reverse proxy.

My problem is that i'm trying to run Apache Zeppelin through the reverse proxy, and i'm having some problems with the websockets.

I get an error like this :

400 HTTP method GET is not supported by this URL

And here is a screenshot of what the Chrome's Networks tab shows :
enter image description here

I add my reverse proxy config for Zeppelin:

error_log /var/log/nginx/nginx_error.log warn;
server {
listen 80;
server_name localhost;

location /zeppelin/ {
proxy_pass http://zeppelin:8080/;
proxy_http_version 1.1;
proxy_set_header Upgrade websocket;
proxy_set_header Connection upgrade;

# fallback
location / {
return 301 http://ci.blablalablab.com/app/;

Zeppelin is running inside a docker container, and i have exposes the 8080 port, its host name is : zeppelin.

If you have any questions on the architecture or so, don't hesitate to ask.

Thank you very much guys !

Answer Source

After a lot of digging around, i ended up with this configuration :

location /zeppelin/ {
    proxy_pass http://zeppelin:8080/;
    proxy_set_header X-Real-IP $remote_addr;
    proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
    proxy_set_header Host $http_host;
    proxy_set_header X-NginX-Proxy true;
    proxy_redirect off;

location /zeppelin/ws {
    proxy_pass http://zeppelin:8080/ws;
    proxy_http_version 1.1;
    proxy_set_header Upgrade $http_upgrade;
    proxy_set_header Connection "Upgrade";

This is working pretty good, thank you everyone for your efforts ;)

Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download