3
0
Fork 0
forked from mirrors/nixpkgs
nixpkgs/pkgs/servers/monitoring/cadvisor/default.nix
R. RyanTM a2fcc1f7a8 cadvisor: 0.29.1 -> 0.30.2
Semi-automatic update generated by https://github.com/ryantm/nixpkgs-update tools. This update was made based on information from https://repology.org/metapackage/cadvisor/versions.
2018-08-08 19:28:02 -07:00

35 lines
927 B
Nix

{ stdenv, go, fetchFromGitHub }:
stdenv.mkDerivation rec {
name = "cadvisor-${version}";
version = "0.30.2";
src = fetchFromGitHub {
owner = "google";
repo = "cadvisor";
rev = "v${version}";
sha256 = "143jsm0pbfhsa2iwkg5zanl9qxbpmsdvay5djyac4rvgl53m0wy9";
};
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;
};
}