Using Godeps vendoring with Codeship
Yesterday, I switched from using Go 1.4 to Go 1.6 to build our binaries on Codeship. I also started using the new vendoring approach and settled on Godeps as our vendoring tool.
Whilst the support for Go and custom Go versions on Codeship is great, it’s sadly not that well documented.
The first thing you need to do is to change the version of Go. This Codeship page explains how you need to add the right commands to your Setup Commands section, but that doesn’t help you with getting Godeps working.
After bit of experimenting, I came up with the a solution. After switching to the Go 1.6 version in your Setup Commands section, you also need to install Godeps and restore and install those packages:
# install Godeps now
go get github.com/tools/godep
# restore packages
cd ${HOME}/src/github.com/AndiamoHQ/patient-frontend-web
godep restore
godep go install
That’s it.