Building conjure-up on Ubuntu 16.04 that requires golang 1.8

I’m having trouble figuring out how to build conjure-up on my Ubuntu 16.04 hosts that requires a newer golang than what’s provided in the deb archives. In launchpad you can set a source archive to pull additional packages from when building and that works fine but I’d like to continue to build test snaps locally without having to upgrade my host machine to Artful.

I’ve tried a couple things already including, adding ppa:~juju/golang to my host machine and specifying golang-1.8 in build-packages for my juju part. However, snapcraft always tries to pull in the go binary for golang-1.6 (default on Xenial 16.04).

Does anyone have any recommendations for doing this? Would doing a cleanbuild work? If so, whats the recommended way to do something like this?

Take a look at vault, here:

It’s using the go remote part. The downside is that it has to compile go, but that’s pretty quick. And on the roadmap is to support snaps as build packages, so you could use @mwhudson’s snaps instead.

1 Like

@gary-wzl Above recipe might be interesting to you too

Thanks for the mention here.
Yeah, It’s a neat and reasonable way to use remote part to utilize golang 1.8.
Same question is that building golang from source doesn’t benefit from patches applied in go1.8.1 / artful.
Please correct me if I was mistaken. @elopio

Yea as it’s only building from upstream go sources you won’t get any security patches etc that were applied in artful.