kasei: add arch nspawn container
This commit is contained in:
parent
b3e782d716
commit
db82ee3419
@ -11,6 +11,9 @@
|
||||
./services/tailscale.nix
|
||||
./services/keybase.nix
|
||||
|
||||
./nspawn-containers/arch.nix
|
||||
];
|
||||
|
||||
system.stateVersion = "22.05";
|
||||
|
||||
boot.binfmt.emulatedSystems = [
|
||||
|
28
hosts/kasei/nspawn-containers/arch.nix
Normal file
28
hosts/kasei/nspawn-containers/arch.nix
Normal file
@ -0,0 +1,28 @@
|
||||
{ ... }:
|
||||
{
|
||||
systemd.targets.machines.enable = true;
|
||||
|
||||
systemd.nspawn."arch" = {
|
||||
enable = true;
|
||||
execConfig.Boot = true;
|
||||
|
||||
filesConfig = {
|
||||
BindReadOnly = [
|
||||
"/nix/store"
|
||||
# "/etc/resolv.conf:/etc/resolv.conf"
|
||||
];
|
||||
Bind = [
|
||||
"/home/h7x4/git"
|
||||
"/home/h7x4/pico"
|
||||
"/home/h7x4/Downloads"
|
||||
];
|
||||
};
|
||||
networkConfig.Private = false;
|
||||
};
|
||||
|
||||
systemd.services."systemd-nspawn@arch" = {
|
||||
enable = true;
|
||||
requiredBy = [ "machines.target" ];
|
||||
overrideStrategy = "asDropin";
|
||||
};
|
||||
}
|
Loading…
Reference in New Issue
Block a user