Ran formatter
This commit is contained in:
parent
a43299c358
commit
c364015d08
|
@ -1,14 +1,17 @@
|
||||||
# Edit this configuration file to define what should be installed on
|
# Edit this configuration file to define what should be installed on
|
||||||
# your system. Help is available in the configuration.nix(5) man page
|
# your system. Help is available in the configuration.nix(5) man page
|
||||||
# and in the NixOS manual (accessible by running ‘nixos-help’).
|
# and in the NixOS manual (accessible by running ‘nixos-help’).
|
||||||
|
|
||||||
{ config, pkgs, ... }:
|
|
||||||
|
|
||||||
{
|
{
|
||||||
imports =
|
config,
|
||||||
[ # Include the results of the hardware scan.
|
pkgs,
|
||||||
./hardware-configuration.nix ./zfs.nix ./vpn.nix
|
...
|
||||||
];
|
}: {
|
||||||
|
imports = [
|
||||||
|
# Include the results of the hardware scan.
|
||||||
|
./hardware-configuration.nix
|
||||||
|
./zfs.nix
|
||||||
|
./vpn.nix
|
||||||
|
];
|
||||||
|
|
||||||
hardware.opengl = {
|
hardware.opengl = {
|
||||||
enable = true;
|
enable = true;
|
||||||
|
@ -16,7 +19,7 @@
|
||||||
driSupport32Bit = true;
|
driSupport32Bit = true;
|
||||||
};
|
};
|
||||||
|
|
||||||
nixpkgs.config.allowUnfree = true;
|
nixpkgs.config.allowUnfree = true;
|
||||||
|
|
||||||
# Make ready for nix flakes
|
# Make ready for nix flakes
|
||||||
nix.package = pkgs.nixFlakes;
|
nix.package = pkgs.nixFlakes;
|
||||||
|
@ -46,9 +49,6 @@
|
||||||
|
|
||||||
# Enable the X11 windowing system.
|
# Enable the X11 windowing system.
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
# Configure keymap in X11
|
# Configure keymap in X11
|
||||||
# "eurosign:e";
|
# "eurosign:e";
|
||||||
# "caps:escape" # map caps to escape.
|
# "caps:escape" # map caps to escape.
|
||||||
|
@ -73,7 +73,7 @@
|
||||||
programs.sway = {
|
programs.sway = {
|
||||||
enable = true;
|
enable = true;
|
||||||
wrapperFeatures.gtk = true; # so that gtk works properly
|
wrapperFeatures.gtk = true; # so that gtk works properly
|
||||||
extraPackages = with pkgs; [ swaylock ];
|
extraPackages = with pkgs; [swaylock];
|
||||||
};
|
};
|
||||||
|
|
||||||
programs.steam = {
|
programs.steam = {
|
||||||
|
@ -109,7 +109,11 @@
|
||||||
# List services that you want to enable:
|
# List services that you want to enable:
|
||||||
|
|
||||||
# Enable the OpenSSH daemon.
|
# Enable the OpenSSH daemon.
|
||||||
services.openssh.enable = true;
|
services.openssh = {
|
||||||
|
enable = true;
|
||||||
|
passwordAuthentication = false;
|
||||||
|
permitRootLogin = "no";
|
||||||
|
};
|
||||||
|
|
||||||
security.rtkit.enable = true;
|
security.rtkit.enable = true;
|
||||||
services.pipewire = {
|
services.pipewire = {
|
||||||
|
@ -137,6 +141,4 @@
|
||||||
# Before changing this value read the documentation for this option
|
# Before changing this value read the documentation for this option
|
||||||
# (e.g. man configuration.nix or on https://nixos.org/nixos/options.html).
|
# (e.g. man configuration.nix or on https://nixos.org/nixos/options.html).
|
||||||
system.stateVersion = "22.05"; # Did you read the comment?
|
system.stateVersion = "22.05"; # Did you read the comment?
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -1,55 +1,64 @@
|
||||||
# Do not modify this file! It was generated by ‘nixos-generate-config’
|
# Do not modify this file! It was generated by ‘nixos-generate-config’
|
||||||
# and may be overwritten by future invocations. Please make changes
|
# and may be overwritten by future invocations. Please make changes
|
||||||
# to /etc/nixos/configuration.nix instead.
|
# to /etc/nixos/configuration.nix instead.
|
||||||
{ config, lib, pkgs, modulesPath, ... }:
|
|
||||||
|
|
||||||
{
|
{
|
||||||
imports =
|
config,
|
||||||
[ (modulesPath + "/installer/scan/not-detected.nix")
|
lib,
|
||||||
];
|
pkgs,
|
||||||
|
modulesPath,
|
||||||
|
...
|
||||||
|
}: {
|
||||||
|
imports = [
|
||||||
|
(modulesPath + "/installer/scan/not-detected.nix")
|
||||||
|
];
|
||||||
|
|
||||||
boot.initrd.availableKernelModules = [ "xhci_pci" "ahci" "nvme" "usbhid" "usb_storage" "sd_mod" ];
|
boot.initrd.availableKernelModules = ["xhci_pci" "ahci" "nvme" "usbhid" "usb_storage" "sd_mod"];
|
||||||
boot.initrd.kernelModules = [ ];
|
boot.initrd.kernelModules = [];
|
||||||
boot.kernelModules = [ "kvm-intel" ];
|
boot.kernelModules = ["kvm-intel"];
|
||||||
boot.extraModulePackages = [ ];
|
boot.extraModulePackages = [];
|
||||||
|
|
||||||
fileSystems."/" =
|
fileSystems."/" = {
|
||||||
{ device = "rpool/nixos/root";
|
device = "rpool/nixos/root";
|
||||||
fsType = "zfs"; options = [ "zfsutil" "X-mount.mkdir" ];
|
fsType = "zfs";
|
||||||
};
|
options = ["zfsutil" "X-mount.mkdir"];
|
||||||
|
};
|
||||||
|
|
||||||
fileSystems."/home" =
|
fileSystems."/home" = {
|
||||||
{ device = "rpool/nixos/home";
|
device = "rpool/nixos/home";
|
||||||
fsType = "zfs"; options = [ "zfsutil" "X-mount.mkdir" ];
|
fsType = "zfs";
|
||||||
};
|
options = ["zfsutil" "X-mount.mkdir"];
|
||||||
|
};
|
||||||
|
|
||||||
fileSystems."/var/lib" =
|
fileSystems."/var/lib" = {
|
||||||
{ device = "rpool/nixos/var/lib";
|
device = "rpool/nixos/var/lib";
|
||||||
fsType = "zfs"; options = [ "zfsutil" "X-mount.mkdir" ];
|
fsType = "zfs";
|
||||||
};
|
options = ["zfsutil" "X-mount.mkdir"];
|
||||||
|
};
|
||||||
|
|
||||||
fileSystems."/var/log" =
|
fileSystems."/var/log" = {
|
||||||
{ device = "rpool/nixos/var/log";
|
device = "rpool/nixos/var/log";
|
||||||
fsType = "zfs"; options = [ "zfsutil" "X-mount.mkdir" ];
|
fsType = "zfs";
|
||||||
};
|
options = ["zfsutil" "X-mount.mkdir"];
|
||||||
|
};
|
||||||
|
|
||||||
fileSystems."/boot" =
|
fileSystems."/boot" = {
|
||||||
{ device = "bpool/nixos/root";
|
device = "bpool/nixos/root";
|
||||||
fsType = "zfs"; options = [ "zfsutil" "X-mount.mkdir" ];
|
fsType = "zfs";
|
||||||
};
|
options = ["zfsutil" "X-mount.mkdir"];
|
||||||
|
};
|
||||||
|
|
||||||
fileSystems."/boot/efis/nvme-WDC_WDS100T2B0C-00PXH0_21111Y801086-part1" =
|
fileSystems."/boot/efis/nvme-WDC_WDS100T2B0C-00PXH0_21111Y801086-part1" = {
|
||||||
{ device = "/dev/disk/by-uuid/1443-371C";
|
device = "/dev/disk/by-uuid/1443-371C";
|
||||||
fsType = "vfat";
|
fsType = "vfat";
|
||||||
};
|
};
|
||||||
|
|
||||||
fileSystems."/boot/efi" =
|
fileSystems."/boot/efi" = {
|
||||||
{ device = "/boot/efis/nvme-WDC_WDS100T2B0C-00PXH0_21111Y801086-part1";
|
device = "/boot/efis/nvme-WDC_WDS100T2B0C-00PXH0_21111Y801086-part1";
|
||||||
fsType = "none";
|
fsType = "none";
|
||||||
options = [ "bind" ];
|
options = ["bind"];
|
||||||
};
|
};
|
||||||
|
|
||||||
swapDevices = [ ];
|
swapDevices = [];
|
||||||
|
|
||||||
# Enables DHCP on each ethernet and wireless interface. In case of scripted networking
|
# Enables DHCP on each ethernet and wireless interface. In case of scripted networking
|
||||||
# (the default) this is the recommended approach. When using systemd-networkd it's
|
# (the default) this is the recommended approach. When using systemd-networkd it's
|
||||||
|
|
|
@ -1,34 +1,37 @@
|
||||||
{ config, pkgs, ... }:
|
{
|
||||||
|
config,
|
||||||
{ boot.supportedFilesystems = [ "zfs" ];
|
pkgs,
|
||||||
|
...
|
||||||
|
}: {
|
||||||
|
boot.supportedFilesystems = ["zfs"];
|
||||||
networking.hostId = "f8616592";
|
networking.hostId = "f8616592";
|
||||||
boot.kernelPackages = config.boot.zfs.package.latestCompatibleLinuxPackages;
|
boot.kernelPackages = config.boot.zfs.package.latestCompatibleLinuxPackages;
|
||||||
boot.loader.efi.efiSysMountPoint = "/boot/efi";
|
boot.loader.efi.efiSysMountPoint = "/boot/efi";
|
||||||
boot.loader.efi.canTouchEfiVariables = false;
|
boot.loader.efi.canTouchEfiVariables = false;
|
||||||
boot.loader.generationsDir.copyKernels = true;
|
boot.loader.generationsDir.copyKernels = true;
|
||||||
boot.loader.grub.efiInstallAsRemovable = true;
|
boot.loader.grub.efiInstallAsRemovable = true;
|
||||||
boot.loader.grub.enable = true;
|
boot.loader.grub.enable = true;
|
||||||
boot.loader.grub.version = 2;
|
boot.loader.grub.version = 2;
|
||||||
boot.loader.grub.copyKernels = true;
|
boot.loader.grub.copyKernels = true;
|
||||||
boot.loader.grub.efiSupport = true;
|
boot.loader.grub.efiSupport = true;
|
||||||
boot.loader.grub.zfsSupport = true;
|
boot.loader.grub.zfsSupport = true;
|
||||||
boot.loader.grub.extraPrepareConfig = ''
|
boot.loader.grub.extraPrepareConfig = ''
|
||||||
mkdir -p /boot/efis
|
mkdir -p /boot/efis
|
||||||
for i in /boot/efis/*; do mount $i ; done
|
for i in /boot/efis/*; do mount $i ; done
|
||||||
|
|
||||||
mkdir -p /boot/efi
|
mkdir -p /boot/efi
|
||||||
mount /boot/efi
|
mount /boot/efi
|
||||||
'';
|
'';
|
||||||
boot.loader.grub.extraInstallCommands = ''
|
boot.loader.grub.extraInstallCommands = ''
|
||||||
ESP_MIRROR=$(mktemp -d)
|
ESP_MIRROR=$(mktemp -d)
|
||||||
cp -r /boot/efi/EFI $ESP_MIRROR
|
cp -r /boot/efi/EFI $ESP_MIRROR
|
||||||
for i in /boot/efis/*; do
|
for i in /boot/efis/*; do
|
||||||
cp -r $ESP_MIRROR/EFI $i
|
cp -r $ESP_MIRROR/EFI $i
|
||||||
done
|
done
|
||||||
rm -rf $ESP_MIRROR
|
rm -rf $ESP_MIRROR
|
||||||
'';
|
'';
|
||||||
boot.loader.grub.devices = [
|
boot.loader.grub.devices = [
|
||||||
"/dev/disk/by-id/nvme-WDC_WDS100T2B0C-00PXH0_21111Y801086"
|
"/dev/disk/by-id/nvme-WDC_WDS100T2B0C-00PXH0_21111Y801086"
|
||||||
];
|
];
|
||||||
users.users.root.initialHashedPassword = "$6$3Ps2Vmff.gUBkiCv$FCeCQjDvNTdWynQU81qtCXFHQht86w4unWNalUgkcyq7lkkI2klzRyTK3dZiQUjIrn8qPKtwJcY9SNdyE8v1L/";
|
users.users.root.initialHashedPassword = "$6$3Ps2Vmff.gUBkiCv$FCeCQjDvNTdWynQU81qtCXFHQht86w4unWNalUgkcyq7lkkI2klzRyTK3dZiQUjIrn8qPKtwJcY9SNdyE8v1L/";
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue