diff --git a/pkgs/applications/virtualization/docker/gc.nix b/pkgs/applications/virtualization/docker/gc.nix new file mode 100644 index 000000000000..f9fb6311fc3a --- /dev/null +++ b/pkgs/applications/virtualization/docker/gc.nix @@ -0,0 +1,33 @@ +{ stdenv, lib, fetchFromGitHub, makeWrapper, docker, coreutils, procps, gnused, findutils, gnugrep }: + +with lib; + +stdenv.mkDerivation rec { + name = "docker-gc-${rev}"; + rev = "b0cc52aa3da2e2ac0080794e0be6e674b1f063fc"; + + src = fetchFromGitHub { + inherit rev; + owner = "spotify"; + repo = "docker-gc"; + sha256 = "07wf9yn0f771xkm3x12946x5rp83hxjkd70xgfgy35zvj27wskzm"; + }; + + buildInputs = [ makeWrapper ]; + + installPhase = '' + mkdir -p $out/bin + cp docker-gc $out/bin + chmod +x $out/bin/docker-gc + wrapProgram $out/bin/docker-gc \ + --prefix PATH : "${docker}/bin:${coreutils}/bin:${procps}/bin:${gnused}/bin:${findutils}/bin:${gnugrep}/bin" + ''; + + meta = { + description = "Docker garbage collection of containers and images"; + license = licenses.asl20; + homepage = https://github.com/spotify/docker-gc; + maintainers = with maintainers; [offline]; + platforms = docker.meta.platforms; + }; +} diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index e8364bec7de4..7dfa5149ca13 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -11268,6 +11268,8 @@ let docker = callPackage ../applications/virtualization/docker { go = go_1_4; }; + docker-gc = callPackage ../applications/virtualization/docker/gc.nix { }; + doodle = callPackage ../applications/search/doodle { }; drumgizmo = callPackage ../applications/audio/drumgizmo { };