-
-
Notifications
You must be signed in to change notification settings - Fork 12.5k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Closes #45603. Signed-off-by: Rui Chen <[email protected]>
- Loading branch information
1 parent
6e90df4
commit 1d8d1f6
Showing
1 changed file
with
36 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
class Minikube < Formula | ||
desc "Run a Kubernetes cluster locally" | ||
homepage "https://minikube.sigs.k8s.io/" | ||
url "https://github.com/kubernetes/minikube.git", | ||
:tag => "v1.5.0", | ||
:revision => "d1151d93385a70c5a03775e166e94067791fe2d9" | ||
head "https://github.com/kubernetes/minikube.git" | ||
|
||
depends_on "go" => :build | ||
depends_on "go-bindata" => :build | ||
depends_on "kubernetes-cli" | ||
|
||
def install | ||
system "make" | ||
bin.install "out/minikube" | ||
|
||
output = Utils.popen_read("#{bin}/minikube completion bash") | ||
(bash_completion/"minikube").write output | ||
|
||
output = Utils.popen_read("#{bin}/minikube completion zsh") | ||
(zsh_completion/"_minikube").write output | ||
end | ||
|
||
test do | ||
output = shell_output("#{bin}/minikube version") | ||
assert_match "version: v#{version}", output | ||
|
||
(testpath/".minikube/config/config.json").write <<~EOS | ||
{ | ||
"vm-driver": "virtualbox" | ||
} | ||
EOS | ||
output = shell_output("#{bin}/minikube config view") | ||
assert_match "vm-driver: virtualbox", output | ||
end | ||
end |