!coeAONBrWyDJnYMbMi:nixos.org

NixOS System Operations

627 Members
About system administration for running NixOS systems in production. Declaratively manage your operations. | Room recommendations: #networking:nixos.org172 Servers

You have reached the beginning of time (for this room).


SenderMessageTime
7 Dec 2024
@hexa:lossy.networkhexaso for one it doesn't like single quotes 😄 23:03:24
@hexa:lossy.networkhexaand doesn't complain about it23:03:28
@hexa:lossy.networkhexa *
  rulerConfig = {
    groups = [ {
      name = "postgresql";
      rules = [ {
        alert = "PostgresqlCollationMismatch";
        expr = ''
          {unit="postgresql.service"}
            |~ "WARNING:  database \"[^\"]+\" has a collation version mismatch"
            | regexp "database \"(?<database>[^\"]+)\""
        '';
        labels.severity = "warning";
        annotations.summary = "PostgreSQL database {{ $labels.database }} on {{ $labels.machine }}i reports database collation mismatch";
      } ];
    } ];
  };
23:04:17
8 Dec 2024
@adam:robins.wtf@adam:robins.wtf My favorite, when something silently accepts invalid input 00:22:52
@hexa:lossy.networkhexathe rules are just not as robust ans simple to test as promql00:49:26
@hexa:lossy.networkhexa
# lokitool rules lint ruler.yml 
ERRO[0000] unable parse rules file                       error="could not parse expression for alert 'PostgresqlCollationMismatch' in group 'postgresql': parse error at line 1, col 19: syntax error: unexpected IDENTIFIER" file=ruler.yml
lokitool: error: prepare operation unsuccessful, unable to parse rules files: file read error, try --help
00:50:15

Show newer messages


Back to Room ListRoom Version: 10