How does telegraf build pull in fpm dependency

Im trying to build telegraf locally away from using make file.

In the build steps there is one step that builds the package

go build -i -o $(TELEGRAF) -ldflags “$(LDFLAGS)” ./cmd/telegraf/telegraf.go

This step internally uses fpm for building the package.

Although im interested in only building a tar file, I would like to know how i can pull in the fpm package as a dependency as part of the build process.

That step doesn’t use fpm, but the make package target does:

package:
	./scripts/build.py --package --platform=all --arch=all

It’s a little messy, but we normally install fpm in scripts/circle-test.sh. I recommend installing this package outside of the build system as a prerequisite, in the same way you would install Go and make.