test
This commit is contained in:
parent
9727dea6c7
commit
245fe5bee8
5 changed files with 39 additions and 34 deletions
|
@ -14,14 +14,14 @@
|
||||||
nur.url = "github:nix-community/NUR";
|
nur.url = "github:nix-community/NUR";
|
||||||
# sops-nix - Secret Management with SOPS using GPG Keys
|
# sops-nix - Secret Management with SOPS using GPG Keys
|
||||||
sops-nix.url = "github:Mic92/sops-nix";
|
sops-nix.url = "github:Mic92/sops-nix";
|
||||||
# doom-emacs - The Doom Emacs distribution
|
# doom-emacs - The Doom Emacs distribution`
|
||||||
doom-emacs.url = "github:nix-community/nix-doom-emacs";
|
doom-emacs.url = "github:nix-community/nix-doom-emacs";
|
||||||
# nixos-hardware - Hardware Configurations
|
# nixos-hardware - Hardware Configurations
|
||||||
nixos-hardware.url = "github:NixOS/nixos-hardware/master";
|
nixos-hardware.url = "github:NixOS/nixos-hardware/master";
|
||||||
# nixos-generators - Automated Image / ISO Creation
|
# nixos-generators - Automated Image / ISO Creation
|
||||||
nixos-generators.url = "github:nix-community/nixos-generators";
|
nixos-generators.url = "github:nix-community/nixos-generators";
|
||||||
nixos-generators.inputs.nixpkgs.follows = "nixpkgs";
|
nixos-generators.inputs.nixpkgs.follows = "nixpkgs";
|
||||||
# disko - Automated Disk Partitioning
|
# disko - Declarative Disk Partitioning
|
||||||
disko.url = "github:nix-community/disko";
|
disko.url = "github:nix-community/disko";
|
||||||
disko.inputs.nixpkgs.follows = "nixpkgs";
|
disko.inputs.nixpkgs.follows = "nixpkgs";
|
||||||
};
|
};
|
||||||
|
|
|
@ -1,14 +1,12 @@
|
||||||
{ config, pkgs, ... }: {
|
{ config, pkgs, desktop, ... }: {
|
||||||
|
|
||||||
|
# IF we're booting into a GUI, load in pretty things
|
||||||
|
imports = [ ] ++ lib.optional (builtins.isString desktop) ./plymouth.nix;
|
||||||
|
|
||||||
# Bootloader
|
# Bootloader
|
||||||
boot.loader.efi.canTouchEfiVariables = true;
|
boot.loader.efi.canTouchEfiVariables = true;
|
||||||
boot.loader.systemd-boot.enable = true;
|
boot.loader.systemd-boot.enable = true;
|
||||||
boot.tmp.cleanOnBoot = true;
|
boot.tmp.cleanOnBoot = true;
|
||||||
boot.initrd.systemd.enable = true;
|
boot.initrd.systemd.enable = true;
|
||||||
boot.kernelParams = ["quiet"];
|
boot.kernelParams = ["quiet"];
|
||||||
|
}
|
||||||
# Plymouth splash screen
|
|
||||||
boot.plymouth.enable = true;
|
|
||||||
# https://github.com/adi1090x/plymouth-themes
|
|
||||||
boot.plymouth.theme = "red_loader";
|
|
||||||
boot.plymouth.themePackages = [ pkgs.adi1090x-plymouth-themes ];
|
|
||||||
}
|
|
7
nixos/common/modules/plymouth.nix
Normal file
7
nixos/common/modules/plymouth.nix
Normal file
|
@ -0,0 +1,7 @@
|
||||||
|
{ pkgs, config, ... }: {
|
||||||
|
# Plymouth splash screen
|
||||||
|
boot.plymouth.enable = true;
|
||||||
|
# https://github.com/adi1090x/plymouth-themes
|
||||||
|
boot.plymouth.theme = "red_loader";
|
||||||
|
boot.plymouth.themePackages = [ pkgs.adi1090x-plymouth-themes ];
|
||||||
|
}
|
|
@ -1,8 +1,6 @@
|
||||||
{
|
{
|
||||||
boot.loader.grub.device = "/dev/sda";
|
boot.loader.grub.device = "/dev/sda";
|
||||||
boot.initrd.luks.devices."sda2".device = "/dev/sda2";
|
boot.initrd.luks.devices."sda2".device = "/dev/sda2";
|
||||||
services.btrfs.autoScrub.enable = true;
|
|
||||||
services.btrfs.autoScrub.interval = "weekly";
|
|
||||||
|
|
||||||
disko.devices.disk.sda = {
|
disko.devices.disk.sda = {
|
||||||
device = "/dev/sda";
|
device = "/dev/sda";
|
||||||
|
@ -29,27 +27,11 @@
|
||||||
end = "100%";
|
end = "100%";
|
||||||
content = {
|
content = {
|
||||||
type = "luks";
|
type = "luks";
|
||||||
name = "LUKS-ROOT";
|
name = "ROOT";
|
||||||
extraOpenArgs = [ "--allow-discards" ];
|
|
||||||
settings.keyFile = "/tmp/secret.key";
|
|
||||||
content = {
|
content = {
|
||||||
type = "filesystem";
|
type = "filesystem";
|
||||||
format = "btrfs";
|
format = "ext4";
|
||||||
# extraArgs = [ "-f" ];
|
mountpoint = "/";
|
||||||
subvolumes = {
|
|
||||||
"/root" = {
|
|
||||||
mountpoint = "/";
|
|
||||||
mountOptions = [ "compress=zstd" "noatime" ];
|
|
||||||
}; # root
|
|
||||||
"/home" = {
|
|
||||||
mountpoint = "/home";
|
|
||||||
mountOptions = [ "compress=zstd" "noatime" ];
|
|
||||||
}; # home
|
|
||||||
"/nix" = {
|
|
||||||
mountpoint = "/nix";
|
|
||||||
mountOptions = [ "compress=zstd" "noatime" ];
|
|
||||||
}; # nix
|
|
||||||
}; # subvolumes
|
|
||||||
}; # content.content
|
}; # content.content
|
||||||
}; # content
|
}; # content
|
||||||
} # partition 2
|
} # partition 2
|
|
@ -1,6 +1,8 @@
|
||||||
{
|
{
|
||||||
boot.loader.grub.device = "/dev/sda";
|
boot.loader.grub.device = "/dev/sda";
|
||||||
boot.initrd.luks.devices."sda2".device = "/dev/sda2";
|
boot.initrd.luks.devices."sda2".device = "/dev/sda2";
|
||||||
|
services.btrfs.autoScrub.enable = true;
|
||||||
|
services.btrfs.autoScrub.interval = "weekly";
|
||||||
|
|
||||||
disko.devices.disk.sda = {
|
disko.devices.disk.sda = {
|
||||||
device = "/dev/sda";
|
device = "/dev/sda";
|
||||||
|
@ -27,11 +29,27 @@
|
||||||
end = "100%";
|
end = "100%";
|
||||||
content = {
|
content = {
|
||||||
type = "luks";
|
type = "luks";
|
||||||
name = "ROOT";
|
name = "LUKS-ROOT";
|
||||||
|
extraOpenArgs = [ "--allow-discards" ];
|
||||||
|
settings.keyFile = "/tmp/secret.key";
|
||||||
content = {
|
content = {
|
||||||
type = "filesystem";
|
type = "filesystem";
|
||||||
format = "ext4";
|
format = "btrfs";
|
||||||
mountpoint = "/";
|
# extraArgs = [ "-f" ];
|
||||||
|
subvolumes = {
|
||||||
|
"/root" = {
|
||||||
|
mountpoint = "/";
|
||||||
|
mountOptions = [ "compress=zstd" "noatime" ];
|
||||||
|
}; # root
|
||||||
|
"/home" = {
|
||||||
|
mountpoint = "/home";
|
||||||
|
mountOptions = [ "compress=zstd" "noatime" ];
|
||||||
|
}; # home
|
||||||
|
"/nix" = {
|
||||||
|
mountpoint = "/nix";
|
||||||
|
mountOptions = [ "compress=zstd" "noatime" ];
|
||||||
|
}; # nix
|
||||||
|
}; # subvolumes
|
||||||
}; # content.content
|
}; # content.content
|
||||||
}; # content
|
}; # content
|
||||||
} # partition 2
|
} # partition 2
|
||||||
|
|
Loading…
Reference in a new issue