327 lines
6.6 KiB
Nix
327 lines
6.6 KiB
Nix
{ config, pkgs, ... }:
|
|
let
|
|
home-manager = builtins.fetchTarball "https://github.com/nix-community/home-manager/archive/master.tar.gz";
|
|
in
|
|
let
|
|
unstableTarball =
|
|
fetchTarball
|
|
https://github.com/NixOS/nixpkgs/archive/nixos-unstable.tar.gz;
|
|
in
|
|
{
|
|
imports =
|
|
[
|
|
./hardware-configuration.nix
|
|
(import "${home-manager}/nixos")
|
|
];
|
|
|
|
# Bootloader.
|
|
boot = {
|
|
loader = {
|
|
grub = {
|
|
enable = true;
|
|
device = "/dev/sda";
|
|
useOSProber = true;
|
|
enableCryptodisk=true;
|
|
};
|
|
};
|
|
initrd = {
|
|
kernelModules = [ "amdgpu" ];
|
|
luks.devices."luks-1e776713-4d94-401d-b9bf-60e70f1a8b3e".keyFile = "/crypto_keyfile.bin";
|
|
# Setup keyfile
|
|
secrets = {
|
|
"/crypto_keyfile.bin" = null;
|
|
};
|
|
};
|
|
|
|
};
|
|
networking.hostName = "jupiter"; # Define your hostname.
|
|
|
|
|
|
networking.networkmanager.enable = true;
|
|
|
|
time.timeZone = "Europe/Madrid";
|
|
i18n.defaultLocale = "en_US.utf8";
|
|
i18n.extraLocaleSettings = {
|
|
LC_ADDRESS = "es_US.utf8";
|
|
LC_IDENTIFICATION = "es_ES.utf8";
|
|
LC_MEASUREMENT = "es_ES.utf8";
|
|
LC_MONETARY = "es_ES.utf8";
|
|
LC_NAME = "es_ES.utf8";
|
|
LC_NUMERIC = "es_ES.utf8";
|
|
LC_PAPER = "es_ES.utf8";
|
|
LC_TELEPHONE = "es_ES.utf8";
|
|
LC_TIME = "es_ES.utf8";
|
|
};
|
|
|
|
sound.enable = true;
|
|
hardware = {
|
|
pulseaudio.enable = false;
|
|
opengl = {
|
|
driSupport32Bit = true;
|
|
driSupport = true;
|
|
|
|
extraPackages = with pkgs; [
|
|
amdvlk
|
|
];
|
|
extraPackages32 = with pkgs; [
|
|
driversi686Linux.amdvlk
|
|
];
|
|
};
|
|
};
|
|
security.rtkit.enable = true;
|
|
|
|
users = {
|
|
mutableUsers = false;
|
|
users.europa = {
|
|
uid = 1000;
|
|
shell = pkgs.fish;
|
|
hashedPassword = "$6$QV9sH1LG6jxHdly3$g5rM6cH1HHKHaXHOxNONFPMRW7ZFJCuGgI20KzA/OYiZbc.0JbIsWiYB4vDubIZXSF8od6EBKQoq9wwCeKNzR0";
|
|
isNormalUser = true;
|
|
description = "europa";
|
|
extraGroups = [ "networkmanager" "wheel" ];
|
|
};
|
|
};
|
|
|
|
home-manager.users.europa = {
|
|
home.packages = with pkgs; [
|
|
lutris
|
|
rofi-rbw
|
|
rofi
|
|
bspwm
|
|
kermit-terminal
|
|
steam-tui
|
|
gnome3.adwaita-icon-theme
|
|
];
|
|
programs = {
|
|
git = {
|
|
enable = true;
|
|
aliases = {
|
|
c = "commit";
|
|
ch = "checkout";
|
|
d = "diff";
|
|
r = "rebase";
|
|
s = "status";
|
|
st = "stash";
|
|
sw = "switch";
|
|
};
|
|
delta.enable = true;
|
|
userEmail = "catalin@roboces.dev";
|
|
userName = "185504a9";
|
|
signing = {
|
|
key = null;
|
|
signByDefault = true;
|
|
};
|
|
};
|
|
ssh = {
|
|
enable = true;
|
|
extraConfig = "
|
|
|
|
Host fuku.lilith
|
|
HostName lilith.fuku
|
|
User catalin
|
|
IdentityFile ~/.ssh/id_ed25519_robo
|
|
IdentitiesOnly yes
|
|
|
|
Host fuku.ramiel
|
|
HostName ramiel.fuku
|
|
User catalin
|
|
IdentityFile ~/.ssh/id_ed25519_robo
|
|
IdentitiesOnly yes
|
|
|
|
Host ceco.mars
|
|
HostName 192.168.2.130
|
|
User catalin
|
|
IdentityFile ~/.ssh/id_ed25519_robo
|
|
IdentitiesOnly yes
|
|
|
|
Host fuku.iramiel
|
|
HostName ramiel.fukurokuju.dev
|
|
User catalin
|
|
Port 23209
|
|
IdentityFile ~/.ssh/id_ed25519_robo
|
|
IdentitiesOnly yes
|
|
|
|
Host fuku.ililith
|
|
HostName ramiel.fukurokuju.dev
|
|
User catalin
|
|
Port 22209
|
|
IdentityFile ~/.ssh/id_ed25519_robo
|
|
IdentitiesOnly yes
|
|
|
|
Host fuku.containers
|
|
HostName containers.fuku
|
|
User bullseye
|
|
IdentityFile ~/.ssh/id_ed25519_robo
|
|
|
|
Host fuku.sandalphon
|
|
HostName sandalphon.fuku
|
|
User pi
|
|
IdentityFile ~/.ssh/id_ed25519_robo
|
|
IdentitiesOnly yes
|
|
|
|
Host fuku.zeruel
|
|
HostName zeruel.fuku
|
|
User pi
|
|
IdentityFile ~/.ssh/id_ed25519_robo IdentitiesOnly yes
|
|
|
|
Host fuku.dns
|
|
HostName dns.fuku
|
|
User root
|
|
IdentityFile ~/.ssh/id_ed25519_robo
|
|
IdentitiesOnly yes
|
|
|
|
Host fuku.cloud
|
|
HostName cloud.fuku
|
|
User root
|
|
IdentityFile ~/.ssh/id_ed25519_robo
|
|
IdentitiesOnly yes
|
|
|
|
Host fuku.postgres
|
|
HostName postgres.fuku
|
|
User root
|
|
|
|
Host fuku.postgres13
|
|
HostName postgres13.fuku
|
|
IdentityFile ~/.ssh/id_ed25519_robo
|
|
IdentitiesOnly yes
|
|
User root
|
|
|
|
Host fuku.smough
|
|
HostName smough.fuku
|
|
User root
|
|
|
|
Host fuku.gitea
|
|
HostName gitea.fuku
|
|
User root
|
|
|
|
Host fuku.nginx
|
|
HostName nginx.fuku
|
|
User root
|
|
|
|
Host fuku.redis
|
|
HostName redis.fuku
|
|
User root
|
|
|
|
Host fuku.mail
|
|
HostName mail.fukurokuju.dev
|
|
User root
|
|
|
|
Host gitlab.com
|
|
HostName gitlab.com
|
|
IdentityFile ~/.ssh/id_ed25519_ceco
|
|
IdentitiesOnly yes
|
|
|
|
Host gitlab.gitops
|
|
HostName gitlab.com
|
|
User git
|
|
AddKeysToAgent yes
|
|
IdentitiesOnly yes
|
|
IdentityFile ~/.ssh/id_ed25519.pub
|
|
";
|
|
};
|
|
fish = {
|
|
enable = true;
|
|
plugins = [{
|
|
name = "z";
|
|
src = pkgs.fetchFromGitHub {
|
|
owner = "jethrokuan";
|
|
repo = "z";
|
|
rev = "85f863f20f24faf675827fb00f3a4e15c7838d76";
|
|
sha256 = "sha256-+FUBM7CodtZrYKqU542fQD+ZDGrd2438trKM0tIESs0=";
|
|
};
|
|
}];
|
|
};
|
|
};
|
|
};
|
|
|
|
nixpkgs = {
|
|
overlays = [
|
|
(import (builtins.fetchTarball "https://github.com/oxalica/rust-overlay/archive/master.tar.gz"))
|
|
(self: super: {
|
|
neovim = super.neovim.override {
|
|
viAlias = true;
|
|
vimAlias = true;
|
|
};
|
|
})
|
|
];
|
|
config = {
|
|
allowUnfree = true;
|
|
packageOverrides = pkgs: {
|
|
unstable = import unstableTarball {
|
|
config = config.nixpkgs.config;
|
|
};
|
|
};
|
|
};
|
|
};
|
|
|
|
environment = {
|
|
variables = {
|
|
EDITOR = "nvim";
|
|
};
|
|
systemPackages = with pkgs; [
|
|
yank
|
|
gcc
|
|
git
|
|
fd
|
|
procs
|
|
tealdeer
|
|
ripgrep
|
|
bottom
|
|
du-dust
|
|
hyperfine
|
|
bandwhich
|
|
delta
|
|
gnumake
|
|
cargo
|
|
rustc
|
|
neovim
|
|
wget
|
|
curl
|
|
firefox
|
|
tmux
|
|
];
|
|
};
|
|
|
|
programs = {
|
|
neovim = {
|
|
enable = true;
|
|
viAlias = true;
|
|
};
|
|
fish.enable = true;
|
|
};
|
|
|
|
|
|
|
|
|
|
services = {
|
|
printing.enable = true;
|
|
flatpak.enable = true;
|
|
|
|
xserver = {
|
|
enable = true;
|
|
displayManager.gdm.enable = true;
|
|
desktopManager.gnome.enable = true;
|
|
layout = "us";
|
|
xkbVariant = "";
|
|
windowManager.bspwm.enable = true;
|
|
videoDrivers = [ "amdgpu" ];
|
|
};
|
|
|
|
pipewire = {
|
|
enable = true;
|
|
alsa.enable = true;
|
|
alsa.support32Bit = true;
|
|
pulse.enable = true;
|
|
};
|
|
|
|
openssh = {
|
|
enable = true;
|
|
passwordAuthentication = true;
|
|
permitRootLogin = "no";
|
|
};
|
|
|
|
};
|
|
system.stateVersion = "22.05";
|
|
}
|
|
|
|
|