2019-08-13 20:02:34 +02:00
|
|
|
{ stdenv
|
|
|
|
, buildGoModule
|
|
|
|
, fetchFromGitHub
|
|
|
|
, go-bindata
|
2020-04-28 10:27:52 +02:00
|
|
|
, installShellFiles
|
|
|
|
, pkg-config
|
|
|
|
, which
|
2019-08-13 20:02:34 +02:00
|
|
|
, libvirt
|
|
|
|
, vmnet
|
2018-06-06 23:38:05 +02:00
|
|
|
}:
|
2017-01-31 18:39:24 +01:00
|
|
|
|
2019-08-13 20:02:34 +02:00
|
|
|
buildGoModule rec {
|
2020-04-28 10:27:52 +02:00
|
|
|
pname = "minikube";
|
2020-10-14 08:30:40 +02:00
|
|
|
version = "1.14.0";
|
2020-04-28 10:27:52 +02:00
|
|
|
|
2020-10-14 08:30:40 +02:00
|
|
|
vendorSha256 = "03imagmsfj9rv5g2sybpdx9y7vdwag3mrsjibgsbq3jhf7r1ib3g";
|
2017-03-12 02:12:53 +01:00
|
|
|
|
2020-08-04 02:26:27 +02:00
|
|
|
doCheck = false;
|
|
|
|
|
2017-03-12 02:12:53 +01:00
|
|
|
src = fetchFromGitHub {
|
2020-04-28 10:27:52 +02:00
|
|
|
owner = "kubernetes";
|
|
|
|
repo = "minikube";
|
|
|
|
rev = "v${version}";
|
2020-10-14 08:30:40 +02:00
|
|
|
sha256 = "1nwpgfgw3vg8zy3mvjja13vdj12mys4crdm8cfimv9g3ka08dqpx";
|
2016-12-06 02:23:59 +01:00
|
|
|
};
|
|
|
|
|
2020-04-28 10:27:52 +02:00
|
|
|
nativeBuildInputs = [ go-bindata installShellFiles pkg-config which ];
|
2017-03-05 04:23:44 +01:00
|
|
|
|
2020-04-28 10:27:52 +02:00
|
|
|
buildInputs = if stdenv.isDarwin then [ vmnet ] else if stdenv.isLinux then [ libvirt ] else null;
|
2017-01-31 18:39:24 +01:00
|
|
|
|
2020-04-28 10:27:52 +02:00
|
|
|
buildPhase = ''
|
2020-07-12 11:20:00 +02:00
|
|
|
make COMMIT=${src.rev}
|
2017-03-12 02:12:53 +01:00
|
|
|
'';
|
|
|
|
|
2020-04-28 10:27:52 +02:00
|
|
|
installPhase = ''
|
|
|
|
install out/minikube -Dt $out/bin
|
|
|
|
|
|
|
|
export HOME=$PWD
|
|
|
|
export MINIKUBE_WANTUPDATENOTIFICATION=false
|
|
|
|
export MINIKUBE_WANTKUBECTLDOWNLOADMSG=false
|
2019-08-13 20:02:34 +02:00
|
|
|
|
2020-07-12 11:20:00 +02:00
|
|
|
for shell in bash zsh fish; do
|
2020-04-28 10:27:52 +02:00
|
|
|
$out/bin/minikube completion $shell > minikube.$shell
|
|
|
|
installShellCompletion minikube.$shell
|
|
|
|
done
|
2018-05-08 04:38:29 +02:00
|
|
|
'';
|
2017-03-12 02:12:53 +01:00
|
|
|
|
2016-12-06 02:23:59 +01:00
|
|
|
meta = with stdenv.lib; {
|
2020-04-28 10:27:52 +02:00
|
|
|
homepage = "https://minikube.sigs.k8s.io";
|
2016-12-06 02:23:59 +01:00
|
|
|
description = "A tool that makes it easy to run Kubernetes locally";
|
2020-04-28 10:27:52 +02:00
|
|
|
license = licenses.asl20;
|
2020-10-10 02:34:52 +02:00
|
|
|
maintainers = with maintainers; [ ebzzry copumpkin vdemeester atkinschang Chili-Man ];
|
2020-04-28 10:27:52 +02:00
|
|
|
platforms = platforms.unix;
|
2016-12-06 02:23:59 +01:00
|
|
|
};
|
|
|
|
}
|