|
| 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 | + nix.settings.experimental-features = ["nix-command" "flakes"]; |
| 14 | + |
| 15 | + home-manager.backupFileExtension = "backup"; |
| 16 | + |
| 17 | + |
| 18 | + environment.variables.EDITOR = "nano"; |
| 19 | + |
| 20 | + # Bootloader. |
| 21 | + boot.loader.systemd-boot.enable = true; |
| 22 | + boot.loader.efi.canTouchEfiVariables = true; |
| 23 | + |
| 24 | + networking.hostName = "nixos"; # Define your hostname. |
| 25 | + # networking.wireless.enable = true; # Enables wireless support via wpa_supplicant. |
| 26 | + |
| 27 | + # Configure network proxy if necessary |
| 28 | + # networking.proxy.default = "http://user:password@proxy:port/"; |
| 29 | + # networking.proxy.noProxy = "127.0.0.1,localhost,internal.domain"; |
| 30 | + |
| 31 | + # Enable networking |
| 32 | + networking.networkmanager.enable = true; |
| 33 | + |
| 34 | + # Set your time zone. |
| 35 | + time.timeZone = "Asia/Tashkent"; |
| 36 | + |
| 37 | + # Select internationalisation properties. |
| 38 | + i18n.defaultLocale = "en_US.UTF-8"; |
| 39 | + |
| 40 | + # Enable the X11 windowing system. |
| 41 | + services.xserver = { |
| 42 | + enable = true; |
| 43 | + }; |
| 44 | + |
| 45 | + # Enable the GNOME Desktop Environment. |
| 46 | + services.xserver.displayManager.gdm.enable = true; |
| 47 | + services.xserver.desktopManager.gnome.enable = true; |
| 48 | + |
| 49 | + # Configure keymap in X11 |
| 50 | + services.xserver.xkb = { |
| 51 | + layout = "us"; |
| 52 | + variant = ""; |
| 53 | + }; |
| 54 | + |
| 55 | + # Enable CUPS to print documents. |
| 56 | + services.printing.enable = true; |
| 57 | + |
| 58 | + # Enable sound with pipewire. |
| 59 | + hardware.pulseaudio.enable = false; |
| 60 | + security.rtkit.enable = true; |
| 61 | + services.pipewire = { |
| 62 | + enable = true; |
| 63 | + alsa.enable = true; |
| 64 | + alsa.support32Bit = true; |
| 65 | + pulse.enable = true; |
| 66 | + # If you want to use JACK applications, uncomment this |
| 67 | + #jack.enable = true; |
| 68 | + |
| 69 | + # use the example session manager (no others are packaged yet so this is enabled by default, |
| 70 | + # no need to redefine it in your config for now) |
| 71 | + #media-session.enable = true; |
| 72 | + }; |
| 73 | + |
| 74 | + # Enable touchpad support (enabled default in most desktopManager). |
| 75 | + # services.xserver.libinput.enable = true; |
| 76 | + |
| 77 | + # Define a user account. Don't forget to set a password with ‘passwd’. |
| 78 | + users.users.rarebek = { |
| 79 | + isNormalUser = true; |
| 80 | + description = "rarebek"; |
| 81 | + extraGroups = [ "networkmanager" "wheel" "docker" ]; |
| 82 | + packages = with pkgs; [ |
| 83 | + thunderbird |
| 84 | + git |
| 85 | + ]; |
| 86 | + }; |
| 87 | + |
| 88 | + # Docker rootless option |
| 89 | + virtualisation.docker.rootless = { |
| 90 | + enable = true; |
| 91 | + setSocketVariable = true; |
| 92 | + }; |
| 93 | + |
| 94 | + # Install firefox. |
| 95 | + programs.firefox.enable = true; |
| 96 | + |
| 97 | + # Allow unfree packages |
| 98 | + nixpkgs.config.allowUnfree = true; |
| 99 | + |
| 100 | + # List packages installed in system profile. To search, run: |
| 101 | + # $ nix search wget |
| 102 | + environment.systemPackages = with pkgs; [ |
| 103 | + # vim # Do not forget to add an editor to edit configuration.nix! The Nano editor is also installed by default. |
| 104 | + # wget |
| 105 | + telegram-desktop |
| 106 | + google-chrome |
| 107 | + vscode |
| 108 | + discord |
| 109 | + go |
| 110 | + git |
| 111 | + wget |
| 112 | + curl |
| 113 | + ]; |
| 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 = false; |
| 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 = "24.05"; # Did you read the comment? |
| 141 | + |
| 142 | +} |
0 commit comments