Building custom filebeat debian

Thanks @steffen for the pointers.

I basically imported the filebeat Makefile to the filebeat repo and added the following to build the debian package I needed.

BEAT_DIR=com.abc.xyz/filebeat
ES_BEATS=./vendor/github.com/elastic/beats
GOPACKAGES=$(shell glide novendor)
SNAPSHOT=no
include $(ES_BEATS)/libbeat/scripts/Makefile

However, for some reason, i had to comment out the following in libbeat/before_build.sh file

# Install gotpl. Clone and copy needed as go-yaml is behind a proxy which doesn't work
# with git 1.7
#git clone https://github.com/tsg/gotpl.git /go/src/github.com/tsg/gotpl
#mkdir -p /go/src/gopkg.in/yaml.v2
#cp -r /go/src/github.com/elastic/beats/vendor/gopkg.in/yaml.v2 /go/src/gopkg.in/
#go install github.com/tsg/gotpl

and had to install gotpl manually to get it working.