about summary refs log tree commit diff
path: root/nixpkgs/nixos/modules/system/boot/systemd.nix
diff options
context:
space:
mode:
authorAlyssa Ross <hi@alyssa.is>2020-04-16 10:49:57 +0000
committerAlyssa Ross <hi@alyssa.is>2020-04-16 11:36:19 +0000
commit2b2852d22ea9b46f994d5b7b037da10dee67d9ae (patch)
treebd5606247a86595ca6f367390f04fa45214fa1f0 /nixpkgs/nixos/modules/system/boot/systemd.nix
parent3f2f1894a2e9b1135133344fe333199cc0701226 (diff)
downloadnixlib-2b2852d22ea9b46f994d5b7b037da10dee67d9ae.tar
nixlib-2b2852d22ea9b46f994d5b7b037da10dee67d9ae.tar.gz
nixlib-2b2852d22ea9b46f994d5b7b037da10dee67d9ae.tar.bz2
nixlib-2b2852d22ea9b46f994d5b7b037da10dee67d9ae.tar.lz
nixlib-2b2852d22ea9b46f994d5b7b037da10dee67d9ae.tar.xz
nixlib-2b2852d22ea9b46f994d5b7b037da10dee67d9ae.tar.zst
nixlib-2b2852d22ea9b46f994d5b7b037da10dee67d9ae.zip
modules/systemd: don't install home.conf example
We don't want /srv on NixOS, and /home is already created by
users-groups.nix.

Furthermore, systemd tmpfiles are set up post-activation, and so
there's absolutely no way for a user to override them.  They can't
even set their own rules in systemd.tmpfiles, because "home.conf"
comes before "nixos.conf" lexicographically, and so systemd always
picks the "home.conf" ones.
Diffstat (limited to 'nixpkgs/nixos/modules/system/boot/systemd.nix')
-rw-r--r--nixpkgs/nixos/modules/system/boot/systemd.nix5
1 files changed, 4 insertions, 1 deletions
diff --git a/nixpkgs/nixos/modules/system/boot/systemd.nix b/nixpkgs/nixos/modules/system/boot/systemd.nix
index cdc9d2379392..c62f0dd225d2 100644
--- a/nixpkgs/nixos/modules/system/boot/systemd.nix
+++ b/nixpkgs/nixos/modules/system/boot/systemd.nix
@@ -895,7 +895,10 @@ in
       "sysctl.d/50-coredump.conf".source = "${systemd}/example/sysctl.d/50-coredump.conf";
       "sysctl.d/50-default.conf".source = "${systemd}/example/sysctl.d/50-default.conf";
 
-      "tmpfiles.d/home.conf".source = "${systemd}/example/tmpfiles.d/home.conf";
+      # home.conf creates /srv (which we don't want), and /home, which
+      # is handled by NixOS anyway.
+      # "tmpfiles.d/home.conf".source = "${systemd}/example/tmpfiles.d/home.conf";
+
       "tmpfiles.d/journal-nocow.conf".source = "${systemd}/example/tmpfiles.d/journal-nocow.conf";
       "tmpfiles.d/portables.conf".source = "${systemd}/example/tmpfiles.d/portables.conf";
       "tmpfiles.d/static-nodes-permissions.conf".source = "${systemd}/example/tmpfiles.d/static-nodes-permissions.conf";