mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-11-22 23:13:19 +00:00
nixos/containers: check nixos-container names for underscores
This commit is contained in:
parent
f163eaf644
commit
108a6f181a
@ -509,6 +509,12 @@ in
|
||||
for details).
|
||||
'';
|
||||
}
|
||||
{
|
||||
assertion = !lib.strings.hasInfix "_" name;
|
||||
message = ''
|
||||
Names containing underscores are not allowed in nixos-containers. Please rename the container '${name}'
|
||||
'';
|
||||
}
|
||||
];
|
||||
};
|
||||
};
|
||||
|
Loading…
Reference in New Issue
Block a user