Nix::getHydraNotifyPrometheusConfig: print errors if the configuration provided is invalid.

[?]
Aug 24, 2021, 3:35 PM
33GPMIWV27YGFKQBGHVSOOVUTSIWYTGDNNWPJAVLWCOIJK6D5VCQC

Dependencies

  • [2] 4H6FVIWG hydra-notify: make the prometheus endpoint configurable, default-off
  • [3] 5DXGOH6Q statsd: add a chance to set hostname and port in hydra.conf
  • [*] 2GK5DOU7 * Downloading closures.

Change contents

  • replacement in src/lib/Hydra/Helper/Nix.pm at line 77
    [2.868][2.868:916]()
    if (!defined($cfg) || ref $cfg ne "HASH") {
    [2.868]
    [2.916]
    if (!defined($cfg)) {
    return undef;
    }
    if (ref $cfg ne "HASH") {
    print STDERR "Error reading Hydra's configuration file: hydra_notify should be a block.\n";
  • replacement in src/lib/Hydra/Helper/Nix.pm at line 87
    [2.979][2.979:1027]()
    if (!defined($cfg) || ref $cfg ne "HASH") {
    [2.979]
    [2.1027]
    if (!defined($cfg)) {
    return undef;
    }
    if (ref $cfg ne "HASH") {
    print STDERR "Error reading Hydra's configuration file: hydra_notify.prometheus should be a block.\n";
  • edit in src/lib/Hydra/Helper/Nix.pm at line 101
    [2.1252]
    [2.1252]
    } else {
    print STDERR "Error reading Hydra's configuration file: hydra_notify.prometheus should include listen_address and port.\n";
    return undef;