users: create on entering nix-shell
This commit is contained in:
parent
c608b60700
commit
5b5d072851
3 changed files with 66 additions and 2 deletions
|
@ -107,7 +107,7 @@ In addition, profiles can depend on other profiles. For example, The
|
||||||
simply by importing it in its [`default.nix`](profiles/graphical/default.nix).
|
simply by importing it in its [`default.nix`](profiles/graphical/default.nix).
|
||||||
|
|
||||||
## Users
|
## Users
|
||||||
User declaration belongs in the [users](users) directory. Everything related to
|
User declaration belongs in the `users` directory. Everything related to
|
||||||
your user should be declared here. For convenience, [home-manager][home-manager]
|
your user should be declared here. For convenience, [home-manager][home-manager]
|
||||||
is available automatically for home directory setup.
|
is available automatically for home directory setup.
|
||||||
|
|
||||||
|
@ -121,7 +121,7 @@ if your not familiar. The filter is already set up to encrypt everything in this
|
||||||
folder by default.
|
folder by default.
|
||||||
|
|
||||||
To keep [profiles](profiles) resuable across configurations, secrets should
|
To keep [profiles](profiles) resuable across configurations, secrets should
|
||||||
only be imported from the [users](users) directory.
|
only be imported from the `users` directory.
|
||||||
|
|
||||||
## Modules and Packages
|
## Modules and Packages
|
||||||
All [modules](modules/default.nix) and [pkgs](pkgs/default.nix) are available
|
All [modules](modules/default.nix) and [pkgs](pkgs/default.nix) are available
|
||||||
|
|
63
hosts/hp500281.nix
Normal file
63
hosts/hp500281.nix
Normal file
|
@ -0,0 +1,63 @@
|
||||||
|
{ lib, pkgs, ... }:
|
||||||
|
let
|
||||||
|
inherit (builtins) readFile;
|
||||||
|
in
|
||||||
|
{
|
||||||
|
imports = [
|
||||||
|
../profiles/games
|
||||||
|
../profiles/misc
|
||||||
|
../profiles/misc/plex.nix
|
||||||
|
../profiles/misc/torrent.nix
|
||||||
|
../users/nrd
|
||||||
|
];
|
||||||
|
|
||||||
|
fileSystems."/" = {
|
||||||
|
device = "/dev/disk/by-uuid/5c0bf17c-6df1-4618-88f8-48a4249adb30";
|
||||||
|
fsType = "xfs";
|
||||||
|
};
|
||||||
|
|
||||||
|
fileSystems."/boot" = {
|
||||||
|
device = "/dev/disk/by-uuid/B361-1241";
|
||||||
|
fsType = "vfat";
|
||||||
|
};
|
||||||
|
|
||||||
|
fileSystems."/srv" = {
|
||||||
|
device = "/dev/disk/by-uuid/2a21bc0b-f30a-4001-8976-f39adf805daa";
|
||||||
|
fsType = "xfs";
|
||||||
|
};
|
||||||
|
|
||||||
|
boot.initrd.availableKernelModules = [
|
||||||
|
"xhci_pci"
|
||||||
|
"ehci_pci"
|
||||||
|
"ahci"
|
||||||
|
"usbhid"
|
||||||
|
"sd_mod"
|
||||||
|
];
|
||||||
|
|
||||||
|
boot.kernelModules = [ "kvm-intel" ];
|
||||||
|
|
||||||
|
environment.sessionVariables = {
|
||||||
|
LIBVA_DRIVER_NAME = "iHD";
|
||||||
|
};
|
||||||
|
|
||||||
|
hardware.cpu.intel.updateMicrocode = true;
|
||||||
|
|
||||||
|
hardware.opengl.extraPackages = with pkgs; [
|
||||||
|
vaapiIntel
|
||||||
|
vaapiVdpau
|
||||||
|
libvdpau-va-gl
|
||||||
|
intel-media-driver
|
||||||
|
];
|
||||||
|
|
||||||
|
networking.networkmanager = {
|
||||||
|
enable = true;
|
||||||
|
};
|
||||||
|
|
||||||
|
nix.maxJobs = lib.mkDefault 4;
|
||||||
|
nix.systemFeatures = [ "gccarch-haswell" ];
|
||||||
|
|
||||||
|
boot.loader.systemd-boot = {
|
||||||
|
enable = true;
|
||||||
|
editor = false;
|
||||||
|
};
|
||||||
|
}
|
|
@ -26,6 +26,7 @@ pkgs.mkShell {
|
||||||
|
|
||||||
shellHook = ''
|
shellHook = ''
|
||||||
mkdir -p secrets
|
mkdir -p secrets
|
||||||
|
mkdir -p users
|
||||||
'';
|
'';
|
||||||
|
|
||||||
NIX_CONF_DIR = let
|
NIX_CONF_DIR = let
|
||||||
|
|
Loading…
Reference in a new issue