chore: format with alejandra
This commit is contained in:
parent
05f0cbdfb4
commit
89f5f65f2d
181 changed files with 2720 additions and 2560 deletions
|
@ -1,14 +1,19 @@
|
|||
{ keys ? import ../../variables/keys.nix
|
||||
, passwords ? import ../../variables/passwords.crypt.nix }:
|
||||
|
||||
{
|
||||
mkRoot = { }@args:
|
||||
keys ? import ../../variables/keys.nix,
|
||||
passwords ? import ../../variables/passwords.crypt.nix,
|
||||
}: {
|
||||
mkRoot = {} @ args:
|
||||
{
|
||||
hashedPassword = passwords.users.root;
|
||||
openssh.authorizedKeys.keys = keys.users.steveej.openssh;
|
||||
} // args;
|
||||
}
|
||||
// args;
|
||||
|
||||
mkUser = { uid, hashedPassword ? passwords.users.steveej, ... }@args:
|
||||
mkUser = {
|
||||
uid,
|
||||
hashedPassword ? passwords.users.steveej,
|
||||
...
|
||||
} @ args:
|
||||
{
|
||||
inherit uid hashedPassword;
|
||||
isNormalUser = true;
|
||||
|
@ -26,7 +31,8 @@
|
|||
"adbusers"
|
||||
];
|
||||
openssh.authorizedKeys.keys = keys.users.steveej.openssh;
|
||||
} // args;
|
||||
}
|
||||
// args;
|
||||
|
||||
disk = rec {
|
||||
# TODO: verify the GPT PARTLABEL cap at 36 chars
|
||||
|
@ -34,7 +40,7 @@
|
|||
|
||||
# LVM doesn't allow most characters in VG names
|
||||
# TODO: replace this with a whitelist for: [a-zA-Z0-9.-_+]
|
||||
volumeGroup = diskId: builtins.replaceStrings [ ":" ] [ "" ] diskId;
|
||||
volumeGroup = diskId: builtins.replaceStrings [":"] [""] diskId;
|
||||
|
||||
# This is important at install-time
|
||||
bootGrubDevice = diskId: "/dev/disk/by-id/" + diskId;
|
||||
|
@ -52,9 +58,8 @@
|
|||
luksName = diskId: (volumeGroup diskId) + "pv";
|
||||
luksPhysicalVolume = diskId: "/dev/mapper/" + (luksName diskId);
|
||||
lvmPv = diskId: encrypted:
|
||||
if encrypted == true then
|
||||
luksPhysicalVolume diskId
|
||||
else
|
||||
bootLuksDevice diskId;
|
||||
if encrypted == true
|
||||
then luksPhysicalVolume diskId
|
||||
else bootLuksDevice diskId;
|
||||
};
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue