Something went wrong. Try again.
my over complex system configurations
Something went wrong. Try again.
12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152{ lib }:let inherit (lib.types) str; inherit (lib.options) mkOption mkEnableOption;
/** A quick way to use my services abstraction
# Arguments
- [name]: The name of the service
# Type
``` mkServiceOption :: String -> (Int -> String -> String -> AttrSet) -> AttrSet ``` */ mkServiceOption = name: { port ? 0, host ? "0.0.0.0", domain ? "", }: { enable = mkEnableOption "Enable the ${name} service";
host = mkOption { type = str; default = host; description = "The host for ${name} service"; };
port = mkOption { type = lib.types.port; default = port; description = "The port for ${name} service"; };
domain = mkOption { type = str; default = domain; defaultText = "networking.domain"; description = "Domain name for the ${name} service"; }; };in{ inherit mkServiceOption;}