!qol(restructure): heavy restructure
This commit is contained in:
123
hosts/doloro-wsl/home.nix
Normal file
123
hosts/doloro-wsl/home.nix
Normal file
@@ -0,0 +1,123 @@
|
||||
{
|
||||
inputs,
|
||||
config,
|
||||
pkgs,
|
||||
fetchFromGitHub,
|
||||
...
|
||||
}:
|
||||
|
||||
{
|
||||
imports = [
|
||||
# ./modules/hyprland/home.nix
|
||||
# ./modules/quickshell/home.nix
|
||||
# ./modules/chromium/home.nix
|
||||
#./modules/neovim/home.nix
|
||||
# ./modules/stylix/home.nix
|
||||
#../../modules/nixvim/home.nix
|
||||
#../../modules/tmux/home.nix
|
||||
#../../modules/theme/home.nix
|
||||
# ./modules/spicetify/home.nix
|
||||
# ./modules/obs/home.nix
|
||||
# ./modules/blender/home.nix
|
||||
#../../modules/fish/home.nix
|
||||
# ./modules/ytm/home.nix
|
||||
#../../overlays.nix
|
||||
];
|
||||
modules = {
|
||||
nixvim.enable = true;
|
||||
tmux.enable = true;
|
||||
fish.enable = true;
|
||||
stylix.enable = true;
|
||||
direnv.enable = true;
|
||||
git.enable = true;
|
||||
};
|
||||
# Home Manager needs a bit of information about you and the paths it should
|
||||
# manage.
|
||||
home.username = "doloro";
|
||||
home.homeDirectory = "/home/doloro";
|
||||
|
||||
# This value determines the Home Manager release that your configuration is
|
||||
# compatible with. This helps avoid breakage when a new Home Manager release
|
||||
# introduces backwards incompatible changes.
|
||||
#
|
||||
# You should not change this value, even if you update Home Manager. If you do
|
||||
# want to update the value, then make sure to first check the Home Manager
|
||||
# release notes.
|
||||
home.stateVersion = "25.05"; # Please read the comment before changing.
|
||||
|
||||
services.gpg-agent = {
|
||||
enable = true;
|
||||
pinentry = {
|
||||
package = pkgs.pinentry-qt;
|
||||
program = "pinentry-qt";
|
||||
};
|
||||
};
|
||||
# The home.packages option allows you to install Nix packages into your
|
||||
# environment.
|
||||
home.packages = with pkgs; [
|
||||
hello
|
||||
# vim
|
||||
# telegram-desktop
|
||||
# vesktop
|
||||
# spotify
|
||||
# pavucontrol
|
||||
lazygit
|
||||
sops
|
||||
];
|
||||
# sops.age.keyFile = "/home/doloro/.config/sops/age/key.txt";
|
||||
|
||||
# Home Manager is pretty good at managing dotfiles. The primary way to manage
|
||||
# plain files is through 'home.file'.
|
||||
home.file = {
|
||||
# # Building this configuration will create a copy of 'dotfiles/screenrc' in
|
||||
# # the Nix store. Activating the configuration will then make '~/.screenrc' a
|
||||
# # symlink to the Nix store copy.
|
||||
# ".screenrc".source = dotfiles/screenrc;
|
||||
|
||||
# # You can also set the file content immediately.
|
||||
# ".gradle/gradle.properties".text = ''
|
||||
# org.gradle.console=verbose
|
||||
# org.gradle.daemon.idletimeout=3600000
|
||||
# '';
|
||||
};
|
||||
|
||||
# Home Manager can also manage your environment variables through
|
||||
# 'home.sessionVariables'. These will be explicitly sourced when using a
|
||||
# shell provided by Home Manager. If you don't want to manage your shell
|
||||
# through Home Manager then you have to manually source 'hm-session-vars.sh'
|
||||
# located at either
|
||||
#
|
||||
# ~/.nix-profile/etc/profile.d/hm-session-vars.sh
|
||||
#
|
||||
# or
|
||||
#
|
||||
# ~/.local/state/nix/profiles/profile/etc/profile.d/hm-session-vars.sh
|
||||
#
|
||||
# or
|
||||
#
|
||||
# /etc/profiles/per-user/doloro/etc/profile.d/hm-session-vars.sh
|
||||
#
|
||||
home.sessionVariables = {
|
||||
EDITOR = "nvim";
|
||||
};
|
||||
# {{{{{ TODO Put in different file
|
||||
# }}}}}
|
||||
# Let Home Manager install and manage itself.
|
||||
programs = {
|
||||
home-manager.enable = true;
|
||||
ssh = {
|
||||
enable = true;
|
||||
enableDefaultConfig = false;
|
||||
matchBlocks = {
|
||||
"*" = {
|
||||
addKeysToAgent = "yes";
|
||||
identityFile = [
|
||||
"~/.ssh/id_github"
|
||||
"~/.ssh/id_gitea_scug_io"
|
||||
"~/.ssh/id_ed25519"
|
||||
];
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
||||
41
hosts/doloro-wsl/nixos.nix
Normal file
41
hosts/doloro-wsl/nixos.nix
Normal file
@@ -0,0 +1,41 @@
|
||||
{
|
||||
inputs,
|
||||
pkgs,
|
||||
lib,
|
||||
user,
|
||||
...
|
||||
}:
|
||||
{
|
||||
modules = {
|
||||
fish.enable = true;
|
||||
stylix.enable = true;
|
||||
};
|
||||
imports = [
|
||||
inputs.nixos-wsl.nixosModules.default
|
||||
];
|
||||
# rocmSupport = false;
|
||||
programs = {
|
||||
dconf.enable = true;
|
||||
ssh = {
|
||||
startAgent = true;
|
||||
};
|
||||
};
|
||||
networking.dhcpcd.enable = lib.mkOverride 0 false;
|
||||
boot.loader.grub.enable = lib.mkOverride 0 false;
|
||||
wsl = {
|
||||
enable = true;
|
||||
defaultUser = user;
|
||||
docker-desktop.enable = false;
|
||||
useWindowsDriver = true;
|
||||
startMenuLaunchers = true;
|
||||
usbip.enable = true;
|
||||
};
|
||||
nix.settings = {
|
||||
experimental-features = "nix-command flakes";
|
||||
};
|
||||
nixpkgs.config.allowUnsupportedSystem = true;
|
||||
systemd.services."user-runtime-dir@" = {
|
||||
overrideStrategy = "asDropin";
|
||||
unitConfig.ConditionPathExists = "!/run/user/%i";
|
||||
};
|
||||
}
|
||||
150
hosts/doloro/home.nix
Normal file
150
hosts/doloro/home.nix
Normal file
@@ -0,0 +1,150 @@
|
||||
{
|
||||
inputs,
|
||||
config,
|
||||
pkgs,
|
||||
fetchFromGitHub,
|
||||
...
|
||||
}:
|
||||
{
|
||||
# imports = [
|
||||
# ../../modules/hyprland/home.nix
|
||||
# ../../modules/quickshell/home.nix
|
||||
# ../../modules/chromium/home.nix
|
||||
# #./modules/neovim/home.nix
|
||||
# ../../modules/stylix/home.nix
|
||||
# ../../modules/nixvim/home.nix
|
||||
# ../../modules/tmux/home.nix
|
||||
# ../../modules/theme/home.nix
|
||||
# # ./modules/spicetify/home.nix
|
||||
# ../../modules/obs/home.nix
|
||||
# ../../modules/blender/home.nix
|
||||
# ../../modules/fish/home.nix
|
||||
# ../../modules/ytm/home.nix
|
||||
# ../../overlays.nix
|
||||
# ];
|
||||
modules = {
|
||||
Hyprland.enable = true;
|
||||
quickshell.enable = true;
|
||||
# chromium.enable = true;
|
||||
wivrn.enable = true;
|
||||
helium.enable = true;
|
||||
nixvim.enable = true;
|
||||
helix.enable = false;
|
||||
stylix.enable = true;
|
||||
tmux.enable = true;
|
||||
theme.enable = true;
|
||||
obs.enable = true;
|
||||
blender.enable = true;
|
||||
bottles.enable = true;
|
||||
fish.enable = true;
|
||||
youtube-music.enable = true;
|
||||
unityhub.enable = true;
|
||||
direnv.enable = true;
|
||||
git.enable = true;
|
||||
};
|
||||
# Home Manager needs a bit of information about you and the paths it should
|
||||
# manage.
|
||||
home.username = "doloro";
|
||||
home.homeDirectory = "/home/doloro";
|
||||
|
||||
services = {
|
||||
gpg-agent = {
|
||||
enable = true;
|
||||
pinentry = {
|
||||
package = pkgs.pinentry-qt;
|
||||
program = "pinentry-qt";
|
||||
};
|
||||
};
|
||||
arrpc = {
|
||||
enable = false;
|
||||
};
|
||||
};
|
||||
xdg.mimeApps.enable = true;
|
||||
|
||||
# This value determines the Home Manager release that your configuration is
|
||||
# compatible with. This helps avoid breakage when a new Home Manager release
|
||||
# introduces backwards incompatible changes.
|
||||
#
|
||||
# You should not change this value, even if you update Home Manager. If you do
|
||||
# want to update the value, then make sure to first check the Home Manager
|
||||
# release notes.
|
||||
home.stateVersion = "25.05"; # Please read the comment before changing.
|
||||
|
||||
# The home.packages option allows you to install Nix packages into your
|
||||
# environment.
|
||||
home.packages = with pkgs; [
|
||||
hello
|
||||
vim
|
||||
telegram-desktop
|
||||
# vesktop
|
||||
(pkgs.discord.override { withVencord = true; })
|
||||
# spotify
|
||||
pavucontrol
|
||||
lazygit
|
||||
btop
|
||||
sops
|
||||
alcom
|
||||
gcr
|
||||
qbittorrent
|
||||
];
|
||||
# sops.age.keyFile = "/home/doloro/.config/sops/age/key.txt";
|
||||
|
||||
# Home Manager is pretty good at managing dotfiles. The primary way to manage
|
||||
# plain files is through 'home.file'.
|
||||
home.file = {
|
||||
# # Building this configuration will create a copy of 'dotfiles/screenrc' in
|
||||
# # the Nix store. Activating the configuration will then make '~/.screenrc' a
|
||||
# # symlink to the Nix store copy.
|
||||
# ".screenrc".source = dotfiles/screenrc;
|
||||
|
||||
# # You can also set the file content immediately.
|
||||
# ".gradle/gradle.properties".text = ''
|
||||
# org.gradle.console=verbose
|
||||
# org.gradle.daemon.idletimeout=3600000
|
||||
# '';
|
||||
};
|
||||
|
||||
# Home Manager can also manage your environment variables through
|
||||
# 'home.sessionVariables'. These will be explicitly sourced when using a
|
||||
# shell provided by Home Manager. If you don't want to manage your shell
|
||||
# through Home Manager then you have to manually source 'hm-session-vars.sh'
|
||||
# located at either
|
||||
#
|
||||
# ~/.nix-profile/etc/profile.d/hm-session-vars.sh
|
||||
#
|
||||
# or
|
||||
#
|
||||
# ~/.local/state/nix/profiles/profile/etc/profile.d/hm-session-vars.sh
|
||||
#
|
||||
# or
|
||||
#
|
||||
# /etc/profiles/per-user/doloro/etc/profile.d/hm-session-vars.sh
|
||||
#
|
||||
home.sessionVariables = {
|
||||
EDITOR = "nvim";
|
||||
};
|
||||
services = {
|
||||
dunst = {
|
||||
enable = true;
|
||||
};
|
||||
};
|
||||
xdg.configFile."mimeapps.list".force = true;
|
||||
# Let Home Manager install and manage itself.
|
||||
|
||||
programs = {
|
||||
ssh = {
|
||||
enable = true;
|
||||
enableDefaultConfig = false;
|
||||
matchBlocks = {
|
||||
"*" = {
|
||||
addKeysToAgent = "yes";
|
||||
identityFile = [
|
||||
"~/.ssh/id_ed25519"
|
||||
"~/.ssh/id_gitea_scug"
|
||||
];
|
||||
};
|
||||
};
|
||||
};
|
||||
home-manager.enable = true;
|
||||
};
|
||||
}
|
||||
265
hosts/doloro/nixos.nix
Normal file
265
hosts/doloro/nixos.nix
Normal file
@@ -0,0 +1,265 @@
|
||||
# Edit this configuration file to define what should be installed on
|
||||
# your system. Help is available in the configuration.nix(5) man page, on
|
||||
# https://search.nixos.org/options and in the NixOS manual (`nixos-help`).
|
||||
|
||||
{
|
||||
config,
|
||||
inputs,
|
||||
lib,
|
||||
pkgs,
|
||||
nix-meow,
|
||||
...
|
||||
}:
|
||||
let
|
||||
sops = inputs.sops-nix;
|
||||
in
|
||||
{
|
||||
imports = [
|
||||
inputs.sops-nix.nixosModules.sops
|
||||
];
|
||||
modules = {
|
||||
fish.enable = true;
|
||||
greetd.enable = true;
|
||||
stylix.enable = true;
|
||||
steam.enable = true;
|
||||
Hyprland.enable = true;
|
||||
wivrn.enable = true;
|
||||
};
|
||||
|
||||
# Use the systemd-boot EFI boot loader.
|
||||
boot.loader.grub.enable = true;
|
||||
boot.loader.grub.device = "nodev";
|
||||
boot.loader.grub.devices = [
|
||||
"/dev/disk/by-id/nvme-CT1000P2SSD8_2221E632CD1F"
|
||||
"nodev"
|
||||
];
|
||||
#boot.loader.efi.canTouchEfiVariables = true;
|
||||
boot.loader.grub.efiSupport = true;
|
||||
boot.loader.grub.efiInstallAsRemovable = true;
|
||||
|
||||
nix.settings = {
|
||||
substituters = [
|
||||
"https://nix-community.cachix.org"
|
||||
"https://cache.nixos.org/"
|
||||
"https://attic.scug.io/pkgs"
|
||||
];
|
||||
trusted-public-keys = [
|
||||
"nix-community.cachix.org-1:mB9FSh9qf2dCimDSUo8Zy7bkq5CX+/rkCWyvRCYg3Fs="
|
||||
"pkgs:+sRbfiZMMX5R3PuAPtIRz/emowDoGZNpozibrnrAvuc="
|
||||
];
|
||||
experimental-features = [
|
||||
"flakes"
|
||||
"nix-command"
|
||||
];
|
||||
trusted-users = [
|
||||
"doloro"
|
||||
];
|
||||
};
|
||||
|
||||
networking.hostName = "doloroo-main"; # Define your hostname.
|
||||
|
||||
nixpkgs.config.allowUnfree = true;
|
||||
|
||||
# Configure network connections interactively with nmcli or nmtui.
|
||||
networking.networkmanager.enable = true;
|
||||
networking.firewall.enable = false;
|
||||
|
||||
security.rtkit.enable = true;
|
||||
|
||||
sops = {
|
||||
defaultSopsFile = builtins.toPath "${nix-meow.flakeRoot}/secrets/users.yaml";
|
||||
secrets = {
|
||||
root-hashed_password = {
|
||||
neededForUsers = true;
|
||||
};
|
||||
doloro-hashed_password = {
|
||||
neededForUsers = true;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
# Set your time zone.
|
||||
time.timeZone = "Europe/London";
|
||||
|
||||
# Configure network proxy if necessary
|
||||
# networking.proxy.default = "http://user:password@proxy:port/";
|
||||
# networking.proxy.noProxy = "127.0.0.1,localhost,internal.domain";
|
||||
|
||||
# Select internationalisation properties.
|
||||
# i18n.defaultLocale = "en_US.UTF-8";
|
||||
# console = {
|
||||
# font = "Lat2-Terminus16";
|
||||
# keyMap = "us";
|
||||
# useXkbConfig = true; # use xkb.options in tty.
|
||||
# };
|
||||
|
||||
# Enable the X11 windowing system.
|
||||
# services.xserver.enable = true;
|
||||
|
||||
# Enable OpenGL
|
||||
hardware.graphics = {
|
||||
enable = true;
|
||||
};
|
||||
|
||||
# Load nvidia driver for Xorg and Wayland
|
||||
services.xserver.videoDrivers = [ "nvidia" ];
|
||||
|
||||
fileSystems."/mnt/2tb" = {
|
||||
device = "/dev/disk/by-uuid/0f49aec7-4af2-4f4f-b475-3f4fad2b59c2";
|
||||
fsType = "ext4";
|
||||
options = [
|
||||
# If you don't have this options attribute, it'll default to "defaults"
|
||||
# boot options for fstab. Search up fstab mount options you can use
|
||||
"defaults"
|
||||
"users" # Allows any user to mount and unmount
|
||||
"nofail" # Prevent system from failing if this drive doesn't mount
|
||||
"exec"
|
||||
];
|
||||
};
|
||||
|
||||
hardware.nvidia = {
|
||||
|
||||
# Modesetting is required.
|
||||
modesetting.enable = true;
|
||||
|
||||
# Nvidia power management. Experimental, and can cause sleep/suspend to fail.
|
||||
# Enable this if you have graphical corruption issues or application crashes after waking
|
||||
# up from sleep. This fixes it by saving the entire VRAM memory to /tmp/ instead
|
||||
# of just the bare essentials.
|
||||
powerManagement.enable = true;
|
||||
|
||||
# Fine-grained power management. Turns off GPU when not in use.
|
||||
# Experimental and only works on modern Nvidia GPUs (Turing or newer).
|
||||
powerManagement.finegrained = false;
|
||||
# prime.offload.enable = true;
|
||||
|
||||
# Use the NVidia open source kernel module (not to be confused with the
|
||||
# independent third-party "nouveau" open source driver).
|
||||
# Support is limited to the Turing and later architectures. Full list of
|
||||
# supported GPUs is at:
|
||||
# https://github.com/NVIDIA/open-gpu-kernel-modules#compatible-gpus
|
||||
# Only available from driver 515.43.04+
|
||||
open = false;
|
||||
|
||||
# Enable the Nvidia settings menu,
|
||||
# accessible via `nvidia-settings`.
|
||||
nvidiaSettings = true;
|
||||
|
||||
# Optionally, you may need to select the appropriate driver version for your specific GPU.
|
||||
package = config.boot.kernelPackages.nvidiaPackages.latest;
|
||||
};
|
||||
|
||||
fonts = {
|
||||
enableDefaultPackages = true;
|
||||
packages = with pkgs; [
|
||||
nerd-fonts.jetbrains-mono
|
||||
material-design-icons
|
||||
material-symbols
|
||||
nerd-fonts.caskaydia-cove
|
||||
nerd-fonts.noto
|
||||
noto-fonts-cjk-sans
|
||||
noto-fonts-cjk-serif
|
||||
];
|
||||
fontDir.enable = true;
|
||||
};
|
||||
|
||||
# Configure keymap in X11
|
||||
# services.xserver.xkb.layout = "us";
|
||||
# services.xserver.xkb.options = "eurosign:e,caps:escape";
|
||||
|
||||
# Enable CUPS to print documents.
|
||||
# services.printing.enable = true;
|
||||
|
||||
# Enable sound.
|
||||
# services.pulseaudio.enable = true;
|
||||
# OR
|
||||
services.pipewire = {
|
||||
enable = true;
|
||||
pulse.enable = true;
|
||||
};
|
||||
|
||||
programs = {
|
||||
ssh = {
|
||||
# enable = true;
|
||||
extraConfig = "AddKeysToAgent yes";
|
||||
startAgent = true;
|
||||
};
|
||||
fish.enable = true;
|
||||
};
|
||||
# Enable touchpad support (enabled default in most desktopManager).
|
||||
# services.libinput.enable = true;
|
||||
services.openssh = {
|
||||
enable = true;
|
||||
settings = {
|
||||
PasswordAuthentication = true;
|
||||
};
|
||||
};
|
||||
users.users.doloro = {
|
||||
isNormalUser = true;
|
||||
shell = pkgs.fish;
|
||||
extraGroups = [
|
||||
"wheel"
|
||||
"dialout"
|
||||
]; # Enable ‘sudo’ for the user.
|
||||
packages = with pkgs; [
|
||||
tree
|
||||
];
|
||||
};
|
||||
users.mutableUsers = false;
|
||||
users.users.doloro.hashedPasswordFile = config.sops.secrets."doloro-hashed_password".path;
|
||||
# users.users.root.hashedPasswordFile = config.sops.secrets."root-hashed_password".path;
|
||||
users.users.root.initialPassword = "root";
|
||||
# programs.firefox.enable = true;
|
||||
|
||||
# List packages installed in system profile.
|
||||
# You can use https://search.nixos.org/ to find more packages (and options).
|
||||
environment.systemPackages = with pkgs; [
|
||||
vim # Do not forget to add an editor to edit configuration.nix! The Nano editor is also installed by default.
|
||||
wget
|
||||
killall
|
||||
sops
|
||||
];
|
||||
|
||||
# Some programs need SUID wrappers, can be configured further or are
|
||||
# started in user sessions.
|
||||
# programs.mtr.enable = true;
|
||||
# programs.gnupg.agent = {
|
||||
# enable = true;
|
||||
# enableSSHSupport = true;
|
||||
# };
|
||||
|
||||
# List services that you want to enable:
|
||||
|
||||
# Enable the OpenSSH daemon.
|
||||
# services.openssh.enable = true;
|
||||
|
||||
# Open ports in the firewall.
|
||||
# networking.firewall.allowedTCPPorts = [ ... ];
|
||||
# networking.firewall.allowedUDPPorts = [ ... ];
|
||||
# Or disable the firewall altogether.
|
||||
# networking.firewall.enable = false;
|
||||
|
||||
# Copy the NixOS configuration file and link it from the resulting system
|
||||
# (/run/current-system/configuration.nix). This is useful in case you
|
||||
# accidentally delete configuration.nix.
|
||||
# system.copySystemConfiguration = true;
|
||||
|
||||
# This option defines the first version of NixOS you have installed on this particular machine,
|
||||
# and is used to maintain compatibility with application data (e.g. databases) created on older NixOS versions.
|
||||
#
|
||||
# Most users should NEVER change this value after the initial install, for any reason,
|
||||
# even if you've upgraded your system to a new NixOS release.
|
||||
#
|
||||
# This value does NOT affect the Nixpkgs version your packages and OS are pulled from,
|
||||
# so changing it will NOT upgrade your system - see https://nixos.org/manual/nixos/stable/#sec-upgrading for how
|
||||
# to actually do that.
|
||||
#
|
||||
# This value being lower than the current NixOS release does NOT mean your system is
|
||||
# out of date, out of support, or vulnerable.
|
||||
#
|
||||
# Do NOT change this value unless you have manually inspected all the changes it would make to your configuration,
|
||||
# and migrated your data accordingly.
|
||||
#
|
||||
# For more information, see `man configuration.nix` or https://nixos.org/manual/nixos/stable/options#opt-system.stateVersion .
|
||||
system.stateVersion = "25.11"; # Did you read the comment?
|
||||
}
|
||||
Reference in New Issue
Block a user