CONSFIGURATOR.PROPERTY.NETWORK
API reference
General
Property: NETWORK:ALIASES
(network:aliases &rest aliases)
Record other DNS names by which the host is known. For example, a mail server might have aliases like imap.example.org and smtp.example.org, even though its hostname is neither ‘imap’ nor ‘smtp’.
Property: NETWORK:IPV4
(network:ipv4 &rest addresses)
Record the host’s public Internet IPv4 addresses.
If you need to record other addresses in hostattrs, such as on a LAN, write a similar property which pushes hostattrs identified by a non-keyword symbol (unless your consfig deals only in hosts without public IP addresses, in which case you can use this property).
Property: NETWORK:IPV6
(network:ipv6 &rest addresses)
Record the host’s public Internet IPv6 addresses.
If you need to record other addresses in hostattrs, such as on a LAN, write a similar property which pushes hostattrs identified by a non-keyword symbol (unless your consfig deals only in hosts without public IP addresses, in which case you can use this property).
Property: NETWORK:CLEAN-/ETC/NETWORK/INTERFACES
(network:clean-/etc/network/interfaces)
Empty /etc/network/interfaces in preparation for configuring interfaces using /etc/network/interfaces.d. On fresh installs this property should not be necessary, but it is useful for removing configuration inserted by your VPS hosting provider, for example.
Property: NETWORK:STATIC
(network:static interface address &optional gateway netmask &rest options)
Configures an interface with a static IP address. OPTIONS is a list of even length of alternating keys and values.
Property: NETWORK:PRESERVE-STATIC-ONCE
(network:preserve-static-once &optional interface &rest options)
Writes configuration to bring up INTERFACE, statically, with the IP addresses and routing configuration currently associated with the interface, assuming that INTERFACE has already been brought up by other means, such as DHCP. INTERFACE defaults to the interface of the default route. This property does nothing if the interface configuration file already exists. OPTIONS is a list of even length of alternating keys and values.
IPv6 addresses are ignored, as it is assumed these use stateless configuration of some form, which is best implemented using a property which does not query the networking stack’s current state like this one does.