# Can't build with beats-packer on Ubuntu 16.04: .../xgo: cannot download

**URL:** https://discuss.elastic.co/t/cant-build-with-beats-packer-on-ubuntu-16-04-xgo-cannot-download/50460
**Category:** Beats
**Created:** [May 19, 2016, 3:31pm UTC](https://discuss.elastic.co/t/cant-build-with-beats-packer-on-ubuntu-16-04-xgo-cannot-download/50460 "2016-05-19T15:31:05Z")
**Posts on this page:** 7
**Page:** 1

<div class="post-metadata">

### Author: ![dviljoen](https://avatars.discourse-cdn.com/v4/letter/d/a5b964/32.png) [@dviljoen](https://discuss.elastic.co/u/dviljoen)
#### Post date: [May 19, 2016, 3:31pm UTC](https://discuss.elastic.co/t/cant-build-with-beats-packer-on-ubuntu-16-04-xgo-cannot-download/50460/1 "2016-05-19T15:31:05Z")

</div>

Trying to build filebeat for arm. Using beats-packer w/docker. Make images and make pull-images both succeed. Make deps fails:

go get [github.com/tsg/xgo](http://github.com/tsg/xgo)  
package [github.com/tsg/xgo:](http://github.com/tsg/xgo:) cannot download, $GOPATH not set. For more details see: go help gopath  
Makefile:49: recipe for target 'deps' failed  
make: \*\*\* [deps] Error 1

Searched for this error came up empty.

---

<div class="post-metadata">

### Author: ![ruflin](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/ruflin/32/3116_2.png) [@ruflin](https://discuss.elastic.co/u/ruflin)
#### Post date: [May 20, 2016, 6:33am UTC](https://discuss.elastic.co/t/cant-build-with-beats-packer-on-ubuntu-16-04-xgo-cannot-download/50460/2 "2016-05-20T06:33:01Z")

</div>

It seems like your GOPATH is not setup properly. Best is to use `go help gopath` to get some more details on how to do this as recommended in the error.

---

<div class="post-metadata">

### Author: ![dviljoen](https://avatars.discourse-cdn.com/v4/letter/d/a5b964/32.png) [@dviljoen](https://discuss.elastic.co/u/dviljoen)
#### Post date: [May 20, 2016, 1:06pm UTC](https://discuss.elastic.co/t/cant-build-with-beats-packer-on-ubuntu-16-04-xgo-cannot-download/50460/3 "2016-05-20T13:06:38Z")

</div>

Sorry for my ignorance, but isn't this building inside of docker instance? And so shouldn't the environment set the GOPATH?

---

<div class="post-metadata">

### Author: ![ruflin](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/ruflin/32/3116_2.png) [@ruflin](https://discuss.elastic.co/u/ruflin)
#### Post date: [May 23, 2016, 7:30am UTC](https://discuss.elastic.co/t/cant-build-with-beats-packer-on-ubuntu-16-04-xgo-cannot-download/50460/4 "2016-05-23T07:30:09Z")

</div>

Which beats-packer are you using? The one in the beats repo or the separate beats-packer repo?

---

<div class="post-metadata">

### Author: ![dviljoen](https://avatars.discourse-cdn.com/v4/letter/d/a5b964/32.png) [@dviljoen](https://discuss.elastic.co/u/dviljoen)
#### Post date: [May 23, 2016, 1:21pm UTC](https://discuss.elastic.co/t/cant-build-with-beats-packer-on-ubuntu-16-04-xgo-cannot-download/50460/5 "2016-05-23T13:21:35Z")

</div>

From GitHub - here [https://github.com/elastic/beats-packer](https://github.com/elastic/beats-packer)

---

<div class="post-metadata">

### Author: ![ruflin](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/ruflin/32/3116_2.png) [@ruflin](https://discuss.elastic.co/u/ruflin)
#### Post date: [May 23, 2016, 3:53pm UTC](https://discuss.elastic.co/t/cant-build-with-beats-packer-on-ubuntu-16-04-xgo-cannot-download/50460/6 "2016-05-23T15:53:04Z")

</div>

Ok, I see. That is probably the issue. We recently moved all packer stuff into the beats repo here: [https://github.com/elastic/beats/tree/master/dev-tools/packer](https://github.com/elastic/beats/tree/master/dev-tools/packer)

---

<div class="post-metadata">

### Author: ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)
#### Post date: [July 5, 2017, 9:51pm UTC](https://discuss.elastic.co/t/cant-build-with-beats-packer-on-ubuntu-16-04-xgo-cannot-download/50460/7 "2017-07-05T21:51:38Z")

</div>


