elasticsearch.conf 537 B

1234567891011121314151617181920
  1. #
  2. # this is the nginx config for elasticsearch with authentication for remote login
  3. # you need to create the auth file /etc/nginx/.htpasswd-elasticsearch with you username and password
  4. # this can be done on the shell via: 'htpasswd -b -c /etc/nginx/.htpasswd-elasticsearch USERNAME PASSWORD'
  5. #
  6. upstream elasticsearch {
  7. server 127.0.0.1:9200;
  8. }
  9. server {
  10. listen 9200;
  11. auth_basic "Elasticsearch";
  12. auth_basic_user_file /etc/nginx/.htpasswd-elasticsearch;
  13. location / {
  14. proxy_pass http://elasticsearch;
  15. }
  16. }