mirror of
https://github.com/ItsDrike/nixdots
synced 2024-11-10 06:29:41 +00:00
Compare commits
5 commits
b930b14cf2
...
5580328f0a
Author | SHA1 | Date | |
---|---|---|---|
ItsDrike | 5580328f0a | ||
ItsDrike | 2dcd368572 | ||
ItsDrike | b8c6ed6ca4 | ||
ItsDrike | 9ab8cf34ac | ||
ItsDrike | 4743732cde |
|
@ -39,8 +39,8 @@
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
outputs = {self, nixpkgs, ...} @ inputs: let
|
outputs = {self, nixpkgs, ...} @ inputs: {
|
||||||
in {
|
nixosConfigurations = import ./hosts {inherit inputs;};
|
||||||
nixosConfigurations = import ./hosts {inherit nixpkgs inputs self;};
|
devShells = import ./shells {inherit inputs;};
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,5 +1,6 @@
|
||||||
{ self, inputs, ... }:
|
{ inputs, ... }:
|
||||||
let
|
let
|
||||||
|
inherit (inputs) self;
|
||||||
inherit (inputs.nixpkgs) lib;
|
inherit (inputs.nixpkgs) lib;
|
||||||
|
|
||||||
# A list of shared modules that ALL systems need
|
# A list of shared modules that ALL systems need
|
||||||
|
@ -10,17 +11,6 @@ let
|
||||||
];
|
];
|
||||||
in
|
in
|
||||||
{
|
{
|
||||||
vboxnix = lib.nixosSystem {
|
|
||||||
system = "x86_64-linux";
|
|
||||||
specialArgs = { inherit lib inputs self; };
|
|
||||||
modules = [
|
|
||||||
./vbox_nix
|
|
||||||
inputs.home-manager.nixosModules.home-manager
|
|
||||||
inputs.impermanence.nixosModules.impermanence
|
|
||||||
inputs.lanzaboote.nixosModules.lanzaboote
|
|
||||||
] ++ shared;
|
|
||||||
};
|
|
||||||
|
|
||||||
herugrim = lib.nixosSystem {
|
herugrim = lib.nixosSystem {
|
||||||
system = "x86_64-linux";
|
system = "x86_64-linux";
|
||||||
specialArgs = { inherit lib inputs self; };
|
specialArgs = { inherit lib inputs self; };
|
||||||
|
|
21
shells/default.nix
Normal file
21
shells/default.nix
Normal file
|
@ -0,0 +1,21 @@
|
||||||
|
{inputs, ...}: let
|
||||||
|
inherit (inputs) nixpkgs;
|
||||||
|
|
||||||
|
system = "x86_64-linux";
|
||||||
|
pkgs = nixpkgs.legacyPackages.${system};
|
||||||
|
in {
|
||||||
|
${system} = {
|
||||||
|
default = pkgs.mkShell {
|
||||||
|
name = "nixdots";
|
||||||
|
meta.description = "The default development shell for my NixOS configuration";
|
||||||
|
packages = with pkgs; [
|
||||||
|
git # flakes require git
|
||||||
|
nil # nix ls
|
||||||
|
statix # lints and suggestions
|
||||||
|
deadnix # clean up unused nix code
|
||||||
|
alejandra # nix formatter
|
||||||
|
];
|
||||||
|
shellHook = "exec $SHELL";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
|
@ -11,6 +11,9 @@
|
||||||
deviceType = config.myOptions.device.roles.type;
|
deviceType = config.myOptions.device.roles.type;
|
||||||
acceptedTypes = ["laptop" "desktop"];
|
acceptedTypes = ["laptop" "desktop"];
|
||||||
|
|
||||||
|
greetingMsg = "'Access is restricted to authorized personnel only.'";
|
||||||
|
tuiGreetTheme = "'border=magenta;text=cyan;prompt=green;time=red;action=white;button=yellow;container=black;input=gray'";
|
||||||
|
|
||||||
sessionData = config.services.displayManager.sessionData.desktops;
|
sessionData = config.services.displayManager.sessionData.desktops;
|
||||||
sessionPaths = concatStringsSep ":" [
|
sessionPaths = concatStringsSep ":" [
|
||||||
"${sessionData}/share/xsessions"
|
"${sessionData}/share/xsessions"
|
||||||
|
@ -25,14 +28,16 @@
|
||||||
"--remember"
|
"--remember"
|
||||||
"--remember-user-session"
|
"--remember-user-session"
|
||||||
"--asterisks"
|
"--asterisks"
|
||||||
|
"--greeting ${greetingMsg}"
|
||||||
"--sessions '${sessionPaths}'"
|
"--sessions '${sessionPaths}'"
|
||||||
|
"--theme ${tuiGreetTheme}"
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
in {
|
in {
|
||||||
config = mkIf (builtins.elem deviceType acceptedTypes) {
|
config = mkIf (builtins.elem deviceType acceptedTypes) {
|
||||||
services.greetd = {
|
services.greetd = {
|
||||||
enable = true;
|
enable = true;
|
||||||
vt = 2;
|
vt = 1;
|
||||||
|
|
||||||
# <https://man.sr.ht/~kennylevinsen/greetd/>
|
# <https://man.sr.ht/~kennylevinsen/greetd/>
|
||||||
settings = {
|
settings = {
|
||||||
|
@ -54,5 +59,8 @@ in {
|
||||||
TTYVHangup = true;
|
TTYVHangup = true;
|
||||||
TTYVTDisallocate = true;
|
TTYVTDisallocate = true;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
# Persist info about previous session & user
|
||||||
|
myOptions.system.impermanence.root.extraDirectories = [ "/var/cache/tuigreet" ];
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue