commit 9fcf2f77cd77b9b9c820055184c9ae009dfcab72
parent cda9428fd6dc4f472f27923cc2b8231f687147c2
Author: Vincent Demeester <vincent@sbr.pm>
Date: Fri, 11 Dec 2020 17:28:50 +0100
systems: revert to normal nix…
… let's experiment with `nixFlake` on a VM to start with
Signed-off-by: Vincent Demeester <vincent@sbr.pm>
Diffstat:
8 files changed, 34 insertions(+), 3 deletions(-)
diff --git a/flake.nix b/flake.nix
@@ -130,7 +130,7 @@
})
# FIXME remove flake suffix once migrated
(import ./systems/modules/default.flake.nix)
- # (import ./systems/profiles)
+ (import ./systems/profiles)
(import config)
];
specialArgs = { inherit name inputs; };
diff --git a/systems/hosts/naruhodo.flake.nix b/systems/hosts/naruhodo.flake.nix
@@ -13,12 +13,14 @@ let
endpointPublicKey = strings.optionalString secretCondition (import secretPath).wireguard.kerkouane.publicKey;
in
{
+ /*
imports = [
../hardware/thinkpad-t480s.nix
../modules
(import ../../users).vincent
(import ../../users).root
];
+ */
fileSystems."/" =
{
diff --git a/systems/modules/core/nix.nix b/systems/modules/core/nix.nix
@@ -57,7 +57,7 @@ in
daemonIONiceLevel = 5;
daemonNiceLevel = 10;
# if hydra is down, don't wait forever
- package = pkgs.nixFlakes;
+ # package = pkgs.nixFlakes;
extraOptions = ''
connect-timeout = 20
build-cores = 0
@@ -86,6 +86,9 @@ in
useSandbox = true;
};
+ # `nix-daemon` will hit the stack limit when using `nixFlakes`.
+ systemd.services.nix-daemon.serviceConfig."LimitSTACK" = "infinity";
+
nixpkgs = {
overlays = [
(import ../../../overlays/mkSecret.nix)
diff --git a/systems/modules/profiles/default.nix b/systems/modules/profiles/default.nix
@@ -1,6 +1,5 @@
{
imports = [
- # Remove "nixos" from here
./avahi.nix
./base.nix
./desktop.nix
diff --git a/systems/profiles/base.nix b/systems/profiles/base.nix
@@ -0,0 +1,15 @@
+{ config, lib, pkgs, ... }:
+let
+ inherit (lib) mkEnableOption;
+ cfg = config.profiles.base;
+in
+{
+ options = {
+ enable = mkEnableOption "base configuration";
+ };
+ config = {
+
+ # `nix-daemon` will hit the stack limit when using `nixFlakes`.
+ systemd.services.nix-daemon.serviceConfig."LimitSTACK" = "infinity";
+ };
+}
diff --git a/systems/profiles/default.nix b/systems/profiles/default.nix
@@ -0,0 +1,12 @@
+{ lib, ... }:
+
+{
+ imports = [
+ ./base.nix
+ ./desktop.nix
+ ./development.nix
+ # FIXME: vpn, server, builder, …
+ ];
+
+ config.profiles.base.enable = lib.mkDefault true;
+}
diff --git a/systems/profiles/desktop.nix b/systems/profiles/desktop.nix
diff --git a/systems/profiles/development.nix b/systems/profiles/development.nix