diff --git a/hosts/xps16/configuration.nix b/hosts/xps16/configuration.nix index 939cba1..a0d96e1 100644 --- a/hosts/xps16/configuration.nix +++ b/hosts/xps16/configuration.nix @@ -13,6 +13,8 @@ ./services/thermald.nix ./services/tlp.nix + ./machines + ./testconfig.nix ]; diff --git a/hosts/xps16/machines/arch.nix b/hosts/xps16/machines/arch.nix new file mode 100644 index 0000000..d264ae9 --- /dev/null +++ b/hosts/xps16/machines/arch.nix @@ -0,0 +1,25 @@ +{ ... }: +{ + systemd.nspawn."arch" = { + enable = true; + execConfig.Boot = true; + + filesConfig = { + BindReadOnly = [ + "/nix/store" + # "/etc/resolv.conf:/etc/resolv.conf" + ]; + Bind = [ + "/home/h7x4/git" + "/home/h7x4/Downloads" + ]; + }; + networkConfig.Private = false; + }; + + systemd.services."systemd-nspawn@arch" = { + enable = true; + requiredBy = [ "machines.target" ]; + overrideStrategy = "asDropin"; + }; +} diff --git a/hosts/xps16/machines/default.nix b/hosts/xps16/machines/default.nix new file mode 100644 index 0000000..ccbf54f --- /dev/null +++ b/hosts/xps16/machines/default.nix @@ -0,0 +1,7 @@ +{ + imports = [ + ./arch.nix + ]; + + systemd.targets.machines.enable = true; +}