Skip to content

Instantly share code, notes, and snippets.

@jmvillaveces
Forked from mathieue/reverse.es
Created September 28, 2015 08:10
Show Gist options
  • Select an option

  • Save jmvillaveces/cc6ad9b98b925d8d64ec to your computer and use it in GitHub Desktop.

Select an option

Save jmvillaveces/cc6ad9b98b925d8d64ec to your computer and use it in GitHub Desktop.
Simple apache read only reverse proxy on elasticsearch
<VirtualHost *:80>
ServerName es.yourhost.com
<Proxy balancer://main>
BalancerMember http://127.0.0.1:9200 max=1 retry=5
<Limit GET >
order deny,allow
deny from all
allow from 127.0.0.1
allow from 8.8.8.8 # your ip
</Limit>
<Limit POST PUT DELETE>
order deny,allow
deny from all
</Limit>
</Proxy>
ProxyPass / balancer://main/
ProxyPassReverse / balancer://main/
</VirtualHost>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment