diff --git a/pkgs/servers/monitoring/consul-alerts/default.nix b/pkgs/servers/monitoring/consul-alerts/default.nix new file mode 100644 index 000000000000..98cb3a3db48c --- /dev/null +++ b/pkgs/servers/monitoring/consul-alerts/default.nix @@ -0,0 +1,18 @@ +# This file was generated by go2nix. +{ stdenv, lib, go16Packages, fetchgit, fetchhg, fetchbzr, fetchsvn }: + +with go16Packages; + +buildGoPackage rec { + name = "consul-alerts-${version}"; + version = "0.3.3"; + rev = "v${version}"; + + goPackagePath = "github.com/AcalephStorage/consul-alerts"; + + src = fetchgit { + inherit rev; + url = "https://github.com/AcalephStorage/consul-alerts"; + sha256 = "1w0mb20w1yazyh84sa30bsw271c5nm7lsx2qg0g3gf6mxdb63lpq"; + }; +} diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index d71d6d73ccab..522a81c0d792 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -706,7 +706,7 @@ in consul-ui = callPackage ../servers/consul/ui.nix { }; - consul-alerts = goPackages.consul-alerts.bin // { outputs = [ "bin" ]; }; + consul-alerts = callPackage ../servers/monitoring/consul-alerts { }; consul-template = goPackages.consul-template.bin // { outputs = [ "bin" ]; }; diff --git a/pkgs/top-level/go-packages.nix b/pkgs/top-level/go-packages.nix index 9cd4f7639742..f0bfad95df45 100644 --- a/pkgs/top-level/go-packages.nix +++ b/pkgs/top-level/go-packages.nix @@ -513,26 +513,6 @@ let sha256 = "0xmxy8ay0wzd307x7xba3rmigvr6rjlpfk9fmn6ir2nc97ifv3i0"; }; - consul-alerts = buildFromGitHub { - rev = "v0.3.3"; - owner = "AcalephStorage"; - repo = "consul-alerts"; - sha256 = "1w0mb20w1yazyh84sa30bsw271c5nm7lsx2qg0g3gf6mxdb63lpq"; - - renameImports = '' - # Remove all references to included dependency store - rm -rf go/src/github.com/AcalephStorage/consul-alerts/Godeps - govers -d -m github.com/AcalephStorage/consul-alerts/Godeps/_workspace/src/ "" - ''; - - # Temporary fix for name change - postPatch = '' - sed -i 's,SetApiKey,SetAPIKey,' notifier/opsgenie-notifier.go - ''; - - buildInputs = [ logrus docopt-go hipchat-go gopherduty consul-api opsgenie-go-sdk influxdb8-client ]; - }; - consul-migrate = buildFromGitHub { rev = "678fb10cdeae25ab309e99e655148f0bf65f9710"; version = "2015-05-19";