Error GOPATH

Hello,

I want to create my own Beat but unfortunately, I am faced with several problems that I can not solve or I do not understand.

In particular the GOPATH. What's the point ?

Because without really understanding its usefulness, I followed Golang's doc but I do not understand where I need to create my project file. and also able to execute the go get command without problem.

ahmed@ahmed-Charafouddine:~/go$ go env
GOARCH="amd64"
GOBIN=""
GOEXE=""
GOHOSTARCH="amd64"
GOHOSTOS="linux"
GOOS="linux"
GOPATH="/home/ahmed/go"
GORACE=""
GOROOT="/usr/lib/go"
GOTOOLDIR="/usr/lib/go/pkg/tool/linux_amd64"
GO15VENDOREXPERIMENT="1"
CC="gcc"
GOGCCFLAGS="-fPIC -m64 -pthread -fmessage-length=0"
CXX="g++"
CGO_ENABLED="1"

Version Golang :

ahmed@ahmed-Charafouddine:~/go$ go version
go version go1.6.2 linux/amd64

Merci !

Hi @charafouddine_ahmed,

I'm wondering if you are following our dev guide https://www.elastic.co/guide/en/beats/devguide/current/new-beat.html ?

Most of it should be explained there, happy to fill the gaps if there is something missing!

Thank you for the link. I will try to follow step by step

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.