nixpkgs-suyu/pkgs/servers/monitoring/cadvisor/default.nix
Ryan Mulligan bc7ca17345 cadvisor: 0.28.3 -> 0.29.1
Semi-automatic update. These checks were done:

- built on NixOS
- Warning: no binary found that responded to help or version flags. (This warning appears even if the package isn't expected to have binaries.)
- found 0.29.1 with grep in /nix/store/8zpvaz7imhsknld6d0qyykqw9b718lxi-cadvisor-0.29.1
- found 0.29.1 in filename of file in /nix/store/8zpvaz7imhsknld6d0qyykqw9b718lxi-cadvisor-0.29.1
2018-03-07 19:50:56 -08:00

34 lines
932 B
Nix

{ stdenv, lib, go, fetchFromGitHub }:
stdenv.mkDerivation rec {
name = "cadvisor-${version}";
version = "0.29.1";
src = fetchFromGitHub {
owner = "google";
repo = "cadvisor";
rev = "v${version}";
sha256 = "132mpcp35cymm2zqig0yrvhnvgn72k7cmn6gla0v7r0yxfl879m3";
};
nativeBuildInputs = [ go ];
buildPhase = ''
mkdir -p Godeps/_workspace/src/github.com/google/
ln -s $(pwd) Godeps/_workspace/src/github.com/google/cadvisor
GOPATH=$(pwd)/Godeps/_workspace go build -v -o cadvisor github.com/google/cadvisor
'';
installPhase = ''
mkdir -p $out/bin
mv cadvisor $out/bin
'';
meta = with stdenv.lib; {
description = "Analyzes resource usage and performance characteristics of running docker containers";
homepage = https://github.com/google/cadvisor;
license = licenses.asl20;
maintainers = with maintainers; [ offline ];
platforms = platforms.linux;
};
}