init basic system
This commit is contained in:
parent
ead4bd10ac
commit
d1a3219ccc
15 changed files with 501 additions and 0 deletions
system
64
system/default.nix
Normal file
64
system/default.nix
Normal file
|
@ -0,0 +1,64 @@
|
|||
{pkgs, ...}: {
|
||||
imports = [
|
||||
./hardware.nix
|
||||
../modules
|
||||
];
|
||||
|
||||
documentation = {
|
||||
enable = true;
|
||||
doc.enable = false;
|
||||
man.enable = true;
|
||||
dev.enable = false;
|
||||
};
|
||||
|
||||
boot.loader = {
|
||||
grub = {
|
||||
enable = true;
|
||||
device = "/dev/sda";
|
||||
configurationLimit = 10;
|
||||
};
|
||||
};
|
||||
|
||||
boot.kernelPackages = pkgs.linuxPackages_latest;
|
||||
|
||||
networking.hostName = "basegbot";
|
||||
|
||||
networking.networkmanager.enable = true;
|
||||
|
||||
i18n.defaultLocale = "en_US.UTF-8";
|
||||
|
||||
services.tailscale.enable = true;
|
||||
services.fstrim.enable = true;
|
||||
|
||||
programs.direnv = {
|
||||
enable = true;
|
||||
loadInNixShell = true;
|
||||
nix-direnv.enable = true;
|
||||
};
|
||||
|
||||
services.xserver = {
|
||||
layout = "us";
|
||||
xkbVariant = "";
|
||||
};
|
||||
|
||||
users = {
|
||||
defaultUserShell = pkgs.nushell;
|
||||
users.basegbot = {
|
||||
openssh.authorizedKeys.keys = [
|
||||
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIEFgkIK+VR+xpAL85buL9ocql82kcVCcHbZyaytVDYB6 basegbot"
|
||||
];
|
||||
isNormalUser = true;
|
||||
description = "basegbot";
|
||||
extraGroups = ["networkmanager" "wheel"];
|
||||
packages = with pkgs; [
|
||||
git
|
||||
helix
|
||||
lazygit
|
||||
croc
|
||||
];
|
||||
};
|
||||
};
|
||||
|
||||
system.autoUpgrade.enable = false;
|
||||
system.stateVersion = "23.05";
|
||||
}
|
27
system/hardware.nix
Normal file
27
system/hardware.nix
Normal file
|
@ -0,0 +1,27 @@
|
|||
{
|
||||
lib,
|
||||
modulesPath,
|
||||
...
|
||||
}: {
|
||||
imports = [
|
||||
(modulesPath + "/profiles/qemu-guest.nix")
|
||||
];
|
||||
|
||||
boot.initrd.availableKernelModules = ["ata_piix" "uhci_hcd" "virtio_pci" "virtio_scsi" "sd_mod" "sr_mod"];
|
||||
boot.initrd.kernelModules = [];
|
||||
boot.kernelModules = ["kvm-intel"];
|
||||
boot.extraModulePackages = [];
|
||||
|
||||
fileSystems."/" = {
|
||||
device = "/dev/disk/by-uuid/477575a1-4100-4a02-b3ee-f68865792026";
|
||||
fsType = "ext4";
|
||||
};
|
||||
|
||||
swapDevices = [
|
||||
{device = "/dev/disk/by-uuid/a4556ca7-ea7b-4c5b-81fe-370d4157366b";}
|
||||
];
|
||||
|
||||
networking.useDHCP = lib.mkDefault true;
|
||||
|
||||
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue