Keepalived
services.keepalived.enable
Whether to enable Keepalived.
Type: boolean
Default
false
Declared by: https://github.com/nixos/nixpkgs/blob/master/nixos/modules/services/networking/keepalived/default.nix
services.keepalived.enableScriptSecurity
Don't run scripts configured to be run as root if any part of the path is writable by a non-root user.
Type: boolean
Default
false
Declared by: https://github.com/nixos/nixpkgs/blob/master/nixos/modules/services/networking/keepalived/default.nix
services.keepalived.extraConfig
Extra lines to be added verbatim to the configuration file.
Type: strings concatenated with "\n"
Default
""
Declared by: https://github.com/nixos/nixpkgs/blob/master/nixos/modules/services/networking/keepalived/default.nix
services.keepalived.extraGlobalDefs
Extra lines to be added verbatim to the 'global_defs' block of the configuration file
Type: strings concatenated with "\n"
Default
""
Declared by: https://github.com/nixos/nixpkgs/blob/master/nixos/modules/services/networking/keepalived/default.nix
services.keepalived.openFirewall
Whether to automatically allow VRRP and AH packets in the firewall.
Type: boolean
Default
false
Declared by: https://github.com/nixos/nixpkgs/blob/master/nixos/modules/services/networking/keepalived/default.nix
services.keepalived.secretFile
Environment variables from this file will be interpolated into the
final config file using envsubst with this syntax: $ENVIRONMENT
or ${VARIABLE}
.
The file should contain lines formatted as SECRET_VAR=SECRET_VALUE
.
This is useful to avoid putting secrets into the nix store.
Type: null or path
Default
null
Example
"/run/keys/keepalived.env"
Declared by: https://github.com/nixos/nixpkgs/blob/master/nixos/modules/services/networking/keepalived/default.nix
services.keepalived.snmp.enable
Whether to enable the builtin AgentX subagent.
Type: boolean
Default
false
Declared by: https://github.com/nixos/nixpkgs/blob/master/nixos/modules/services/networking/keepalived/default.nix
services.keepalived.snmp.enableChecker
Enable SNMP handling of checker element of KEEPALIVED MIB.
Type: boolean
Default
false
Declared by: https://github.com/nixos/nixpkgs/blob/master/nixos/modules/services/networking/keepalived/default.nix
services.keepalived.snmp.enableKeepalived
Enable SNMP handling of vrrp element of KEEPALIVED MIB.
Type: boolean
Default
false
Declared by: https://github.com/nixos/nixpkgs/blob/master/nixos/modules/services/networking/keepalived/default.nix
services.keepalived.snmp.enableRfc
Enable SNMP handling of RFC2787 and RFC6527 VRRP MIBs.
Type: boolean
Default
false
Declared by: https://github.com/nixos/nixpkgs/blob/master/nixos/modules/services/networking/keepalived/default.nix
services.keepalived.snmp.enableRfcV2
Enable SNMP handling of RFC2787 VRRP MIB.
Type: boolean
Default
false
Declared by: https://github.com/nixos/nixpkgs/blob/master/nixos/modules/services/networking/keepalived/default.nix
services.keepalived.snmp.enableRfcV3
Enable SNMP handling of RFC6527 VRRP MIB.
Type: boolean
Default
false
Declared by: https://github.com/nixos/nixpkgs/blob/master/nixos/modules/services/networking/keepalived/default.nix
services.keepalived.snmp.enableTraps
Enable SNMP traps.
Type: boolean
Default
false
Declared by: https://github.com/nixos/nixpkgs/blob/master/nixos/modules/services/networking/keepalived/default.nix
services.keepalived.snmp.socket
Socket to use for connecting to SNMP master agent. If this value is set to null, keepalived's default will be used, which is unix:/var/agentx/master, unless using a network namespace, when the default is udp:localhost:705.
Type: null or string
Default
null
Declared by: https://github.com/nixos/nixpkgs/blob/master/nixos/modules/services/networking/keepalived/default.nix
services.keepalived.vrrpInstances
Declarative vhost config
Type: attribute set of (submodule)
Default
{ }
Declared by: https://github.com/nixos/nixpkgs/blob/master/nixos/modules/services/networking/keepalived/default.nix
services.keepalived.vrrpInstances.<name>.extraConfig
Extra lines to be added verbatim to the vrrp_instance section.
Type: strings concatenated with "\n"
Default
""
Declared by: https://github.com/nixos/nixpkgs/blob/master/nixos/modules/services/networking/keepalived/default.nix
services.keepalived.vrrpInstances.<name>.interface
Interface for inside_network, bound by vrrp.
Type: string
Declared by: https://github.com/nixos/nixpkgs/blob/master/nixos/modules/services/networking/keepalived/default.nix
services.keepalived.vrrpInstances.<name>.noPreempt
VRRP will normally preempt a lower priority machine when a higher priority machine comes online. "nopreempt" allows the lower priority machine to maintain the master role, even when a higher priority machine comes back online. NOTE: For this to work, the initial state of this entry must be BACKUP.
Type: boolean
Default
false
Declared by: https://github.com/nixos/nixpkgs/blob/master/nixos/modules/services/networking/keepalived/default.nix
services.keepalived.vrrpInstances.<name>.priority
For electing MASTER, highest priority wins. To be MASTER, make 50 more than other machines.
Type: signed integer
Default
100
Declared by: https://github.com/nixos/nixpkgs/blob/master/nixos/modules/services/networking/keepalived/default.nix
services.keepalived.vrrpInstances.<name>.state
Initial state. As soon as the other machine(s) come up, an election will be held and the machine with the highest "priority" will become MASTER. So the entry here doesn't matter a whole lot.
Type: one of "MASTER", "BACKUP"
Default
"BACKUP"
Declared by: https://github.com/nixos/nixpkgs/blob/master/nixos/modules/services/networking/keepalived/default.nix
services.keepalived.vrrpInstances.<name>.trackInterfaces
List of network interfaces to monitor for health tracking.
Type: list of string
Default
[ ]
Example
["eth0""eth1"]
Declared by: https://github.com/nixos/nixpkgs/blob/master/nixos/modules/services/networking/keepalived/default.nix
services.keepalived.vrrpInstances.<name>.trackScripts
List of script names to invoke for health tracking.
Type: list of string
Default
[ ]
Example
["chk_cmd1""chk_cmd2"]
Declared by: https://github.com/nixos/nixpkgs/blob/master/nixos/modules/services/networking/keepalived/default.nix
services.keepalived.vrrpInstances.<name>.unicastPeers
Do not send VRRP adverts over VRRP multicast group. Instead it sends adverts to the following list of ip addresses using unicast design fashion. It can be cool to use VRRP FSM and features in a networking environment where multicast is not supported! IP Addresses specified can IPv4 as well as IPv6.
Type: list of string
Default
[ ]
Declared by: https://github.com/nixos/nixpkgs/blob/master/nixos/modules/services/networking/keepalived/default.nix
services.keepalived.vrrpInstances.<name>.unicastSrcIp
Default IP for binding vrrpd is the primary IP on interface. If you want to hide location of vrrpd, use this IP as src_addr for unicast vrrp packets.
Type: null or string
Default
null
Declared by: https://github.com/nixos/nixpkgs/blob/master/nixos/modules/services/networking/keepalived/default.nix
services.keepalived.vrrpInstances.<name>.useVmac
Use VRRP Virtual MAC.
Type: boolean
Default
false
Declared by: https://github.com/nixos/nixpkgs/blob/master/nixos/modules/services/networking/keepalived/default.nix
services.keepalived.vrrpInstances.<name>.virtualIps
Declarative vhost config
Type: list of (submodule)
Default
[ ]
Declared by: https://github.com/nixos/nixpkgs/blob/master/nixos/modules/services/networking/keepalived/default.nix
services.keepalived.vrrpInstances.<name>.virtualIps.*.addr
IP address, optionally with a netmask: IPADDR[/MASK]
Type: string
Declared by: https://github.com/nixos/nixpkgs/blob/master/nixos/modules/services/networking/keepalived/default.nix
services.keepalived.vrrpInstances.<name>.virtualIps.*.brd
The broadcast address on the interface.
Type: null or string
Default
null
Declared by: https://github.com/nixos/nixpkgs/blob/master/nixos/modules/services/networking/keepalived/default.nix
services.keepalived.vrrpInstances.<name>.virtualIps.*.dev
The name of the device to add the address to.
Type: null or string
Default
null
Declared by: https://github.com/nixos/nixpkgs/blob/master/nixos/modules/services/networking/keepalived/default.nix
services.keepalived.vrrpInstances.<name>.virtualIps.*.label
Each address may be tagged with a label string. In order to preserve compatibility with Linux-2.0 net aliases, this string must coincide with the name of the device or must be prefixed with the device name followed by colon.
Type: null or string
Default
null
Declared by: https://github.com/nixos/nixpkgs/blob/master/nixos/modules/services/networking/keepalived/default.nix
services.keepalived.vrrpInstances.<name>.virtualIps.*.scope
The scope of the area where this address is valid.
Type: null or string
Default
null
Declared by: https://github.com/nixos/nixpkgs/blob/master/nixos/modules/services/networking/keepalived/default.nix
services.keepalived.vrrpInstances.<name>.virtualRouterId
Arbitrary unique number 1..255. Used to differentiate multiple instances of vrrpd running on the same NIC (and hence same socket).
Type: integer between 1 and 255 (both inclusive)
Declared by: https://github.com/nixos/nixpkgs/blob/master/nixos/modules/services/networking/keepalived/default.nix
services.keepalived.vrrpInstances.<name>.vmacInterface
Name of the vmac interface to use. keepalived will come up with a name if you don't specify one.
Type: null or string
Default
null
Declared by: https://github.com/nixos/nixpkgs/blob/master/nixos/modules/services/networking/keepalived/default.nix
services.keepalived.vrrpInstances.<name>.vmacXmitBase
Send/Recv VRRP messages from base interface instead of VMAC interface.
Type: boolean
Default
false
Declared by: https://github.com/nixos/nixpkgs/blob/master/nixos/modules/services/networking/keepalived/default.nix
services.keepalived.vrrpScripts
Declarative vrrp script config
Type: attribute set of (submodule)
Default
{ }
Declared by: https://github.com/nixos/nixpkgs/blob/master/nixos/modules/services/networking/keepalived/default.nix
services.keepalived.vrrpScripts.<name>.extraConfig
Extra lines to be added verbatim to the vrrp_script section.
Type: strings concatenated with "\n"
Default
""
Declared by: https://github.com/nixos/nixpkgs/blob/master/nixos/modules/services/networking/keepalived/default.nix
services.keepalived.vrrpScripts.<name>.fall
Required number of failures for KO transition.
Type: signed integer
Default
3
Declared by: https://github.com/nixos/nixpkgs/blob/master/nixos/modules/services/networking/keepalived/default.nix
services.keepalived.vrrpScripts.<name>.group
Name of group to run the script under. Defaults to user group.
Type: null or string
Default
null
Declared by: https://github.com/nixos/nixpkgs/blob/master/nixos/modules/services/networking/keepalived/default.nix
services.keepalived.vrrpScripts.<name>.interval
Seconds between script invocations.
Type: signed integer
Default
1
Declared by: https://github.com/nixos/nixpkgs/blob/master/nixos/modules/services/networking/keepalived/default.nix
services.keepalived.vrrpScripts.<name>.rise
Required number of successes for OK transition.
Type: signed integer
Default
5
Declared by: https://github.com/nixos/nixpkgs/blob/master/nixos/modules/services/networking/keepalived/default.nix
services.keepalived.vrrpScripts.<name>.script
(Path of) Script command to execute followed by args, i.e. cmd [args]...
Type: string
Example
"${pkgs.curl} -f http://localhost:80"
Declared by: https://github.com/nixos/nixpkgs/blob/master/nixos/modules/services/networking/keepalived/default.nix
services.keepalived.vrrpScripts.<name>.timeout
Seconds after which script is considered to have failed.
Type: signed integer
Default
5
Declared by: https://github.com/nixos/nixpkgs/blob/master/nixos/modules/services/networking/keepalived/default.nix
services.keepalived.vrrpScripts.<name>.user
Name of user to run the script under.
Type: string
Default
"keepalived_script"
Declared by: https://github.com/nixos/nixpkgs/blob/master/nixos/modules/services/networking/keepalived/default.nix
services.keepalived.vrrpScripts.<name>.weight
Following a failure, adjust the priority by this weight.
Type: signed integer
Default
0
Declared by: https://github.com/nixos/nixpkgs/blob/master/nixos/modules/services/networking/keepalived/default.nix