Improve custom iso
This commit is contained in:
parent
2357c5d3d6
commit
1b180a8a25
4 changed files with 57 additions and 18 deletions
hosts/nixos
|
@ -3,7 +3,13 @@
|
|||
# users' home persist dir exists and has the right permissions
|
||||
#
|
||||
# It works even if / is tmpfs, btrfs snapshot, or even not ephemeral at all.
|
||||
{ lib, inputs, config, ... }: {
|
||||
{
|
||||
lib,
|
||||
inputs,
|
||||
config,
|
||||
...
|
||||
}:
|
||||
{
|
||||
imports = [ inputs.impermanence.nixosModules.impermanence ];
|
||||
|
||||
environment.persistence."/persist/state".directories = [
|
||||
|
@ -19,11 +25,13 @@
|
|||
# {{{ Create home directories
|
||||
systemd.tmpfiles.rules =
|
||||
let
|
||||
users = lib.filter (v: v != null && v.isNormalUser)
|
||||
(lib.mapAttrsToList (_: u: u) config.users.users);
|
||||
users = lib.filter (v: v != null && v.isNormalUser) (
|
||||
lib.mapAttrsToList (_: u: u) config.users.users
|
||||
);
|
||||
|
||||
mkHomePersistFor = location: lib.forEach users
|
||||
(user: "Q ${location}${user.home} ${user.homeMode} ${user.name} ${user.group} -");
|
||||
mkHomePersistFor =
|
||||
location:
|
||||
lib.forEach users (user: "d ${location}${user.home} ${user.homeMode} ${user.name} ${user.group} -");
|
||||
in
|
||||
lib.flatten [
|
||||
(mkHomePersistFor "/persist/data")
|
||||
|
@ -32,4 +40,3 @@
|
|||
];
|
||||
# }}}
|
||||
}
|
||||
|
||||
|
|
|
@ -1,13 +1,23 @@
|
|||
{ modulesPath, pkgs, ... }:
|
||||
{ modulesPath, ... }:
|
||||
{
|
||||
imports = [
|
||||
"${modulesPath}/installer/cd-dvd/installation-cd-minimal.nix"
|
||||
|
||||
../common/global/services/openssh.nix
|
||||
../common/global/locale.nix
|
||||
../common/global/cli/fish.nix
|
||||
../common/global/nix.nix
|
||||
../common/global
|
||||
../common/optional/wayland/hyprland.nix
|
||||
];
|
||||
|
||||
environment.systemPackages = [ pkgs.neovim ];
|
||||
# Tell sops-nix to use the hermes keys for decrypting secrets
|
||||
sops.age.sshKeyPaths = [ "/hermes/secrets/hermes/ssh_host_ed25519_key" ];
|
||||
|
||||
# {{{ Automount hermes
|
||||
fileSystems."/hermes" = {
|
||||
device = "/dev/disk/by-uuid/7FE7-CA68";
|
||||
neededForBoot = true;
|
||||
options = [
|
||||
"nofail"
|
||||
"x-systemd.automount"
|
||||
];
|
||||
};
|
||||
# }}}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue