Skip to content

Instantly share code, notes, and snippets.

View xthexder's full-sized avatar

Jacob Wirth xthexder

View GitHub Profile
@xthexder
xthexder / session.go
Last active August 29, 2015 13:56
Revel SessionFilter for storing sessions in redis. Adds a config option for setting and verifying CSRF tokens.
package app
import (
"crypto/rand"
"encoding/hex"
"fmt"
"net/http"
"strings"
"time"
@mystix
mystix / install-elasticsearch-debian
Last active March 19, 2023 15:14 — forked from karussell/install-elasticsearch-debian
Install ElasticSearch on Debian
VERSION=0.20.6
sudo apt-get update
sudo apt-get install openjdk-6-jdk
wget https://download.elasticsearch.org/elasticsearch/elasticsearch/elasticsearch-$VERSION.deb
sudo dpkg -i elasticsearch-$VERSION.deb
# be sure you add "action.disable_delete_all_indices" : true to the config!!