I hereby claim:
- I am dahernan on github.
- I am dahernan (https://keybase.io/dahernan) on keybase.
- I have a public key whose fingerprint is DF74 80B5 424D 0DDD 96AA 9E4E 0E34 CAA0 068D E384
To claim this, I am signing this object:
I hereby claim:
To claim this, I am signing this object:
David Hernandez is an independent Software Engineer in London, he helps companies to improve their software. He worked different countries like Spain, UK and Australia, participating in projects like the BBC London Olympics 2012, helping to achieve Continuous Delivery at Atlassian, or delivering services to the citizens at the Government Digital Services.
You can find David speaking and collaborating at Go London User Group, because Go is his favourite language.
$ redis-cli set sequence 1 | |
$ redis-cli set node_id 1 | |
-- id.lua | |
local epoch = 1288834974657 | |
local seq = tonumber(redis.call('INCR', 'sequence')) % 4096 | |
local node = tonumber(redis.call('GET', 'node_id')) % 1024 | |
local time = redis.call('TIME') | |
local time41 = ((tonumber(time[1]) * 1000) + (tonumber(time[2]) / 1000)) - epoch | |
return (time41 * (2 ^ 22)) + (node * (2 ^ 12)) + seq |
// example for Minimal Auth | |
// it does not compile is just as a guide for rolling your own | |
// some code for login by http post | |
func (a *AuthRoute) Login(w http.ResponseWriter, req *http.Request) { | |
var authForm map[string]string | |
err := RequestToJsonObject(req, &authForm) | |
if err != nil { | |
Render().JSON(w, http.StatusUnauthorized, nil) |
##Recommendation Engine Services
####IREUS Recommendation Engine for stores as SaaS
####Plista
# @gf3’s Sexy Bash Prompt, inspired by “Extravagant Zsh Prompt†| |
# Shamelessly copied from https://github.com/gf3/dotfiles | |
# Screenshot: http://i.imgur.com/s0Blh.png | |
if [[ $COLORTERM = gnome-* && $TERM = xterm ]] && infocmp gnome-256color >/dev/null 2>&1; then | |
export TERM=gnome-256color | |
elif infocmp xterm-256color >/dev/null 2>&1; then | |
export TERM=xterm-256color | |
fi |
$ docker run -d elasticsearch | |
$ docker ps | |
ID IMAGE COMMAND CREATED STATUS PORTS | |
29fd16250848 elasticsearch:latest /bin/sh -c elasticse 32 seconds ago Up 32 seconds 9200->9200 |
$ docker images | |
REPOSITORY TAG ID CREATED SIZE | |
ubuntu 12.04 8dbd9e392a96 3 months ago 131.5 MB (virtual 131.5 MB) | |
ubuntu 12.10 b750fe79269d 4 months ago 24.65 kB (virtual 180.1 MB) | |
ubuntu latest 8dbd9e392a96 3 months ago 131.5 MB (virtual 131.5 MB) | |
ubuntu precise 8dbd9e392a96 3 months ago 131.5 MB (virtual 131.5 MB) | |
ubuntu quantal b750fe79269d 4 months ago 24.65 kB (virtual 180.1 MB) | |
elasticsearch latest ef2487bb289d 52 seconds ago 12.29 kB (virtual 558.7 MB) |
FROM ubuntu | |
MAINTAINER dahernan "[email protected]" | |
# Java 7 | |
RUN echo "deb http://ppa.launchpad.net/webupd8team/java/ubuntu precise main" | tee -a /etc/apt/sources.list | |
RUN apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys EEA14886 | |
RUN apt-get update | |
RUN echo oracle-java7-installer shared/accepted-oracle-license-v1-1 select true | /usr/bin/debconf-set-selections | |
RUN apt-get install oracle-java7-installer -y |