Guest User

configuration.nix

a guest
Feb 9th, 2023
184
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 4.15 KB | None | 0 0
  1. # Edit this configuration file to define what should be installed on
  2. # your system. Help is available in the configuration.nix(5) man page
  3. # and in the NixOS manual (accessible by running ‘nixos-help’).
  4.  
  5. { config, pkgs, ... }:
  6.  
  7. {
  8. imports =
  9. [ # Include the results of the hardware scan.
  10. ./hardware-configuration.nix
  11. ];
  12.  
  13. # Bootloader.
  14. boot.loader.systemd-boot.enable = true;
  15. boot.loader.efi.canTouchEfiVariables = true;
  16. boot.loader.efi.efiSysMountPoint = "/boot/efi";
  17.  
  18. # Setup keyfile
  19. boot.initrd.secrets = {
  20. "/crypto_keyfile.bin" = null;
  21. };
  22.  
  23. networking.hostName = "nixos"; # Define your hostname.
  24. # networking.wireless.enable = true; # Enables wireless support via wpa_supplicant.
  25.  
  26. # Configure network proxy if necessary
  27. # networking.proxy.default = "http://user:password@proxy:port/";
  28. # networking.proxy.noProxy = "127.0.0.1,localhost,internal.domain";
  29.  
  30. # Enable networking
  31. networking.networkmanager.enable = true;
  32.  
  33. # Set your time zone.
  34. time.timeZone = "Europe/Brussels";
  35.  
  36. # Select internationalisation properties.
  37. i18n.defaultLocale = "en_US.UTF-8";
  38.  
  39. i18n.extraLocaleSettings = {
  40. LC_ADDRESS = "it_IT.UTF-8";
  41. LC_IDENTIFICATION = "it_IT.UTF-8";
  42. LC_MEASUREMENT = "it_IT.UTF-8";
  43. LC_MONETARY = "it_IT.UTF-8";
  44. LC_NAME = "it_IT.UTF-8";
  45. LC_NUMERIC = "it_IT.UTF-8";
  46. LC_PAPER = "it_IT.UTF-8";
  47. LC_TELEPHONE = "it_IT.UTF-8";
  48. LC_TIME = "it_IT.UTF-8";
  49. };
  50.  
  51. # Configure X11
  52. services.xserver = {
  53. enable = true;
  54.  
  55. layout = "it";
  56. xkbVariant = "";
  57.  
  58. windowManager.herbstluftwm = {
  59. enable = true;
  60. };
  61.  
  62. displayManager = {
  63. defaultSession = "none+herbstluftwm";
  64. lightdm.enable = true;
  65.  
  66. autoLogin = {
  67. enable = true;
  68. user = "star";
  69. };
  70. };
  71.  
  72. desktopManager.xterm.enable = true;
  73.  
  74. resolutions = [ { x = 1920; y = 1080; } ];
  75. dpi = 141;
  76.  
  77. libinput.enable = true;
  78. libinput.touchpad.tappingButtonMap = "lrm";
  79. };
  80.  
  81. # Configure console keymap
  82. console.keyMap = "it";
  83.  
  84. # Define a user account. Don't forget to set a password with ‘passwd’.
  85. users.users.juice = {
  86. isNormalUser = true;
  87. extraGroups = [ "networkmanager" "wheel" ];
  88. packages = with pkgs; [
  89. syncplay tdesktop
  90. ];
  91. };
  92.  
  93. # Enable automatic login for the user.
  94. services.getty.autologinUser = "juice";
  95.  
  96. # Allow unfree packages
  97. nixpkgs.config.allowUnfree = true;
  98.  
  99. # List packages installed in system profile. To search, run:
  100. # $ nix search wget
  101. environment.systemPackages = with pkgs; [
  102. earlyoom lshw dunst exa feh git cinnamon.nemo parallel
  103. pavucontrol easyeffects playerctl zathura man-db
  104. qbittorrent rsync xorg.xev xorg.xkill xss-lock cheat
  105. dutree moar sublime4 picom-next polybar lxappearance
  106. arc-theme papirus-icon-theme rofi unzip unrar p7zip
  107. usbutils v4l-utils tdrop alacritty python3 rustup
  108. docker android-tools scrcpy appimage-run firefox fd
  109. neovim networkmanagerapplet ntfs3g
  110. ];
  111.  
  112. # Power management
  113. powerManagement.powertop.enable = true;
  114.  
  115. # Some programs need SUID wrappers, can be configured further or are
  116. # started in user sessions.
  117. # programs.mtr.enable = true;
  118. # programs.gnupg.agent = {
  119. # enable = true;
  120. # enableSSHSupport = true;
  121. # };
  122.  
  123. # List services that you want to enable:
  124.  
  125. # Enable the OpenSSH daemon.
  126. services.openssh.enable = true;
  127.  
  128. # Open ports in the firewall.
  129. # networking.firewall.allowedTCPPorts = [ ... ];
  130. # networking.firewall.allowedUDPPorts = [ ... ];
  131. # Or disable the firewall altogether.
  132. networking.firewall.enable = true;
  133.  
  134. # This value determines the NixOS release from which the default
  135. # settings for stateful data, like file locations and database versions
  136. # on your system were taken. It‘s perfectly fine and recommended to leave
  137. # this value at the release version of the first install of this system.
  138. # Before changing this value read the documentation for this option
  139. # (e.g. man configuration.nix or on https://nixos.org/nixos/options.html).
  140. system.stateVersion = "22.11"; # Did you read the comment?
  141.  
  142. }
  143.  
Add Comment
Please, Sign In to add comment