1
1
Fork 1
mirror of https://github.com/oddlama/nix-config.git synced 2025-10-11 07:10:39 +02:00

feat: enable impermanence

This commit is contained in:
oddlama 2023-05-01 11:49:37 +02:00
parent 30cfdaf860
commit 4cee692eff
No known key found for this signature in database
GPG key ID: 14EFE510775FE39A
7 changed files with 55 additions and 27 deletions

View file

@ -8,6 +8,7 @@
}: {
imports = [
./inputrc.nix
./impermanence.nix
./issue.nix
./net.nix
./nix.nix

View file

@ -0,0 +1,28 @@
{
# State that should be kept across reboots, but is otherwise
# NOT important information in any way that needs to be backed up.
#environment.persistence."/nix/state" = {
# hideMounts = true;
# files = [
# "/etc/machine-id"
# "/etc/ssh/ssh_host_ed25519_key"
# "/etc/ssh/ssh_host_ed25519_key.pub"
# ];
# directories = [
# "/var/log"
# ];
#};
# State that should be kept forever, and backed up accordingly.
environment.persistence."/persist" = {
hideMounts = true;
files = [
"/etc/machine-id"
"/etc/ssh/ssh_host_ed25519_key"
"/etc/ssh/ssh_host_ed25519_key.pub"
];
directories = [
"/var/log"
];
};
}

View file

@ -1,4 +1,5 @@
{
lib,
extraLib,
nodeSecrets,
pkgs,
@ -39,6 +40,8 @@
};
};
fileSystems."/persist".neededForBoot = true;
#environment.persistence."/persist".directories = [
# { directory = "/var/lib/acme"; user = "acme"; group = "acme"; }
#];