helmfile 0.21.0 (new formula)
Closes #28436. Signed-off-by: Dominyk Tiller <dominyktiller@gmail.com>
This commit is contained in:
parent
2f41351626
commit
7ae10498c3
1 changed files with 30 additions and 0 deletions
30
Formula/helmfile.rb
Normal file
30
Formula/helmfile.rb
Normal file
|
@ -0,0 +1,30 @@
|
|||
class Helmfile < Formula
|
||||
desc "Deploy Kubernetes Helm Charts"
|
||||
homepage "https://github.com/roboll/helmfile"
|
||||
url "https://github.com/roboll/helmfile/archive/v0.21.0.tar.gz"
|
||||
sha256 "75503bd10fbff95fa5c4d84ef2aff8f62774eeec2d5a73d1025271883cd330f2"
|
||||
|
||||
depends_on "go" => :build
|
||||
depends_on "kubernetes-helm"
|
||||
|
||||
def install
|
||||
ENV["GOPATH"] = buildpath
|
||||
(buildpath/"src/github.com/roboll/helmfile").install buildpath.children
|
||||
cd "src/github.com/roboll/helmfile" do
|
||||
system "go", "build", "-ldflags", "-X main.Version=v#{version}",
|
||||
"-o", bin/"helmfile", "-v", "github.com/roboll/helmfile"
|
||||
prefix.install_metafiles
|
||||
end
|
||||
end
|
||||
|
||||
test do
|
||||
(testpath/"helmfile.yaml").write <<-EOS
|
||||
repositories:
|
||||
- name: stable
|
||||
url: https://kubernetes-charts.storage.googleapis.com/
|
||||
EOS
|
||||
system Formula["kubernetes-helm"].opt_bin/"helm", "init", "--client-only"
|
||||
output = '"stable" has been added to your repositories'
|
||||
assert_match output, shell_output("#{bin}/helmfile -f helmfile.yaml repos")
|
||||
end
|
||||
end
|
Loading…
Reference in a new issue