Skip to content

Instantly share code, notes, and snippets.

@vuchau
Forked from sthomp/kibana_nginx.conf
Created May 9, 2017 06:25
Show Gist options
  • Save vuchau/16d16318e96c4cc7f7b7ed441b8fcfb9 to your computer and use it in GitHub Desktop.
Save vuchau/16d16318e96c4cc7f7b7ed441b8fcfb9 to your computer and use it in GitHub Desktop.
nginx config to proxy connections to kibana on aws
worker_processes 1;
events {
worker_connections 1024;
}
http{
server {
listen 80;
server_name localhost;
# redirect /
location = / {
rewrite ^ /_plugin/kibana/ redirect;
}
# redirect /dashboard
location = /dashboard {
rewrite ^ /_plugin/kibana/#/dashboard/My-Dashboard?_g=(refreshInterval:(display:'1%20minute',section:2,value:60000),time:(from:now-7d,mode:quick,to:now)) redirect;
}
location / {
proxy_pass https://<my-search-domain>.us-east-1.es.amazonaws.com;
proxy_pass_request_headers off;
auth_basic "Restricted";
auth_basic_user_file htpasswd;
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment