This commit is contained in:
cnst
2024-06-21 17:44:02 +02:00
parent f9b2c71463
commit 9794839977
17 changed files with 634 additions and 62 deletions

View File

@@ -77,14 +77,32 @@
pkgs.nixd
];
# Bootloader
boot.loader.grub.enable = true;
boot.loader.grub.device = "/dev/vda";
boot.loader.grub.useOSProber = true;
fonts.packages = with pkgs; [
noto-fonts
noto-fonts-cjk
noto-fonts-emoji
liberation_ttf
fira-code-symbols
font-awesome
jetbrains-mono
(nerdfonts.override {fonts = ["JetBrainsMono" "FiraCode" "Iosevka" "3270" "DroidSansMono"];})
]; # Bootloader
boot.loader.systemd-boot.enable = true;
boot.loader.efi.canTouchEfiVariables = true;
# Enable networking
networking.networkmanager.enable = true;
# TODO: Set your hostname
networking.hostName = "cnix";
# Enable sound with pipewire.
hardware.pulseaudio.enable = false;
security.rtkit.enable = true;
programs.hyprland = {
# Install the packages from nixpkgs
enable = true;
# Whether to enable XWayland
xwayland.enable = true;
};
# Time zone & Locale
time.timeZone = "Europe/Stockholm";
@@ -102,49 +120,62 @@
LC_TIME = "sv_SE.UTF-8";
};
# Configure keymap in X11
services.xserver.xkb = {
extraLayouts.hhkbse = {
description = "HHKBse by cnst";
languages = [ "se" ];
symbolsFile = /home/cnst/Documents/nix-config/nixos/xkb/symbols/hhkbse;
};
layout = "hhkbse";
# dir = "/home/cnst/Documents/nix-config/nixos/xkb";
variant = "";
options = "lv3:rwin_switch";
};
# Console keymap
console.useXkbConfig = true;
# TODO: Configure your system-wide user settings (groups, etc), add more users as needed.
users.users = {
cnst = {
# TODO: You can set an initial password for your user.
# If you do, you can skip setting a root password by passing '--no-root-passwd' to nixos-install.
# Be sure to change it (using passwd) after rebooting!
initialPassword = "1234";
isNormalUser = true;
openssh.authorizedKeys.keys = [
# TODO: Add your SSH public key(s) here, if you plan on using SSH to connect
];
# TODO: Be sure to add any other groups you need (such as networkmanager, audio, docker, etc)
extraGroups = [ "wheel" "networkmanager" "audio" "video" ];
extraGroups = ["wheel" "networkmanager" "audio" "video"];
};
};
# This setups a SSH server. Very important if you're setting up a headless system.
# Feel free to remove if you don't need it.
services.openssh = {
enable = true;
settings = {
# Opinionated: forbid root login through SSH.
PermitRootLogin = "no";
# Opinionated: use keys only.
# Remove if you want to SSH using passwords
PasswordAuthentication = false;
# services
services = {
mullvad-vpn.enable = true;
mullvad-vpn.package = pkgs.mullvad-vpn;
openssh = {
enable = true;
settings = {
# Opinionated: forbid root login through SSH.
PermitRootLogin = "no";
# Opinionated: use keys only.
# Remove if you want to SSH using passwords
PasswordAuthentication = false;
};
};
xserver = {
enable = true;
displayManager.gdm.enable = true;
desktopManager.gnome.enable = true;
xkb = {
extraLayouts.hhkbse = {
description = "HHKBse by cnst";
languages = ["se"];
symbolsFile = /home/cnst/.nix-config/nixos/xkb/symbols/hhkbse;
};
layout = "hhkbse";
# dir = "/home/cnst/.nix-config/nixos/xkb";
variant = "";
options = "lv3:rwin_switch";
};
};
pipewire = {
enable = true;
alsa.enable = true;
alsa.support32Bit = true;
pulse.enable = true;
# If you want to use JACK applications, uncomment this
#jack.enable = true;
# use the example session manager (no others are packaged yet so this is enabled by default,
# no need to redefine it in your config for now)
#media-session.enable = true;
};
};