]> Git — Sourcephile - julm/julm-nix.git/blob - nixos/profiles/system.nix
mmsd: push in nixpkgs#196965
[julm/julm-nix.git] / nixos / profiles / system.nix
1 { config, pkgs, lib, ... }:
2 {
3 imports = [
4 ./bash.nix
5 ];
6 documentation = {
7 enable = lib.mkDefault true;
8 dev.enable = lib.mkDefault false;
9 doc.enable = lib.mkDefault true;
10 info.enable = lib.mkDefault false;
11 man.enable = lib.mkDefault true;
12 nixos.enable = lib.mkDefault false;
13 };
14 environment.variables = {
15 EDITOR = "vim";
16 PAGER = "less -R";
17 SYSTEMD_LESS = "FKMRX";
18 };
19 home-manager.users.root = {
20 imports = [
21 ../../home-manager/options.nix
22 ../../home-manager/profiles/essential.nix
23 ];
24 };
25 systemd.services.home-manager-root.postStart = ''
26 ${pkgs.nix}/bin/nix-env --delete-generations +1 --profile /nix/var/nix/profiles/per-user/root/home-manager
27 '';
28 nix = {
29 settings.auto-optimise-store = lib.mkDefault true;
30 gc.automatic = lib.mkDefault true;
31 gc.dates = lib.mkDefault "weekly";
32 gc.options = lib.mkDefault "--delete-older-than 7d";
33 nixPath = lib.mkForce [ ];
34 };
35 security.lockKernelModules = false;
36 services.journald = {
37 extraConfig = ''
38 Compress=true
39 MaxRetentionSec=1month
40 Storage=persistent
41 SystemMaxUse=100M
42 '';
43 };
44 users.mutableUsers = false;
45 }