Is there a basic configuration for using nginx with kibana as a reverse proxy server.
Here is my configuration:
server {
listen 80 default_server;
listen [::]:80 default_server;
server_name _;
return 301 https://$host$request_uri;
}
upstream websocket {
server 127.0.0.1:80;
}
server {
listen 443 ssl;
server_name my_server;
auth_basic "Restricted Access";
auth_basic_user_file /etc/nginx/htpasswd.users;
location /kibana {
rewrite ^/kibana/(.*)$ /$1 break;
proxy_pass http://127.0.0.1:5601;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection 'upgrade';
proxy_set_header Host $host;
proxy_cache_bypass $http_upgrade;
}
No matter what i try it just wont work.