Skip to content

Instantly share code, notes, and snippets.

View vhyza's full-sized avatar

Vojtěch Hýža vhyza

View GitHub Profile
@karmi
karmi / nginx-elasticsearch-proxy.conf
Created May 23, 2011 08:16
Route requests to ElasticSearch to authenticated user's own index with an Nginx reverse-proxy
# Run me with:
#
# $ nginx -p /path/to/this/file/ -c nginx.conf
#
# All requests are then routed to authenticated user's index, so
#
# GET http://user:password@localhost:8080/_search?q=*
#
# is rewritten to:
#
@karmi
karmi / slingshot.rb
Created February 6, 2011 14:17
Sketch of a Ruby API for ElasticSearch [http://elasticsearch.com]
# Sketch of a Ruby API for ElasticSearch [http://elasticsearch.com]
require 'rubygems'
require 'curb'
require 'rest_client'
require 'yajl/json_gem'
module Slingshot
def http
@karmi
karmi / mac_os_setup.sh
Created December 19, 2010 13:43
Installation Instructions For Setting Up A Clean Mac OS X System
# =====================================================
# Installation instructions for a clean Mac OS X system
# =====================================================
#
# <https://gist.github.com/747336>
#
# Keep only `.ssh` and `.profile.local` files from backup
# + Clean up Apple Ruby