Files
dev/configs/nixos/registry/local-route.nix

26 lines
594 B
Nix

{ lib, ... }:
{
checks = [
{
assertion = lib.registry.predicates.uniqueValue (entry: entry.value.domain);
message = "Local route domains must be unique.";
}
];
type = lib.types.submodule {
options = {
domain = lib.mkOption {
type = lib.types.str;
example = "home";
description = "Local HTTP domain served by this route entry.";
};
port = lib.mkOption {
type = lib.types.port;
example = 8082;
description = "Backend TCP port served by the matching address registry entry.";
};
};
};
}