Do not allow multiple definitions of IP addresses etc. within an interface
This commit is contained in:
parent
92ef9d6b46
commit
dbefab9cf4
@ -14,14 +14,14 @@ let
|
|||||||
|
|
||||||
name = mkOption {
|
name = mkOption {
|
||||||
example = "eth0";
|
example = "eth0";
|
||||||
type = types.string;
|
type = types.uniq types.string;
|
||||||
description = "Name of the interface.";
|
description = "Name of the interface.";
|
||||||
};
|
};
|
||||||
|
|
||||||
ipAddress = mkOption {
|
ipAddress = mkOption {
|
||||||
default = null;
|
default = null;
|
||||||
example = "10.0.0.1";
|
example = "10.0.0.1";
|
||||||
type = types.nullOr types.string;
|
type = types.nullOr (types.uniq types.string);
|
||||||
description = ''
|
description = ''
|
||||||
IP address of the interface. Leave empty to configure the
|
IP address of the interface. Leave empty to configure the
|
||||||
interface using DHCP.
|
interface using DHCP.
|
||||||
@ -41,7 +41,7 @@ let
|
|||||||
subnetMask = mkOption {
|
subnetMask = mkOption {
|
||||||
default = "";
|
default = "";
|
||||||
example = "255.255.255.0";
|
example = "255.255.255.0";
|
||||||
type = types.string;
|
type = types.uniq types.string;
|
||||||
description = ''
|
description = ''
|
||||||
Subnet mask of the interface, specified as a bitmask.
|
Subnet mask of the interface, specified as a bitmask.
|
||||||
This is deprecated; use <option>prefixLength</option>
|
This is deprecated; use <option>prefixLength</option>
|
||||||
@ -52,7 +52,7 @@ let
|
|||||||
macAddress = mkOption {
|
macAddress = mkOption {
|
||||||
default = null;
|
default = null;
|
||||||
example = "00:11:22:33:44:55";
|
example = "00:11:22:33:44:55";
|
||||||
type = types.nullOr types.string;
|
type = types.nullOr (types.uniq types.string);
|
||||||
description = ''
|
description = ''
|
||||||
MAC address of the interface. Leave empty to use the default.
|
MAC address of the interface. Leave empty to use the default.
|
||||||
'';
|
'';
|
||||||
|
Loading…
Reference in New Issue
Block a user