host/asus: persist docker
This commit is contained in:
parent
57d8d2a610
commit
0fe23e8bf8
1 changed files with 29 additions and 16 deletions
|
@ -1,4 +1,4 @@
|
||||||
{ lib, ... }:
|
{ config, lib, ... }:
|
||||||
|
|
||||||
{
|
{
|
||||||
# A setup which would clean root subvolume between boots remove automatically removed roots that
|
# A setup which would clean root subvolume between boots remove automatically removed roots that
|
||||||
|
@ -36,20 +36,33 @@
|
||||||
"ssh_host_ed25519_key"
|
"ssh_host_ed25519_key"
|
||||||
];
|
];
|
||||||
|
|
||||||
environment.persistence."/persistent/system" = {
|
environment.persistence = {
|
||||||
hideMounts = true;
|
"/persistent/system" = {
|
||||||
directories = [
|
hideMounts = true;
|
||||||
"/var/lib/bluetooth"
|
directories = [
|
||||||
"/var/lib/nixos"
|
"/var/lib/bluetooth"
|
||||||
"/var/lib/systemd/coredump"
|
"/var/lib/nixos"
|
||||||
"/etc/NetworkManager/system-connections"
|
"/var/lib/systemd/coredump"
|
||||||
];
|
"/etc/NetworkManager/system-connections"
|
||||||
files = [
|
];
|
||||||
"/etc/machine-id"
|
files = [
|
||||||
"/etc/ssh/ssh_host_rsa_key"
|
"/etc/machine-id"
|
||||||
"/etc/ssh/ssh_host_rsa_key.pub"
|
"/etc/ssh/ssh_host_rsa_key"
|
||||||
"/etc/ssh/ssh_host_ed25519_key"
|
"/etc/ssh/ssh_host_rsa_key.pub"
|
||||||
"/etc/ssh/ssh_host_ed25519_key.pub"
|
"/etc/ssh/ssh_host_ed25519_key"
|
||||||
];
|
"/etc/ssh/ssh_host_ed25519_key.pub"
|
||||||
|
];
|
||||||
|
};
|
||||||
|
"/persistent/docker" = lib.mkIf config.virtualisation.docker.enable {
|
||||||
|
hideMounts = true;
|
||||||
|
directories = map (v: "/var/lib/docker/${v}") [
|
||||||
|
"containers"
|
||||||
|
"volumes"
|
||||||
|
"image"
|
||||||
|
"overlay2"
|
||||||
|
"network"
|
||||||
|
];
|
||||||
|
files = [ "/var/lib/docker/engine-id" ];
|
||||||
|
};
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue