Unverified Commit 15edec16 authored by Leona Maroni's avatar Leona Maroni Committed by GitHub
Browse files

VictoriaMetrics: 1.91.0 -> 1.91.3 (#242354)

Also allow binding to localhost on darwin
This is required to fix tests as they bind to localhost
parent da4daed5
Loading
Loading
Loading
Loading
+5 −16
Original line number Diff line number Diff line
{ lib, buildGoModule, fetchFromGitHub, fetchpatch, nixosTests }:
{ lib, buildGoModule, fetchFromGitHub, nixosTests }:

buildGoModule rec {
  pname = "VictoriaMetrics";
  version = "1.91.0";
  version = "1.91.3";

  src = fetchFromGitHub {
    owner = pname;
    repo = pname;
    rev = "v${version}";
    hash = "sha256-ZGUJfziqQCCv/9p+z8UJpvHkg6fKOIMv1tJ679f9NTo=";
    hash = "sha256-xW31Lm+WiJ1quMaIDa7tbZuKhILTMdUviIDTRJT1Cqg=";
  };

  vendorHash = null;

  patches = [
    (fetchpatch {
      name = "vmctl-fix-tests.patch";
      url = "https://github.com/VictoriaMetrics/VictoriaMetrics/commit/4060f3f261cb41d97df719e6c60b71be19829301.patch";
      hash = "sha256-SCeSdSLzZZodMiL7Kts0L8R5XD7TbOc5+/oidmithCY=";
    })
    (fetchpatch {
      name = "graphite-fixes-tests-for-arm.patch";
      url = "https://github.com/VictoriaMetrics/VictoriaMetrics/commit/228ea03bda0eda3507d782cb627d946843f29c30.patch";
      hash = "sha256-FnN5O9H1tNtBs5Fr4tXrnyted8SZwX82ZdBmeHlIQ2Y=";
    })
  ];

  postPatch = ''
    # main module (github.com/VictoriaMetrics/VictoriaMetrics) does not contain package
    # github.com/VictoriaMetrics/VictoriaMetrics/app/vmui/packages/vmui/web
@@ -47,6 +34,8 @@ buildGoModule rec {
    export ldflags=''${ldflags//=${version}/=}
  '';

  __darwinAllowLocalNetworking = true;

  passthru.tests = { inherit (nixosTests) victoriametrics; };

  meta = with lib; {