Setup nix on new SSD
This commit is contained in:
parent
90a6060978
commit
8c800ed66e
@ -4,7 +4,8 @@
|
|||||||
|
|
||||||
{ config, pkgs, ... }:
|
{ config, pkgs, ... }:
|
||||||
|
|
||||||
{
|
let python-packages = ps: with ps; [ ];
|
||||||
|
in rec {
|
||||||
imports = [ # Include the results of the hardware scan.
|
imports = [ # Include the results of the hardware scan.
|
||||||
./hardware-configuration.nix
|
./hardware-configuration.nix
|
||||||
];
|
];
|
||||||
@ -131,7 +132,7 @@
|
|||||||
uid = 1000;
|
uid = 1000;
|
||||||
group = "julian";
|
group = "julian";
|
||||||
shell = pkgs.zsh;
|
shell = pkgs.zsh;
|
||||||
extraGroups = [ "networkmanager" "wheel" ];
|
extraGroups = [ "networkmanager" "wheel" "docker" ];
|
||||||
packages = with pkgs; [
|
packages = with pkgs; [
|
||||||
hunspell
|
hunspell
|
||||||
hunspellDicts.de_DE
|
hunspellDicts.de_DE
|
||||||
@ -152,16 +153,16 @@
|
|||||||
};
|
};
|
||||||
|
|
||||||
users.groups.julian = { gid = 1000; };
|
users.groups.julian = { gid = 1000; };
|
||||||
users.groups.wolfi = { gid = 1001; };
|
# users.groups.wolfi = { gid = 1001; };
|
||||||
|
|
||||||
users.users.wolfi = {
|
# users.users.wolfi = {
|
||||||
isNormalUser = true;
|
# isNormalUser = true;
|
||||||
description = "Wolfi";
|
# description = "Wolfi";
|
||||||
uid = 1001;
|
# uid = 1001;
|
||||||
group = "wolfi";
|
# group = "wolfi";
|
||||||
shell = pkgs.fish;
|
# shell = pkgs.fish;
|
||||||
extraGroups = [ "networkmanager" "wheel" ];
|
# extraGroups = [ "networkmanager" "wheel" ];
|
||||||
};
|
# };
|
||||||
|
|
||||||
# Allow unfree packages
|
# Allow unfree packages
|
||||||
nixpkgs.config.allowUnfree = true;
|
nixpkgs.config.allowUnfree = true;
|
||||||
@ -198,11 +199,15 @@
|
|||||||
|
|
||||||
# List packages installed in system profile. To search, run:
|
# List packages installed in system profile. To search, run:
|
||||||
# $ nix search wget
|
# $ nix search wget
|
||||||
|
|
||||||
environment.systemPackages = with pkgs; [
|
environment.systemPackages = with pkgs; [
|
||||||
|
(pkgs.python3.withPackages python-packages)
|
||||||
firefox
|
firefox
|
||||||
thunderbird
|
thunderbird
|
||||||
nextcloud-client
|
nextcloud-client
|
||||||
qalculate-gtk
|
qalculate-gtk
|
||||||
|
libqalculate
|
||||||
|
|
||||||
schildichat-desktop
|
schildichat-desktop
|
||||||
tdesktop
|
tdesktop
|
||||||
|
|
||||||
@ -300,6 +305,11 @@
|
|||||||
|
|
||||||
poppler_utils # Pdf utils including pdfimages
|
poppler_utils # Pdf utils including pdfimages
|
||||||
matlab # Using nix-matlab overlay defined in flake
|
matlab # Using nix-matlab overlay defined in flake
|
||||||
|
sage
|
||||||
|
|
||||||
|
devbox
|
||||||
|
parted
|
||||||
|
du-dust # Like du tree but better
|
||||||
];
|
];
|
||||||
|
|
||||||
nixpkgs.overlays = [
|
nixpkgs.overlays = [
|
||||||
@ -321,6 +331,8 @@
|
|||||||
source-code-pro
|
source-code-pro
|
||||||
];
|
];
|
||||||
|
|
||||||
|
virtualisation.docker.enable = true;
|
||||||
|
|
||||||
# Some programs need SUID wrappers, can be configured further or are
|
# Some programs need SUID wrappers, can be configured further or are
|
||||||
# started in user sessions.
|
# started in user sessions.
|
||||||
# programs.mtr.enable = true;
|
# programs.mtr.enable = true;
|
||||||
|
18
nix/flake.lock
generated
18
nix/flake.lock
generated
@ -22,11 +22,11 @@
|
|||||||
"nixpkgs": "nixpkgs"
|
"nixpkgs": "nixpkgs"
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1693148476,
|
"lastModified": 1693407679,
|
||||||
"narHash": "sha256-1TOqS+BnFgb+6H4XlVPb2y32rTSYh+dNnxHqFQz08s4=",
|
"narHash": "sha256-UeeXQk/PNmmFEeZ/hcpB8fyT6jjVUTYPtKicHThxmIw=",
|
||||||
"owner": "doronbehar",
|
"owner": "doronbehar",
|
||||||
"repo": "nix-matlab",
|
"repo": "nix-matlab",
|
||||||
"rev": "e5ae42eec5bc093f0a414ce86f7349dc9e43648f",
|
"rev": "bf537f8ae01effaebb3f5c6bdc6ab842faac6b2e",
|
||||||
"type": "gitlab"
|
"type": "gitlab"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@ -37,11 +37,11 @@
|
|||||||
},
|
},
|
||||||
"nixpkgs": {
|
"nixpkgs": {
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1693060755,
|
"lastModified": 1693355128,
|
||||||
"narHash": "sha256-KNsbfqewEziFJEpPR0qvVz4rx0x6QXxw1CcunRhlFdk=",
|
"narHash": "sha256-+ZoAny3ZxLcfMaUoLVgL9Ywb/57wP+EtsdNGuXUJrwg=",
|
||||||
"owner": "NixOS",
|
"owner": "NixOS",
|
||||||
"repo": "nixpkgs",
|
"repo": "nixpkgs",
|
||||||
"rev": "c66ccfa00c643751da2fd9290e096ceaa30493fc",
|
"rev": "a63a64b593dcf2fe05f7c5d666eb395950f36bc9",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@ -51,11 +51,11 @@
|
|||||||
},
|
},
|
||||||
"nixpkgs-unstable": {
|
"nixpkgs-unstable": {
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1693003285,
|
"lastModified": 1693377291,
|
||||||
"narHash": "sha256-5nm4yrEHKupjn62MibENtfqlP6pWcRTuSKrMiH9bLkc=",
|
"narHash": "sha256-vYGY9bnqEeIncNarDZYhm6KdLKgXMS+HA2mTRaWEc80=",
|
||||||
"owner": "NixOS",
|
"owner": "NixOS",
|
||||||
"repo": "nixpkgs",
|
"repo": "nixpkgs",
|
||||||
"rev": "5690c4271f2998c304a45c91a0aeb8fb69feaea7",
|
"rev": "e7f38be3775bab9659575f192ece011c033655f0",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
@ -8,33 +8,49 @@
|
|||||||
[ (modulesPath + "/installer/scan/not-detected.nix")
|
[ (modulesPath + "/installer/scan/not-detected.nix")
|
||||||
];
|
];
|
||||||
|
|
||||||
boot.initrd.availableKernelModules = [ "ehci_pci" "ahci" "xhci_pci" "usbhid" "usb_storage" "sd_mod" "sr_mod" ];
|
boot.initrd.availableKernelModules = [ "ehci_pci" "ahci" "xhci_pci" "usbhid" "uas" "sd_mod" "sr_mod" ];
|
||||||
boot.initrd.kernelModules = [ ];
|
boot.initrd.kernelModules = [ ];
|
||||||
boot.kernelModules = [ ];
|
boot.kernelModules = [ ];
|
||||||
boot.extraModulePackages = [ ];
|
boot.extraModulePackages = [ ];
|
||||||
|
|
||||||
fileSystems."/" =
|
fileSystems."/" =
|
||||||
{ device = "/dev/disk/by-uuid/7469546c-44d6-44a7-aecd-28aae51c84ca";
|
{ device = "/dev/disk/by-uuid/97a9342e-0be0-4193-9a25-03400fc7da94";
|
||||||
fsType = "ext4";
|
fsType = "btrfs";
|
||||||
};
|
options = [ "subvol=root" "compress=zstd" ];
|
||||||
|
|
||||||
fileSystems."/boot/efi" =
|
|
||||||
{ device = "/dev/disk/by-uuid/5A58-A8EB";
|
|
||||||
fsType = "vfat";
|
|
||||||
};
|
};
|
||||||
|
|
||||||
fileSystems."/home" =
|
fileSystems."/home" =
|
||||||
{ device = "/dev/disk/by-uuid/232d00ae-a844-4b59-97e9-d7248ff179a4";
|
{ device = "/dev/disk/by-uuid/97a9342e-0be0-4193-9a25-03400fc7da94";
|
||||||
fsType = "btrfs";
|
fsType = "btrfs";
|
||||||
|
options = [ "subvol=home" "compress=zstd" ];
|
||||||
};
|
};
|
||||||
|
|
||||||
swapDevices = [ { device = "/swapfile"; } ];
|
fileSystems."/nix" =
|
||||||
|
{ device = "/dev/disk/by-uuid/97a9342e-0be0-4193-9a25-03400fc7da94";
|
||||||
|
fsType = "btrfs";
|
||||||
|
options = [ "subvol=nix" "compress=zstd" "noatime" ];
|
||||||
|
};
|
||||||
|
|
||||||
|
# fileSystems."/swap" =
|
||||||
|
# { device = "/dev/disk/by-uuid/97a9342e-0be0-4193-9a25-03400fc7da94";
|
||||||
|
# fsType = "btrfs";
|
||||||
|
# options = [ "subvol=swap" "noatime" ];
|
||||||
|
# };
|
||||||
|
|
||||||
|
fileSystems."/boot/efi" =
|
||||||
|
{ device = "/dev/disk/by-uuid/7D48-A59C";
|
||||||
|
fsType = "vfat";
|
||||||
|
};
|
||||||
|
|
||||||
|
swapDevices = [ ];
|
||||||
|
# swapDevices = [ { device = "/swapfile"; } ];
|
||||||
|
|
||||||
# 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
|
||||||
# still possible to use this option, but it's recommended to use it in conjunction
|
# still possible to use this option, but it's recommended to use it in conjunction
|
||||||
# with explicit per-interface declarations with `networking.interfaces.<interface>.useDHCP`.
|
# with explicit per-interface declarations with `networking.interfaces.<interface>.useDHCP`.
|
||||||
networking.useDHCP = lib.mkDefault true;
|
networking.useDHCP = lib.mkDefault true;
|
||||||
|
# networking.interfaces.docker0.useDHCP = lib.mkDefault true;
|
||||||
# networking.interfaces.enp4s0.useDHCP = lib.mkDefault true;
|
# networking.interfaces.enp4s0.useDHCP = lib.mkDefault true;
|
||||||
|
|
||||||
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
|
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
|
||||||
|
Loading…
x
Reference in New Issue
Block a user