homebrew-core/Formula/rancher-compose.rb

20 lines
744 B
Ruby
Raw Normal View History

class RancherCompose < Formula
desc "Docker compose compatible client to deploy to Rancher"
homepage "https://github.com/rancher/rancher-compose"
url "https://github.com/rancher/rancher-compose/archive/v0.4.0.tar.gz"
sha256 "07192c7ef554fadc1ef62c32ee942526f013109dd5bacb04642b22fd6f1aeec7"
depends_on "go" => :build
def install
ENV["GOPATH"] = "#{buildpath}:#{buildpath}/Godeps/_workspace"
mkdir_p "#{buildpath}/src/github.com/rancher"
ln_s buildpath, "#{buildpath}/src/github.com/rancher/rancher-compose"
system "go", "build", "-ldflags", "-w -X github.com/rancher/rancher-compose/version.VERSION #{version}", "-o", "#{bin}/rancher-compose"
end
test do
system "#{bin}/rancher-compose", "help"
end
end