summary refs log tree commit diff stats
path: root/modules
diff options
context:
space:
mode:
authorSilas Schöffel <sils@sils.li>2024-04-19 20:34:23 +0200
committerSilas Schöffel <sils@sils.li>2024-04-19 20:34:23 +0200
commit0c11c9fbf6f577f0e23dc09ec383c44431b516fa (patch)
tree7ec50c04bb1094d1d7c2ef046c6da69146eb725a /modules
parentflake.lock: update (diff)
downloadnix-config-0c11c9fbf6f577f0e23dc09ec383c44431b516fa.tar.gz
nix-config-0c11c9fbf6f577f0e23dc09ec383c44431b516fa.zip
modules: introduce role system
Diffstat (limited to 'modules')
-rw-r--r--modules/nixos/default.nix1
-rw-r--r--modules/nixos/roles.nix7
2 files changed, 8 insertions, 0 deletions
diff --git a/modules/nixos/default.nix b/modules/nixos/default.nix
index 2d05002..fae14fc 100644
--- a/modules/nixos/default.nix
+++ b/modules/nixos/default.nix
@@ -1,5 +1,6 @@
 {...}: {
   imports = [
+    ./roles.nix
     ./sils
   ];
 }
diff --git a/modules/nixos/roles.nix b/modules/nixos/roles.nix
new file mode 100644
index 0000000..71883e0
--- /dev/null
+++ b/modules/nixos/roles.nix
@@ -0,0 +1,7 @@
+{lib, ...}: {
+  options.role.sils = lib.mkOption {
+    type = lib.types.nullOr (lib.types.enum ["laptop" "undefined" "vm"]);
+    default = null;
+    description = "The role which should be applied to your configuration.";
+  };
+}