Compare commits
1 Commits
4ec06a5204
...
gitea_typs
| Author | SHA1 | Date | |
|---|---|---|---|
|
f601854156
|
@@ -2,8 +2,7 @@
|
||||
config,
|
||||
pkgs,
|
||||
...
|
||||
}:
|
||||
{
|
||||
}: {
|
||||
imports = [
|
||||
];
|
||||
|
||||
@@ -15,10 +14,7 @@
|
||||
gc.automatic = true;
|
||||
gc.options = "--delete-older-than 7d";
|
||||
package = pkgs.nixVersions.latest;
|
||||
settings.experimental-features = [
|
||||
"nix-command"
|
||||
"flakes"
|
||||
];
|
||||
settings.experimental-features = ["nix-command" "flakes"];
|
||||
};
|
||||
|
||||
boot = {
|
||||
@@ -57,16 +53,15 @@
|
||||
networking = {
|
||||
firewall.enable = true;
|
||||
hostName = "blue";
|
||||
nameservers = [
|
||||
"127.0.0.1"
|
||||
"::1"
|
||||
];
|
||||
nameservers = ["127.0.0.1" "::1"];
|
||||
dhcpcd.extraConfig = "nohook resolv.conf";
|
||||
|
||||
networkmanager = {
|
||||
enable = true;
|
||||
dns = "none";
|
||||
# wifi.backend = "iwd";
|
||||
/*
|
||||
wifi.backend = "iwd";
|
||||
*/
|
||||
};
|
||||
};
|
||||
|
||||
@@ -157,10 +152,7 @@
|
||||
windowManager.i3.enable = true;
|
||||
};
|
||||
|
||||
udev.packages = [
|
||||
pkgs.rtl-sdr
|
||||
pkgs.openhantek6022
|
||||
];
|
||||
udev.packages = [pkgs.rtl-sdr pkgs.openhantek6022];
|
||||
|
||||
tlp = {
|
||||
enable = true;
|
||||
@@ -177,19 +169,13 @@
|
||||
|
||||
{
|
||||
keys = [114];
|
||||
events = [
|
||||
"key"
|
||||
"rep"
|
||||
];
|
||||
events = ["key" "rep"];
|
||||
command = "/run/current-system/sw/bin/runuser -l akill -c 'amixer -q set Master 5%- unmute'";
|
||||
}
|
||||
|
||||
{
|
||||
keys = [115];
|
||||
events = [
|
||||
"key"
|
||||
"rep"
|
||||
];
|
||||
events = ["key" "rep"];
|
||||
command = "/run/current-system/sw/bin/runuser -l akill -c 'amixer -q set Master 5%+ unmute'";
|
||||
}
|
||||
|
||||
@@ -320,14 +306,6 @@
|
||||
users.users.akill = {
|
||||
isNormalUser = true;
|
||||
shell = pkgs.zsh;
|
||||
extraGroups = [
|
||||
"wireshark"
|
||||
"kvm"
|
||||
"tty"
|
||||
"audio"
|
||||
"sound"
|
||||
"adbusers"
|
||||
"dialout"
|
||||
];
|
||||
extraGroups = ["wireshark" "kvm" "tty" "audio" "sound" "adbusers" "dialout"];
|
||||
};
|
||||
}
|
||||
|
||||
@@ -6,21 +6,12 @@
|
||||
lib,
|
||||
modulesPath,
|
||||
...
|
||||
}:
|
||||
{
|
||||
}: {
|
||||
imports = [
|
||||
(modulesPath + "/installer/scan/not-detected.nix")
|
||||
];
|
||||
|
||||
boot.initrd.availableKernelModules = [
|
||||
"xhci_pci"
|
||||
"ahci"
|
||||
"nvme"
|
||||
"usbhid"
|
||||
"usb_storage"
|
||||
"sd_mod"
|
||||
"sr_mod"
|
||||
];
|
||||
boot.initrd.availableKernelModules = ["xhci_pci" "ahci" "nvme" "usbhid" "usb_storage" "sd_mod" "sr_mod"];
|
||||
boot.initrd.kernelModules = [];
|
||||
boot.kernelModules = ["kvm-intel"];
|
||||
boot.extraModulePackages = [];
|
||||
@@ -28,55 +19,34 @@
|
||||
fileSystems."/" = {
|
||||
device = "/dev/disk/by-uuid/0af4dcb9-6e59-4946-87b2-0d2f14b808d4";
|
||||
fsType = "btrfs";
|
||||
options = [
|
||||
"subvol=root"
|
||||
"compress=zstd"
|
||||
"noatime"
|
||||
];
|
||||
options = ["subvol=root" "compress=zstd" "noatime"];
|
||||
};
|
||||
|
||||
boot.initrd.luks.devices."enc_root".device =
|
||||
"/dev/disk/by-uuid/8eb8ac22-d89d-4406-bfbd-ce43e283649f";
|
||||
boot.initrd.luks.devices."enc_root".device = "/dev/disk/by-uuid/8eb8ac22-d89d-4406-bfbd-ce43e283649f";
|
||||
|
||||
fileSystems."/home" = {
|
||||
device = "/dev/disk/by-uuid/0af4dcb9-6e59-4946-87b2-0d2f14b808d4";
|
||||
fsType = "btrfs";
|
||||
options = [
|
||||
"subvol=home"
|
||||
"compress=zstd"
|
||||
"noatime"
|
||||
];
|
||||
options = ["subvol=home" "compress=zstd" "noatime"];
|
||||
};
|
||||
|
||||
fileSystems."/nix" = {
|
||||
device = "/dev/disk/by-uuid/0af4dcb9-6e59-4946-87b2-0d2f14b808d4";
|
||||
fsType = "btrfs";
|
||||
options = [
|
||||
"subvol=nix"
|
||||
"compress=zstd"
|
||||
"noatime"
|
||||
];
|
||||
options = ["subvol=nix" "compress=zstd" "noatime"];
|
||||
};
|
||||
|
||||
fileSystems."/var/log" = {
|
||||
device = "/dev/disk/by-uuid/0af4dcb9-6e59-4946-87b2-0d2f14b808d4";
|
||||
fsType = "btrfs";
|
||||
options = [
|
||||
"subvol=log"
|
||||
"compress=zstd"
|
||||
"noatime"
|
||||
];
|
||||
options = ["subvol=log" "compress=zstd" "noatime"];
|
||||
neededForBoot = true;
|
||||
};
|
||||
|
||||
fileSystems."/persist" = {
|
||||
device = "/dev/disk/by-uuid/0af4dcb9-6e59-4946-87b2-0d2f14b808d4";
|
||||
fsType = "btrfs";
|
||||
options = [
|
||||
"subvol=persist"
|
||||
"compress=zstd"
|
||||
"noatime"
|
||||
];
|
||||
options = ["subvol=persist" "compress=zstd" "noatime"];
|
||||
};
|
||||
|
||||
fileSystems."/boot" = {
|
||||
|
||||
@@ -1,25 +1,19 @@
|
||||
{ pkgs
|
||||
, system
|
||||
, ...
|
||||
}:
|
||||
{
|
||||
environment.systemPackages =
|
||||
with pkgs;
|
||||
pkgs,
|
||||
nix-xilinx,
|
||||
system,
|
||||
...
|
||||
}: {
|
||||
environment.systemPackages = with pkgs;
|
||||
[
|
||||
alsa-ucm-conf
|
||||
onboard
|
||||
maliit-keyboard
|
||||
maliit-framework
|
||||
wvkbd
|
||||
acpi
|
||||
aria2
|
||||
binutils
|
||||
binwalk
|
||||
bluez
|
||||
bluez-tools
|
||||
btop
|
||||
busybox
|
||||
curl
|
||||
curlHTTP3
|
||||
dfu-util
|
||||
dhcpcd
|
||||
direnv
|
||||
@@ -27,7 +21,6 @@
|
||||
dnsmasq
|
||||
dnsutils
|
||||
dtach
|
||||
ethtool
|
||||
f2fs-tools
|
||||
fd
|
||||
file
|
||||
@@ -97,5 +90,6 @@
|
||||
xfsprogs
|
||||
zip
|
||||
z-lua
|
||||
];
|
||||
]
|
||||
++ (with nix-xilinx.packages.${system}; [vivado vitis vitis_hls model_composer xilinx-shell]);
|
||||
}
|
||||
|
||||
@@ -4,11 +4,9 @@
|
||||
pkgs,
|
||||
...
|
||||
}:
|
||||
with lib;
|
||||
let
|
||||
with lib; let
|
||||
cfg = config.services.batteryNotifier;
|
||||
in
|
||||
{
|
||||
in {
|
||||
options = {
|
||||
services.batteryNotifier = {
|
||||
enable = mkOption {
|
||||
|
||||
178
flake.lock
generated
178
flake.lock
generated
@@ -35,11 +35,11 @@
|
||||
"flake-compat_2": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1761588595,
|
||||
"narHash": "sha256-XKUZz9zewJNUj46b4AJdiRZJAvSZ0Dqj2BNfXvFlJC4=",
|
||||
"lastModified": 1673956053,
|
||||
"narHash": "sha256-4gtG9iQuiKITOjNQQeQIpoIB6b16fm+504Ch3sNKLd8=",
|
||||
"owner": "edolstra",
|
||||
"repo": "flake-compat",
|
||||
"rev": "f387cd2afec9419c8ee37694406ca490c3f34ee5",
|
||||
"rev": "35bb57c0c8d8b62bbfd284272c928ceb64ddbde9",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
@@ -48,51 +48,37 @@
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"git-hooks": {
|
||||
"inputs": {
|
||||
"flake-compat": [
|
||||
"simple-nixos-mailserver",
|
||||
"flake-compat"
|
||||
],
|
||||
"gitignore": "gitignore",
|
||||
"nixpkgs": [
|
||||
"simple-nixos-mailserver",
|
||||
"nixpkgs"
|
||||
]
|
||||
},
|
||||
"flake-compat_3": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1763988335,
|
||||
"narHash": "sha256-QlcnByMc8KBjpU37rbq5iP7Cp97HvjRP0ucfdh+M4Qc=",
|
||||
"owner": "cachix",
|
||||
"repo": "git-hooks.nix",
|
||||
"rev": "50b9238891e388c9fdc6a5c49e49c42533a1b5ce",
|
||||
"lastModified": 1696426674,
|
||||
"narHash": "sha256-kvjfFW7WAETZlt09AgDn1MrtKzP7t90Vf7vypd3OL1U=",
|
||||
"owner": "edolstra",
|
||||
"repo": "flake-compat",
|
||||
"rev": "0f9255e01c2351cc7d116c072cb317785dd33b33",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "cachix",
|
||||
"repo": "git-hooks.nix",
|
||||
"owner": "edolstra",
|
||||
"repo": "flake-compat",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"gitignore": {
|
||||
"flake-utils": {
|
||||
"inputs": {
|
||||
"nixpkgs": [
|
||||
"simple-nixos-mailserver",
|
||||
"git-hooks",
|
||||
"nixpkgs"
|
||||
]
|
||||
"systems": "systems"
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1709087332,
|
||||
"narHash": "sha256-HG2cCnktfHsKV0s4XW83gU3F57gaTljL9KNSuG6bnQs=",
|
||||
"owner": "hercules-ci",
|
||||
"repo": "gitignore.nix",
|
||||
"rev": "637db329424fd7e46cf4185293b9cc8c88c95394",
|
||||
"lastModified": 1681202837,
|
||||
"narHash": "sha256-H+Rh19JDwRtpVPAWp64F+rlEtxUWBAQW28eAi3SRSzg=",
|
||||
"owner": "numtide",
|
||||
"repo": "flake-utils",
|
||||
"rev": "cfacdce06f30d2b68473a46042957675eebb3401",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "hercules-ci",
|
||||
"repo": "gitignore.nix",
|
||||
"owner": "numtide",
|
||||
"repo": "flake-utils",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
@@ -103,16 +89,15 @@
|
||||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1764536451,
|
||||
"narHash": "sha256-BgtcUkBfItu9/yU14IgUaj4rYOanTOUZjUfBP20/ZB4=",
|
||||
"lastModified": 1730016908,
|
||||
"narHash": "sha256-bFCxJco7d8IgmjfNExNz9knP8wvwbXU4s/d53KOK6U0=",
|
||||
"owner": "nix-community",
|
||||
"repo": "home-manager",
|
||||
"rev": "3fdd076e08049a9c7a83149b270440d9787d2df5",
|
||||
"rev": "e83414058edd339148dc142a8437edb9450574c8",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "nix-community",
|
||||
"ref": "release-25.11",
|
||||
"repo": "home-manager",
|
||||
"type": "github"
|
||||
}
|
||||
@@ -138,34 +123,49 @@
|
||||
"type": "gitlab"
|
||||
}
|
||||
},
|
||||
"nixos": {
|
||||
"nixpkgs": {
|
||||
"locked": {
|
||||
"lastModified": 1764831616,
|
||||
"narHash": "sha256-OtzF5wBvO0jgW1WW1rQU9cMGx7zuvkF7CAVJ1ypzkxA=",
|
||||
"lastModified": 1732981179,
|
||||
"narHash": "sha256-F7thesZPvAMSwjRu0K8uFshTk3ZZSNAsXTIFvXBT+34=",
|
||||
"owner": "nixos",
|
||||
"repo": "nixpkgs",
|
||||
"rev": "c97c47f2bac4fa59e2cbdeba289686ae615f8ed4",
|
||||
"rev": "62c435d93bf046a5396f3016472e8f7c8e2aed65",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "nixos",
|
||||
"ref": "nixos-25.11",
|
||||
"ref": "nixos-24.11",
|
||||
"repo": "nixpkgs",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"nixpkgs": {
|
||||
"nixpkgs-24_05": {
|
||||
"locked": {
|
||||
"lastModified": 1764522689,
|
||||
"narHash": "sha256-SqUuBFjhl/kpDiVaKLQBoD8TLD+/cTUzzgVFoaHrkqY=",
|
||||
"owner": "nixos",
|
||||
"lastModified": 1717144377,
|
||||
"narHash": "sha256-F/TKWETwB5RaR8owkPPi+SPJh83AQsm6KrQAlJ8v/uA=",
|
||||
"owner": "NixOS",
|
||||
"repo": "nixpkgs",
|
||||
"rev": "8bb5646e0bed5dbd3ab08c7a7cc15b75ab4e1d0f",
|
||||
"rev": "805a384895c696f802a9bf5bf4720f37385df547",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "nixos",
|
||||
"ref": "nixos-25.11",
|
||||
"id": "nixpkgs",
|
||||
"ref": "nixos-24.05",
|
||||
"type": "indirect"
|
||||
}
|
||||
},
|
||||
"nixpkgs-stable": {
|
||||
"locked": {
|
||||
"lastModified": 1729973466,
|
||||
"narHash": "sha256-knnVBGfTCZlQgxY1SgH0vn2OyehH9ykfF8geZgS95bk=",
|
||||
"owner": "NixOS",
|
||||
"repo": "nixpkgs",
|
||||
"rev": "cd3e8833d70618c4eea8df06f95b364b016d4950",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "NixOS",
|
||||
"ref": "release-24.05",
|
||||
"repo": "nixpkgs",
|
||||
"type": "github"
|
||||
}
|
||||
@@ -177,11 +177,11 @@
|
||||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1764594740,
|
||||
"narHash": "sha256-YLyM7w1j7BcOK9F+L7x7iY9wfOzPfcIBWW9LeU9Wzoo=",
|
||||
"lastModified": 1733261583,
|
||||
"narHash": "sha256-HOVUtrhtJ16umPuEODuVE9fx+JmDCRp7wIxnEART0Eg=",
|
||||
"ref": "refs/heads/master",
|
||||
"rev": "878c87430f5e3c109f183a1822988b1c32413131",
|
||||
"revCount": 51,
|
||||
"rev": "a09a34997ce692c7a2e8e434b44433156a73088c",
|
||||
"revCount": 38,
|
||||
"type": "git",
|
||||
"url": "https://git.project-cloud.net/asmir/nvim_flake"
|
||||
},
|
||||
@@ -190,6 +190,28 @@
|
||||
"url": "https://git.project-cloud.net/asmir/nvim_flake"
|
||||
}
|
||||
},
|
||||
"peerix": {
|
||||
"inputs": {
|
||||
"flake-compat": "flake-compat_2",
|
||||
"flake-utils": "flake-utils",
|
||||
"nixpkgs": [
|
||||
"nixpkgs"
|
||||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1684706914,
|
||||
"narHash": "sha256-pBlTtsC28e/5MUTe4NWeNNOc/4Kf6EzGQGppQEQ/ioo=",
|
||||
"owner": "asmir.abdulahovic",
|
||||
"repo": "peerix",
|
||||
"rev": "8fdbbd0039240e05b4f93bbd5b454d5643e8a8d1",
|
||||
"type": "gitlab"
|
||||
},
|
||||
"original": {
|
||||
"owner": "asmir.abdulahovic",
|
||||
"repo": "peerix",
|
||||
"type": "gitlab"
|
||||
}
|
||||
},
|
||||
"project-cloud": {
|
||||
"inputs": {
|
||||
"nixpkgs": [
|
||||
@@ -216,9 +238,9 @@
|
||||
"inputs": {
|
||||
"home-manager": "home-manager",
|
||||
"nix-xilinx": "nix-xilinx",
|
||||
"nixos": "nixos",
|
||||
"nixpkgs": "nixpkgs",
|
||||
"nvim": "nvim",
|
||||
"peerix": "peerix",
|
||||
"project-cloud": "project-cloud",
|
||||
"simple-nixos-mailserver": "simple-nixos-mailserver",
|
||||
"sops-nix": "sops-nix",
|
||||
@@ -229,18 +251,18 @@
|
||||
"simple-nixos-mailserver": {
|
||||
"inputs": {
|
||||
"blobs": "blobs",
|
||||
"flake-compat": "flake-compat_2",
|
||||
"git-hooks": "git-hooks",
|
||||
"flake-compat": "flake-compat_3",
|
||||
"nixpkgs": [
|
||||
"nixpkgs"
|
||||
]
|
||||
],
|
||||
"nixpkgs-24_05": "nixpkgs-24_05"
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1764381008,
|
||||
"narHash": "sha256-s+/BuhPPSJHpPRcylqfW+3UFyYsHjAhKdtPSxusYn0U=",
|
||||
"lastModified": 1722877200,
|
||||
"narHash": "sha256-qgKDNJXs+od+1UbRy62uk7dYal3h98I4WojfIqMoGcg=",
|
||||
"owner": "simple-nixos-mailserver",
|
||||
"repo": "nixos-mailserver",
|
||||
"rev": "76bd7a85e78a9b8295782a9cf719ec3489d8eb55",
|
||||
"rev": "af7d3bf5daeba3fc28089b015c0dd43f06b176f2",
|
||||
"type": "gitlab"
|
||||
},
|
||||
"original": {
|
||||
@@ -253,14 +275,15 @@
|
||||
"inputs": {
|
||||
"nixpkgs": [
|
||||
"nixpkgs"
|
||||
]
|
||||
],
|
||||
"nixpkgs-stable": "nixpkgs-stable"
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1764483358,
|
||||
"narHash": "sha256-EyyvCzXoHrbL467YSsQBTWWg4sR96MH1sPpKoSOelB4=",
|
||||
"lastModified": 1729999681,
|
||||
"narHash": "sha256-qm0uCtM9bg97LeJTKQ8dqV/FvqRN+ompyW4GIJruLuw=",
|
||||
"owner": "Mic92",
|
||||
"repo": "sops-nix",
|
||||
"rev": "5aca6ff67264321d47856a2ed183729271107c9c",
|
||||
"rev": "1666d16426abe79af5c47b7c0efa82fd31bf4c56",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
@@ -289,6 +312,21 @@
|
||||
"url": "https://git.project-cloud.net/asmir/swaysw"
|
||||
}
|
||||
},
|
||||
"systems": {
|
||||
"locked": {
|
||||
"lastModified": 1681028828,
|
||||
"narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=",
|
||||
"owner": "nix-systems",
|
||||
"repo": "default",
|
||||
"rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "nix-systems",
|
||||
"repo": "default",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"theme_anemone": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
@@ -328,11 +366,11 @@
|
||||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1764579633,
|
||||
"narHash": "sha256-gOD5RMHOB9Fw4T3nk2a95YdU0J24QU3uWUiZVIQza64=",
|
||||
"lastModified": 1721120316,
|
||||
"narHash": "sha256-CaAMnU6LKqJrsZmR9k0/2brpULnAekpgG5S0BjtFhaQ=",
|
||||
"ref": "refs/heads/master",
|
||||
"rev": "b0707744e2b4a077e759145cdbfa8d8d1017e732",
|
||||
"revCount": 25,
|
||||
"rev": "8a7923bd4e5d36b186408d5432568a91ac67b695",
|
||||
"revCount": 21,
|
||||
"type": "git",
|
||||
"url": "https://git.project-cloud.net/asmir/zremap"
|
||||
},
|
||||
|
||||
118
flake.nix
118
flake.nix
@@ -2,14 +2,18 @@
|
||||
description = "NixOS configuration";
|
||||
|
||||
inputs = {
|
||||
nixpkgs.url = "github:nixos/nixpkgs/nixos-25.11";
|
||||
nixos.url = "github:nixos/nixpkgs/nixos-25.11";
|
||||
nixpkgs.url = "github:nixos/nixpkgs/nixos-24.11";
|
||||
|
||||
nix-xilinx = {
|
||||
url = "gitlab:asmir.abdulahovic/nix-xilinx";
|
||||
inputs.nixpkgs.follows = "nixpkgs";
|
||||
};
|
||||
|
||||
peerix = {
|
||||
url = "gitlab:asmir.abdulahovic/peerix";
|
||||
inputs.nixpkgs.follows = "nixpkgs";
|
||||
};
|
||||
|
||||
zremap = {
|
||||
url = "git+https://git.project-cloud.net/asmir/zremap";
|
||||
inputs.nixpkgs.follows = "nixpkgs";
|
||||
@@ -31,7 +35,7 @@
|
||||
};
|
||||
|
||||
home-manager = {
|
||||
url = "github:nix-community/home-manager/release-25.11";
|
||||
url = "github:nix-community/home-manager";
|
||||
inputs.nixpkgs.follows = "nixpkgs";
|
||||
};
|
||||
|
||||
@@ -46,24 +50,22 @@
|
||||
};
|
||||
};
|
||||
|
||||
outputs =
|
||||
inputs@{ home-manager
|
||||
, nixpkgs
|
||||
, nix-xilinx
|
||||
, nvim
|
||||
, project-cloud
|
||||
, simple-nixos-mailserver
|
||||
, sops-nix
|
||||
, swaysw
|
||||
, zremap
|
||||
, nixos
|
||||
, ...
|
||||
}:
|
||||
let
|
||||
outputs = inputs @ {
|
||||
home-manager,
|
||||
nixpkgs,
|
||||
nix-xilinx,
|
||||
nvim,
|
||||
peerix,
|
||||
project-cloud,
|
||||
simple-nixos-mailserver,
|
||||
sops-nix,
|
||||
swaysw,
|
||||
zremap,
|
||||
...
|
||||
}: let
|
||||
pkgs = nixpkgs.legacyPackages.x86_64-linux.pkgs;
|
||||
in
|
||||
{
|
||||
nixosConfigurations = {
|
||||
in {
|
||||
nixosConfigurations = rec {
|
||||
nixy = nixpkgs.lib.nixosSystem rec {
|
||||
system = "x86_64-linux";
|
||||
modules = [
|
||||
@@ -79,54 +81,21 @@
|
||||
{
|
||||
home-manager.useGlobalPkgs = true;
|
||||
home-manager.useUserPackages = true;
|
||||
home-manager.users.akill = import ./home/nixy/home.nix;
|
||||
home-manager.users.akill = import ./home/home.nix;
|
||||
home-manager.extraSpecialArgs = {inherit inputs system;};
|
||||
home-manager.backupFileExtension = "home_backup";
|
||||
}
|
||||
];
|
||||
};
|
||||
|
||||
fuji = nixpkgs.lib.nixosSystem rec {
|
||||
system = "x86_64-linux";
|
||||
modules = [
|
||||
{ _module.args = inputs; }
|
||||
{ _module.args.system = system; }
|
||||
{ nix.registry.nixpkgs.flake = nixpkgs; }
|
||||
./common/packages.nix
|
||||
./common/suspend.nix
|
||||
./fuji/configuration.nix
|
||||
./fuji/hardware-configuration.nix
|
||||
sops-nix.nixosModules.sops
|
||||
home-manager.nixosModules.home-manager
|
||||
peerix.nixosModules.peerix
|
||||
{
|
||||
home-manager.useGlobalPkgs = true;
|
||||
home-manager.useUserPackages = true;
|
||||
home-manager.users.akill = import ./home/fuji/home.nix;
|
||||
home-manager.extraSpecialArgs = { inherit inputs system; };
|
||||
home-manager.backupFileExtension = "home_backup";
|
||||
}
|
||||
];
|
||||
services.peerix = {
|
||||
enable = true;
|
||||
globalCacheTTL = 10;
|
||||
package = peerix.packages.x86_64-linux.peerix;
|
||||
openFirewall = true; # UDP/12304
|
||||
privateKeyFile = nixy.config.sops.secrets."peerix/private".path;
|
||||
publicKeyFile = ./nixy/peerix-public;
|
||||
publicKey = "peerix-mediabox:UDgG3xdQYv7bmx2l4ZPNRPJtp2zMmY++H/fnGeJ9BQw=";
|
||||
};
|
||||
|
||||
nixy_iso = nixos.lib.nixosSystem rec {
|
||||
system = "x86_64-linux";
|
||||
modules = [
|
||||
{ _module.args = inputs; }
|
||||
{ _module.args.system = system; }
|
||||
{ nix.registry.nixpkgs.flake = nixpkgs; }
|
||||
{ isoImage.squashfsCompression = "gzip -Xcompression-level 1"; }
|
||||
./common/packages.nix
|
||||
./common/suspend.nix
|
||||
./nixy/configuration.nix
|
||||
"${nixos}/nixos/modules/installer/cd-dvd/installation-cd-minimal-new-kernel-no-zfs.nix"
|
||||
sops-nix.nixosModules.sops
|
||||
home-manager.nixosModules.home-manager
|
||||
{
|
||||
home-manager.useGlobalPkgs = true;
|
||||
home-manager.useUserPackages = true;
|
||||
home-manager.users.akill = import ./home/nixy/home.nix;
|
||||
home-manager.extraSpecialArgs = { inherit inputs system; };
|
||||
home-manager.backupFileExtension = "home_backup";
|
||||
}
|
||||
];
|
||||
};
|
||||
@@ -147,9 +116,21 @@
|
||||
{
|
||||
home-manager.useGlobalPkgs = true;
|
||||
home-manager.useUserPackages = true;
|
||||
home-manager.users.akill = import ./home/mediabox/home.nix;
|
||||
home-manager.users.akill = import ./home/home.nix;
|
||||
home-manager.extraSpecialArgs = {inherit inputs system;};
|
||||
}
|
||||
peerix.nixosModules.peerix
|
||||
{
|
||||
services.peerix = {
|
||||
enable = true;
|
||||
globalCacheTTL = 10;
|
||||
package = peerix.packages.x86_64-linux.peerix;
|
||||
openFirewall = true; # UDP/12304
|
||||
privateKeyFile = mediabox.config.sops.secrets."peerix/private".path;
|
||||
publicKeyFile = ./mediabox/peerix-public;
|
||||
publicKey = "peerix-nixy:8THqS0R2zWF/47ai0RFmqJnieYTZ1jaWOD9tnzpvA6s=";
|
||||
};
|
||||
}
|
||||
];
|
||||
};
|
||||
|
||||
@@ -166,12 +147,11 @@
|
||||
{
|
||||
home-manager.useGlobalPkgs = true;
|
||||
home-manager.useUserPackages = true;
|
||||
home-manager.users.akill = import ./home/blue/home.nix;
|
||||
home-manager.users.akill = import ./home/home.nix;
|
||||
home-manager.extraSpecialArgs = {inherit inputs system;};
|
||||
}
|
||||
];
|
||||
};
|
||||
|
||||
magpie = nixpkgs.lib.nixosSystem rec {
|
||||
system = "aarch64-linux";
|
||||
modules = [
|
||||
@@ -188,11 +168,7 @@
|
||||
};
|
||||
|
||||
devShell.x86_64-linux = pkgs.mkShell {
|
||||
buildInputs = with pkgs; [
|
||||
sops
|
||||
ssh-to-age
|
||||
age
|
||||
];
|
||||
buildInputs = with pkgs; [sops ssh-to-age age];
|
||||
shellHook = ''
|
||||
echo "Configuring NixOS!"
|
||||
'';
|
||||
|
||||
@@ -1,706 +0,0 @@
|
||||
{ config
|
||||
, nvim
|
||||
, pkgs
|
||||
, system
|
||||
, zremap
|
||||
, ...
|
||||
}:
|
||||
let
|
||||
USER = "akill";
|
||||
in
|
||||
{
|
||||
imports = [ ];
|
||||
|
||||
system = {
|
||||
stateVersion = "23.05";
|
||||
autoUpgrade.enable = false;
|
||||
etc.overlay.enable = true;
|
||||
nixos-init.enable = true;
|
||||
};
|
||||
|
||||
sops = {
|
||||
age.sshKeyPaths = [ "/etc/ssh/ssh_host_ed25519_key" ];
|
||||
secrets = {
|
||||
"peerix/private" = {
|
||||
sopsFile = ./secrets/peerix.yaml;
|
||||
mode = "0400";
|
||||
owner = config.users.users.nobody.name;
|
||||
group = config.users.users.nobody.group;
|
||||
};
|
||||
|
||||
"wg_privkey" = {
|
||||
sopsFile = ./secrets/wg_privkey.yaml;
|
||||
};
|
||||
|
||||
"wg_preshared/nixy" = {
|
||||
sopsFile = ../common/secrets/wg_preshared.yaml;
|
||||
};
|
||||
|
||||
"wg_privkey_proton" = {
|
||||
sopsFile = ./secrets/wg_privkey_proton.yaml;
|
||||
};
|
||||
|
||||
"wg_endpoint_proton" = {
|
||||
sopsFile = ./secrets/wg_privkey_proton.yaml;
|
||||
};
|
||||
|
||||
"borgbase_enc_key" = {
|
||||
sopsFile = ./secrets/borgbase_enc_key.yaml;
|
||||
owner = config.users.users.${USER}.name;
|
||||
};
|
||||
|
||||
"borgbase_ssh_key" = {
|
||||
sopsFile = ./secrets/borgbase_ssh_key.yaml;
|
||||
owner = config.users.users.${USER}.name;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
nix = {
|
||||
optimise.automatic = true;
|
||||
gc.automatic = true;
|
||||
gc.options = "--delete-older-than 7d";
|
||||
package = pkgs.nixVersions.latest;
|
||||
settings = {
|
||||
sandbox = true;
|
||||
experimental-features = [
|
||||
"nix-command"
|
||||
"flakes"
|
||||
];
|
||||
};
|
||||
};
|
||||
|
||||
boot = {
|
||||
extraModulePackages = with config.boot.kernelPackages; [
|
||||
usbip
|
||||
v4l2loopback
|
||||
];
|
||||
extraModprobeConfig = ''
|
||||
options snd_sof ipc_type=1 tplg_path=intel/sof-ipc4-tplg tplg_filename=sof-hda-generic-cavs25-2ch.tplg
|
||||
'';
|
||||
blacklistedKernelModules = [ ];
|
||||
|
||||
|
||||
initrd.compressor = "zstd";
|
||||
initrd.kernelModules = [ ];
|
||||
initrd.systemd.enable = true;
|
||||
binfmt.emulatedSystems = [
|
||||
"wasm32-wasi"
|
||||
"x86_64-windows"
|
||||
];
|
||||
kernelParams = [
|
||||
"xe.force_probe=a7a0"
|
||||
"i915.force_probe=!a7a0"
|
||||
];
|
||||
kernelPackages = pkgs.linuxPackages_latest;
|
||||
kernel.sysctl = {
|
||||
"net.core.default_qdisc" = "fq";
|
||||
"net.ipv4.tcp_congestion_control" = "bbr";
|
||||
"kernel.unprivileged_userns_clone" = "1"; /* Needed with harderned kernel */
|
||||
};
|
||||
loader.efi.canTouchEfiVariables = true;
|
||||
loader.systemd-boot = {
|
||||
editor = false;
|
||||
enable = true;
|
||||
memtest86.enable = true;
|
||||
};
|
||||
nixStoreMountOpts = [ "ro" ];
|
||||
supportedFilesystems = [
|
||||
"xfs"
|
||||
];
|
||||
tmp.useTmpfs = true;
|
||||
};
|
||||
|
||||
security = {
|
||||
rtkit.enable = true;
|
||||
allowSimultaneousMultithreading = true;
|
||||
sudo.enable = true;
|
||||
doas.enable = true;
|
||||
doas.extraRules = [
|
||||
{
|
||||
users = [ USER ];
|
||||
keepEnv = true;
|
||||
persist = true;
|
||||
}
|
||||
];
|
||||
};
|
||||
|
||||
powerManagement = {
|
||||
enable = true;
|
||||
};
|
||||
|
||||
networking = {
|
||||
nftables.enable = true;
|
||||
firewall = {
|
||||
enable = true;
|
||||
allowedTCPPorts = [
|
||||
80
|
||||
443
|
||||
51820
|
||||
8020
|
||||
];
|
||||
};
|
||||
|
||||
hostName = "fuji";
|
||||
nameservers = [
|
||||
"127.0.0.1"
|
||||
"::1"
|
||||
];
|
||||
dhcpcd.extraConfig = "nohook resolv.conf";
|
||||
|
||||
extraHosts = ''
|
||||
192.168.88.171 jellyfin.mediabox.lan
|
||||
192.168.88.171 jellyseerr.mediabox.lan
|
||||
192.168.88.171 mediabox.lan
|
||||
192.168.88.171 qbittorrent.mediabox.lan
|
||||
192.168.88.1 router.lan
|
||||
192.168.88.231 workstation.lan
|
||||
192.168.88.121 ender.lan
|
||||
'';
|
||||
|
||||
networkmanager = {
|
||||
enable = true;
|
||||
dns = "none";
|
||||
wifi.backend = "iwd";
|
||||
};
|
||||
|
||||
wireless.iwd = {
|
||||
enable = true;
|
||||
settings = {
|
||||
General = {
|
||||
AddressRandomization = "network";
|
||||
#EnableNetworkConfiguration = true;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
wireguard.interfaces = {
|
||||
wg0 = {
|
||||
ips = [ "10.100.0.6/24" ];
|
||||
privateKeyFile = config.sops.secrets."wg_privkey".path;
|
||||
peers = [
|
||||
{
|
||||
publicKey = builtins.readFile ../magpie/wg_pubkey;
|
||||
presharedKeyFile = config.sops.secrets."wg_preshared/nixy".path;
|
||||
allowedIPs = [ "10.100.0.0/24" ];
|
||||
endpoint = "5.75.229.224:51820";
|
||||
persistentKeepalive = 25;
|
||||
}
|
||||
];
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
time.timeZone = "Europe/Sarajevo";
|
||||
|
||||
nixpkgs.config.allowUnfree = true;
|
||||
nixpkgs.overlays = [
|
||||
nvim.overlays.${system}.overlay
|
||||
];
|
||||
environment = {
|
||||
systemPackages = with pkgs; [ alsa-ucm-conf maliit-keyboard ];
|
||||
variables.ALSA_CONFIG_UCM2 = "${pkgs.alsa-ucm-conf}/share/alsa/ucm2";
|
||||
|
||||
sessionVariables = {
|
||||
LIBVA_DRIVER_NAME = "iHD";
|
||||
KWIN_COMPOSE = "O2ES";
|
||||
};
|
||||
|
||||
etc = {
|
||||
"firejail/qutebrowser.local".text = ''
|
||||
whitelist ''${RUNUSER}/qutebrowser
|
||||
'';
|
||||
"xdg/autostart/powerdevil.desktop".text = ''
|
||||
[Desktop Entry]
|
||||
Hidden=true
|
||||
'';
|
||||
};
|
||||
extraInit = ''
|
||||
unset -v SSH_ASKPASS
|
||||
'';
|
||||
homeBinInPath = true;
|
||||
variables = {
|
||||
PATH = "$HOME/.cargo/bin";
|
||||
};
|
||||
};
|
||||
|
||||
programs = {
|
||||
steam = {
|
||||
enable = true;
|
||||
remotePlay.openFirewall = true;
|
||||
dedicatedServer.openFirewall = false;
|
||||
localNetworkGameTransfers.openFirewall = true;
|
||||
};
|
||||
gnupg.agent = {
|
||||
enable = true;
|
||||
enableSSHSupport = true;
|
||||
};
|
||||
appimage = {
|
||||
enable = true;
|
||||
binfmt = true;
|
||||
};
|
||||
nix-ld = {
|
||||
enable = false;
|
||||
libraries = with pkgs; [
|
||||
stdenv.cc.cc.lib
|
||||
zlib
|
||||
];
|
||||
};
|
||||
zsh.enable = true;
|
||||
firejail.enable = true;
|
||||
adb.enable = true;
|
||||
wireshark.enable = true;
|
||||
sway.enable = true;
|
||||
};
|
||||
|
||||
documentation.dev.enable = true;
|
||||
|
||||
systemd = {
|
||||
#sysusers.enable = true;
|
||||
services = {
|
||||
# Fix issue where systemd-vconsole-setup failes to find keymap
|
||||
systemd-vconsole-setup = {
|
||||
unitConfig = {
|
||||
After = "local-fs.target";
|
||||
};
|
||||
};
|
||||
|
||||
"zremap@" = {
|
||||
enable = true;
|
||||
restartIfChanged = true;
|
||||
serviceConfig.Nice = -20;
|
||||
unitConfig = {
|
||||
Description = "zremap on %I";
|
||||
ConditionPathExists = "%I";
|
||||
};
|
||||
serviceConfig = {
|
||||
Type = "simple";
|
||||
ExecStart = "${zremap.defaultPackage.${system}}/bin/zremap %I";
|
||||
};
|
||||
};
|
||||
|
||||
"netns@" = {
|
||||
description = "%I network namespace";
|
||||
before = [ "network.target" ];
|
||||
serviceConfig = {
|
||||
Type = "oneshot";
|
||||
RemainAfterExit = true;
|
||||
ExecStart = "${pkgs.iproute2}/bin/ip netns add %I";
|
||||
ExecStop = "${pkgs.iproute2}/bin/ip netns del %I";
|
||||
};
|
||||
};
|
||||
|
||||
"wg_proton" = {
|
||||
description = "wg network interface";
|
||||
bindsTo = [ "netns@wg.service" ];
|
||||
requires = [ "network-online.target" ];
|
||||
wants = [ "dnscrypt-proxy_proton.service" ];
|
||||
after = [ "netns@wg.service" ];
|
||||
before = [ "dnscrypt-proxy_proton.service" ];
|
||||
serviceConfig = {
|
||||
Type = "oneshot";
|
||||
RemainAfterExit = true;
|
||||
ExecStart = pkgs.writers.writeBash "wg-up" ''
|
||||
set -e
|
||||
ENDPOINT_IP=$(${pkgs.coreutils-full}/bin/cat "${config.sops.secrets."wg_endpoint_proton".path}")
|
||||
${pkgs.iproute2}/bin/ip link add proton_wg type wireguard
|
||||
${pkgs.iproute2}/bin/ip link set proton_wg netns wg
|
||||
${pkgs.iproute2}/bin/ip -n wg address add 10.2.0.2/32 dev proton_wg
|
||||
${pkgs.iproute2}/bin/ip netns exec wg \
|
||||
${pkgs.wireguard-tools}/bin/wg set "proton_wg" private-key "${
|
||||
config.sops.secrets."wg_privkey_proton".path
|
||||
}"
|
||||
${pkgs.iproute2}/bin/ip netns exec wg \
|
||||
${pkgs.wireguard-tools}/bin/wg set "proton_wg" peer "g6DkXWKI/68RsLjROIwCEcyB/ZhyK5Q7OWcz1TtqER0=" \
|
||||
endpoint "$ENDPOINT_IP:51820" \
|
||||
persistent-keepalive "25" \
|
||||
allowed-ips "0.0.0.0/0"
|
||||
${pkgs.iproute2}/bin/ip -n wg link set lo up
|
||||
${pkgs.iproute2}/bin/ip -n wg link set proton_wg up
|
||||
${pkgs.iproute2}/bin/ip -n wg route add default dev proton_wg
|
||||
'';
|
||||
ExecStop = pkgs.writers.writeBash "wg-down" ''
|
||||
${pkgs.iproute2}/bin/ip -n wg route del default dev proton_wg
|
||||
${pkgs.iproute2}/bin/ip -n wg link del proton_wg
|
||||
'';
|
||||
};
|
||||
};
|
||||
|
||||
"dnscrypt-proxy_proton" = {
|
||||
description = "DNSCrypt-proxy client proton";
|
||||
wants = [
|
||||
"network-online.target"
|
||||
"nss-lookup.target"
|
||||
];
|
||||
before = [ "nss-lookup.target" ];
|
||||
after = [ "wg_proton.service" ];
|
||||
partOf = [ "wg_proton.service" ];
|
||||
serviceConfig = {
|
||||
AmbientCapabilities = "CAP_NET_BIND_SERVICE";
|
||||
CacheDirectory = "dnscrypt-proxy";
|
||||
DynamicUser = true;
|
||||
ExecStart = "${pkgs.dnscrypt-proxy}/bin/dnscrypt-proxy -config ${config.services.dnscrypt-proxy.configFile}";
|
||||
LockPersonality = true;
|
||||
LogsDirectory = "dnscrypt-proxy";
|
||||
MemoryDenyWriteExecute = true;
|
||||
NetworkNamespacePath = "/var/run/netns/wg";
|
||||
NonBlocking = true;
|
||||
NoNewPrivileges = true;
|
||||
PrivateDevices = true;
|
||||
ProtectClock = true;
|
||||
ProtectControlGroups = true;
|
||||
ProtectHome = true;
|
||||
ProtectHostname = true;
|
||||
ProtectKernelLogs = true;
|
||||
ProtectKernelModules = true;
|
||||
ProtectKernelTunables = true;
|
||||
ProtectSystem = "strict";
|
||||
Restart = "always";
|
||||
RestrictAddressFamilies = [
|
||||
"AF_INET"
|
||||
"AF_INET6"
|
||||
];
|
||||
RestrictNamespaces = true;
|
||||
RestrictRealtime = true;
|
||||
RuntimeDirectory = "dnscrypt-proxy";
|
||||
StateDirectory = "dnscrypt-proxy";
|
||||
SystemCallArchitectures = "native";
|
||||
SystemCallFilter = [
|
||||
"@system-service"
|
||||
"@chown"
|
||||
"~@aio"
|
||||
"~@keyring"
|
||||
"~@memlock"
|
||||
"~@setuid"
|
||||
"~@timer"
|
||||
];
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
coredump.enable = false;
|
||||
settings.Manager = {
|
||||
DefaultTimeoutStartSec = "30s";
|
||||
DefaultTimeoutStopSec = "30s";
|
||||
};
|
||||
};
|
||||
|
||||
services = {
|
||||
acpid.enable = true;
|
||||
dbus.enable = true;
|
||||
dbus.implementation = "broker";
|
||||
envfs.enable = true;
|
||||
fstrim.enable = true;
|
||||
fwupd.enable = true;
|
||||
ntp.enable = true;
|
||||
openssh.enable = true;
|
||||
power-profiles-daemon.enable = false;
|
||||
printing.enable = true;
|
||||
userborn.enable = true;
|
||||
|
||||
greetd = {
|
||||
enable = true;
|
||||
settings = {
|
||||
default_session = {
|
||||
command = ''
|
||||
${pkgs.tuigreet}/bin/tuigreet \
|
||||
--time \
|
||||
--remember \
|
||||
--remember-session \
|
||||
--greeting 'Welcome to NixOS' \
|
||||
--cmd sway
|
||||
'';
|
||||
user = "greeter";
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
logind = {
|
||||
powerKey = "suspend";
|
||||
};
|
||||
|
||||
desktopManager = {
|
||||
plasma6.enable = true;
|
||||
};
|
||||
|
||||
pipewire = {
|
||||
enable = true;
|
||||
alsa.enable = true;
|
||||
alsa.support32Bit = true;
|
||||
pulse.enable = true;
|
||||
};
|
||||
|
||||
avahi = {
|
||||
enable = true;
|
||||
nssmdns4 = true;
|
||||
openFirewall = true;
|
||||
};
|
||||
|
||||
libinput.enable = true;
|
||||
xserver = {
|
||||
enable = false;
|
||||
dpi = 144;
|
||||
desktopManager.xterm.enable = false;
|
||||
displayManager = {
|
||||
lightdm.enable = false;
|
||||
startx.enable = true;
|
||||
};
|
||||
windowManager.i3.enable = false;
|
||||
};
|
||||
|
||||
udev = {
|
||||
packages = [
|
||||
pkgs.openhantek6022
|
||||
pkgs.openocd
|
||||
];
|
||||
extraRules = ''
|
||||
#Xilinx FTDI
|
||||
ACTION=="add", ATTR{idVendor}=="0403", ATTR{manufacturer}=="Xilinx", MODE:="666"
|
||||
|
||||
#Xilinx Digilent
|
||||
ATTR{idVendor}=="1443", MODE:="666"
|
||||
ACTION=="add", ATTR{idVendor}=="0403", ATTR{manufacturer}=="Digilent", MODE:="666"
|
||||
|
||||
#Arduino UNO r4
|
||||
SUBSYSTEMS=="usb", ATTRS{idVendor}=="2341", MODE:="0666"
|
||||
|
||||
#zremap on new keyboard
|
||||
ACTION=="add", SUBSYSTEM=="input", ATTRS{phys}!="", KERNEL=="event[0-9]*", ENV{ID_INPUT_KEY}=="1", ENV{ID_INPUT_KEYBOARD}=="1", TAG+="systemd", ENV{SYSTEMD_WANTS}+="zremap@$env{DEVNAME}.service"
|
||||
'';
|
||||
};
|
||||
|
||||
tlp = {
|
||||
enable = true;
|
||||
settings = {
|
||||
START_CHARGE_THRESH_BAT0 = 70;
|
||||
STOP_CHARGE_THRESH_BAT0 = 94;
|
||||
#CPU_SCALING_GOVERNOR_ON_AC = "performance";
|
||||
#CPU_SCALING_GOVERNOR_ON_BAT = "powersave";
|
||||
|
||||
# For your Fujitsu U9313X - Intel 13th gen
|
||||
#CPU_ENERGY_PERF_POLICY_ON_AC = "performance";
|
||||
#CPU_ENERGY_PERF_POLICY_ON_BAT = "balance_power";
|
||||
CPU_SCALING_MAX_FREQ_ON_AC = 4700000;
|
||||
CPU_SCALING_MAX_FREQ_ON_BAT = 3000000;
|
||||
CPU_SCALING_MIN_FREQ_ON_AC = 400000;
|
||||
CPU_SCALING_MIN_FREQ_ON_BAT = 400000;
|
||||
|
||||
# Optional: CPU boost control
|
||||
CPU_BOOST_ON_AC = 1;
|
||||
CPU_BOOST_ON_BAT = 0;
|
||||
|
||||
};
|
||||
};
|
||||
|
||||
batteryNotifier = {
|
||||
enable = true;
|
||||
notifyCapacity = 12;
|
||||
suspendCapacity = 5;
|
||||
};
|
||||
|
||||
actkbd = {
|
||||
enable = true;
|
||||
bindings = [
|
||||
{
|
||||
keys = [ 115 ];
|
||||
events = [ "key" ];
|
||||
command = "XDG_RUNTIME_DIR=/run/user/$(id -u ${USER}) ${pkgs.wireplumber}/bin/wpctl set-volume @DEFAULT_AUDIO_SINK@ 5%+";
|
||||
}
|
||||
|
||||
{
|
||||
keys = [ 114 ];
|
||||
events = [
|
||||
"key"
|
||||
"rep"
|
||||
];
|
||||
command = "XDG_RUNTIME_DIR=/run/user/$(id -u ${USER}) ${pkgs.wireplumber}/bin/wpctl set-volume @DEFAULT_AUDIO_SINK@ 5%-";
|
||||
}
|
||||
|
||||
{
|
||||
keys = [ 113 ];
|
||||
events = [
|
||||
"key"
|
||||
"rep"
|
||||
];
|
||||
command = "XDG_RUNTIME_DIR=/run/user/$(id -u ${USER}) ${pkgs.wireplumber}/bin/wpctl set-mute @DEFAULT_AUDIO_SINK@ toggle";
|
||||
}
|
||||
|
||||
{
|
||||
keys = [ 224 ];
|
||||
events = [ "key" ];
|
||||
command = "${pkgs.light}/bin/light -U 5";
|
||||
}
|
||||
|
||||
{
|
||||
keys = [ 225 ];
|
||||
events = [ "key" ];
|
||||
command = "${pkgs.light}/bin/light -A 5";
|
||||
}
|
||||
];
|
||||
};
|
||||
|
||||
dnscrypt-proxy = {
|
||||
enable = true;
|
||||
settings = {
|
||||
ipv6_servers = true;
|
||||
require_dnssec = true;
|
||||
require_nolog = true;
|
||||
require_nofilter = true;
|
||||
http3 = true;
|
||||
|
||||
sources.public-resolvers = {
|
||||
urls = [
|
||||
"https://raw.githubusercontent.com/DNSCrypt/dnscrypt-resolvers/master/v3/public-resolvers.md"
|
||||
"https://download.dnscrypt.info/resolvers-list/v3/public-resolvers.md"
|
||||
];
|
||||
cache_file = "/var/lib/dnscrypt-proxy/public-resolvers.md";
|
||||
minisign_key = "RWQf6LRCGA9i53mlYecO4IzT51TGPpvWucNSCh1CBM0QTaLn73Y7GFO3";
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
borgbackup.jobs."borgbase" =
|
||||
let
|
||||
user = config.users.users.${USER};
|
||||
home = user.home;
|
||||
in
|
||||
{
|
||||
user = user.name;
|
||||
paths = [
|
||||
(home + "/pic/priv")
|
||||
(home + "/pproj")
|
||||
(home + "/videos/priv")
|
||||
];
|
||||
exclude = [
|
||||
"**/.ccls_cache"
|
||||
"**/*.d"
|
||||
"**/*.map"
|
||||
"**/*.o"
|
||||
"**/zig-cache"
|
||||
"**/zig-out"
|
||||
];
|
||||
repo = "ssh://oda929rv@oda929rv.repo.borgbase.com/./repo";
|
||||
encryption = {
|
||||
mode = "repokey-blake2";
|
||||
passCommand = "${pkgs.coreutils-full}/bin/cat ${config.sops.secrets."borgbase_enc_key".path}";
|
||||
};
|
||||
environment.BORG_RSH = "${pkgs.openssh}/bin/ssh -i ${config.sops.secrets."borgbase_ssh_key".path}";
|
||||
compression = "auto,zstd";
|
||||
startAt = "daily";
|
||||
};
|
||||
|
||||
nix-serve = {
|
||||
enable = false;
|
||||
secretKeyFile = "/var/cache-priv-key.pem";
|
||||
};
|
||||
|
||||
journald.extraConfig = ''
|
||||
SystemMaxUse=50M
|
||||
'';
|
||||
|
||||
logind.settings.Login = {
|
||||
KillUserProcesses = true;
|
||||
};
|
||||
|
||||
};
|
||||
|
||||
fonts = {
|
||||
fontconfig = {
|
||||
cache32Bit = true;
|
||||
allowBitmaps = true;
|
||||
useEmbeddedBitmaps = true;
|
||||
defaultFonts = {
|
||||
monospace = [ "JetBrainsMono" ];
|
||||
};
|
||||
};
|
||||
|
||||
packages = with pkgs; [
|
||||
dejavu_fonts
|
||||
dina-font
|
||||
fira-code
|
||||
fira-code-symbols
|
||||
font-awesome_6
|
||||
inconsolata
|
||||
iosevka
|
||||
jetbrains-mono
|
||||
liberation_ttf
|
||||
libertine
|
||||
noto-fonts
|
||||
noto-fonts-cjk-sans
|
||||
noto-fonts-color-emoji
|
||||
proggyfonts
|
||||
siji
|
||||
terminus_font
|
||||
terminus_font_ttf
|
||||
ubuntu-classic
|
||||
vista-fonts
|
||||
];
|
||||
};
|
||||
|
||||
virtualisation = {
|
||||
waydroid.enable = false;
|
||||
libvirtd = {
|
||||
enable = true;
|
||||
allowedBridges = [
|
||||
"virbr0"
|
||||
"br0"
|
||||
];
|
||||
};
|
||||
spiceUSBRedirection.enable = true;
|
||||
containers.storage.settings = {
|
||||
storage = {
|
||||
graphroot = "/var/lib/containers/storage";
|
||||
runroot = "/run/containers/storage";
|
||||
};
|
||||
};
|
||||
podman = {
|
||||
enable = true;
|
||||
autoPrune.enable = true;
|
||||
dockerCompat = true;
|
||||
};
|
||||
};
|
||||
|
||||
hardware = {
|
||||
bluetooth = {
|
||||
enable = true;
|
||||
settings = {
|
||||
General = {
|
||||
Experimental = true;
|
||||
Enable = "Source,Sink,Media,Socket";
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
graphics = {
|
||||
enable = true;
|
||||
extraPackages = with pkgs; [ intel-media-driver ];
|
||||
};
|
||||
|
||||
rtl-sdr.enable = true;
|
||||
firmware = [ pkgs.sof-firmware ];
|
||||
sensor.iio.enable = true;
|
||||
};
|
||||
|
||||
zramSwap = {
|
||||
enable = true;
|
||||
algorithm = "zstd";
|
||||
};
|
||||
|
||||
users.users.${USER} = {
|
||||
isNormalUser = true;
|
||||
initialHashedPassword = "$y$j9T$FZnEcCEMIC0Fjj4dZi5t8.$D8ygvO19dR5nyTZxWwDgjEimHutD.sKnD1DLAyhU8.B";
|
||||
shell = pkgs.zsh;
|
||||
extraGroups = [
|
||||
"adbusers"
|
||||
"audio"
|
||||
"dialout"
|
||||
"input"
|
||||
"kvm"
|
||||
"plugdev"
|
||||
"sound"
|
||||
"tty"
|
||||
"wheel"
|
||||
"wireshark"
|
||||
];
|
||||
};
|
||||
}
|
||||
@@ -1,45 +0,0 @@
|
||||
# Do not modify this file! It was generated by ‘nixos-generate-config’
|
||||
# and may be overwritten by future invocations. Please make changes
|
||||
# to /etc/nixos/configuration.nix instead.
|
||||
{ config, lib, pkgs, modulesPath, ... }:
|
||||
|
||||
{
|
||||
imports =
|
||||
[
|
||||
(modulesPath + "/installer/scan/not-detected.nix")
|
||||
];
|
||||
|
||||
boot.initrd.availableKernelModules = [ "xhci_pci" "ehci_pci" "thunderbolt" "nvme" "uas" "usb_storage" "sd_mod" "rtsx_pci_sdmmc" ];
|
||||
|
||||
boot.initrd.luks.devices."cryptroot".device = "/dev/disk/by-uuid/8a06d0e9-d765-49e8-a729-4d84c2638d56";
|
||||
|
||||
boot.initrd.kernelModules = [ "dm-snapshot" ];
|
||||
boot.kernelModules = [ "kvm-intel" "fujitsu_laptop" "xe" "snd_soc_sof_sdw" ];
|
||||
boot.extraModulePackages = [ ];
|
||||
|
||||
fileSystems."/" =
|
||||
{
|
||||
device = "/dev/mapper/fuji_lvm_root-root";
|
||||
fsType = "xfs";
|
||||
};
|
||||
|
||||
fileSystems."/home" =
|
||||
{
|
||||
device = "/dev/mapper/fuji_lvm_root-home";
|
||||
fsType = "xfs";
|
||||
};
|
||||
|
||||
fileSystems."/boot" =
|
||||
{
|
||||
device = "/dev/disk/by-uuid/83F9-733B";
|
||||
fsType = "vfat";
|
||||
options = [ "fmask=0022" "dmask=0022" ];
|
||||
};
|
||||
|
||||
swapDevices = [ ];
|
||||
|
||||
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
|
||||
hardware.sensor.iio.enable = lib.mkDefault true;
|
||||
hardware.enableRedistributableFirmware = true;
|
||||
hardware.cpu.intel.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
|
||||
}
|
||||
@@ -1 +0,0 @@
|
||||
peerix-nixy:8THqS0R2zWF/47ai0RFmqJnieYTZ1jaWOD9tnzpvA6s=
|
||||
@@ -1,21 +0,0 @@
|
||||
borgbase_enc_key: ENC[AES256_GCM,data:AD+JghEOX25tBGYhoU1ge1fqrA+5AK8N4yg=,iv:u05GVeWbL3xdZQgGkXSPkxlATd2M9MX4uSZiLOHMMRE=,tag:pmTQIJWmz+ePmSNzO/EO4Q==,type:str]
|
||||
sops:
|
||||
kms: []
|
||||
gcp_kms: []
|
||||
azure_kv: []
|
||||
hc_vault: []
|
||||
age:
|
||||
- recipient: age1geqqmsnng2e9sja6uxxmtlwlm4c6e5v6ch3l3yjenstq6tjq4fusr0305s
|
||||
enc: |
|
||||
-----BEGIN AGE ENCRYPTED FILE-----
|
||||
YWdlLWVuY3J5cHRpb24ub3JnL3YxCi0+IFgyNTUxOSBEaDhSZVVibVl1NU84NG9U
|
||||
aEVQbThIcC9CajNHS25SVW1SMFFwMUsvMmxJCkpTVThpZ0JZdEpLTnJlQWFqM244
|
||||
LzFaUFVvWWxIcU4wRlhXalF5TkNpVHMKLS0tIExXMUx5cDBBbDloQ0sxbEY0eGdj
|
||||
bE5vNHVHekI2RzY5M3JNcTdCa3pNeUUK8C04wF1te6epA97sNrhoz0VUn+MC7SML
|
||||
6N1CZK3MuRARBqcj4c/W1aXuTysvuV1o/Fl5xOk/gbumcfwnDYj28A==
|
||||
-----END AGE ENCRYPTED FILE-----
|
||||
lastmodified: "2024-04-21T08:14:25Z"
|
||||
mac: ENC[AES256_GCM,data:7M+akGH09E2JYyKLmwpjx0VCEBmXqO6bNHFNRCO+9LdSIqsEw8MD4WGO0zwHOD9ls7+1OPFeoU+MVbtfMhmvN4g6rg+tFkXbxPSXCPkTA4tL90ZLXoBIpUBxKKhFMxtdOnjXxES3rTzjXGAvxocFOiNv/7pKbzeqMJUnH9FgAcM=,iv:h0+OpLmutMyPN3YFhyuHFgWSqxVK5WmBAE0k5ezEo9A=,tag:UKOXnTOjWaLDEOYk5YK4Aw==,type:str]
|
||||
pgp: []
|
||||
unencrypted_suffix: _unencrypted
|
||||
version: 3.8.1
|
||||
@@ -1,21 +0,0 @@
|
||||
borgbase_ssh_key: ENC[AES256_GCM,data:lLHIBmw/03An3SRJUjYS2pn0g7XEW0kTXtSObhIGwjBwlRypU7uQDz4JseOA2GbSm+GqsGK8U3Ifgirb7t8AsGy6DPxO+2sm+ByJ1S46G6cwkO2GateJw4Zg0mmhUBBuB/eXQMLuBLKZM2WGta5+6O0SWxDtsrTsBhlo5qbwwYILu0gg2zsBWFSn1OBGgvjYYRTd7N85WX8+S7oNYVAL2HjCmhHHtYrLnua4ajBY9dQEzrKdZaQW4v39HV9MyoilEz17fFLU8S2KbJ1iw8HgoAc9W81hpQNNd8fWKY+e0iWxD9X5H7UTs8YP/bsKeWyG4OAwr99zIZ1Lqzi0EuZI+PYkIz4Q4WBmv1wD6Py274iug3kr1OqvaIOmIT/9j2C3mOZTqxuFaF5T4NMkcIeViCBmRwUMTl/8a36X+n/MYxRoznHCQmg8zKubDuykVJfBmFwxbUc9tx8PeodnWeiASOV7FvBie47yq+NyBGItJXAK14SxLE9T2sxRchJWcrQBcekZdZ5Mej20lfUlcAGkwfUc0e54xsv1K3oY,iv:5157BQmbfuF5EYbDHCy/TmnTYErIwmgXO8RaX6f18xs=,tag:T2eZN46Qd6RgLWk4kbYgPQ==,type:str]
|
||||
sops:
|
||||
kms: []
|
||||
gcp_kms: []
|
||||
azure_kv: []
|
||||
hc_vault: []
|
||||
age:
|
||||
- recipient: age1geqqmsnng2e9sja6uxxmtlwlm4c6e5v6ch3l3yjenstq6tjq4fusr0305s
|
||||
enc: |
|
||||
-----BEGIN AGE ENCRYPTED FILE-----
|
||||
YWdlLWVuY3J5cHRpb24ub3JnL3YxCi0+IFgyNTUxOSB5b2YzSDdaU3R5TUdqS3Nv
|
||||
eUYraFBiZlZ1TXBqYzlWNUNYOFlyMzJvWEE4ClJ6R25CRXRUZ2FDTFY2ZmJIRkRX
|
||||
WVJCSy83N2JUNzRuT3VuSUF1OTV2TUkKLS0tIEZ5cVg1V2o0MkdmWEx1emJVdjZ0
|
||||
RkZFL2tRNW9RdnAwalE2ZzVQcnljRFUKRyN8ahv9ZI63m8ycl74GZ59lyAXUsKmi
|
||||
tfPqQvL1oTtJr3hzwy2bkctXQLYjGvsMyZt2tiWpy5vLc1MrxlqVDQ==
|
||||
-----END AGE ENCRYPTED FILE-----
|
||||
lastmodified: "2024-04-21T08:16:40Z"
|
||||
mac: ENC[AES256_GCM,data:VkXpCPQB4RypDrK31pYWXeOcl8ulis6fMF1q/SLCg2wXnL0jFrmAFp78C+ers9xFhbnUnMbVc/ZJIVKfa0g94WV3jJbn4+HB0GPWQCz7LwhmG5XEY5O5sFLuDCcHb/epZvDbCsEQeiq+TGDHp6TtdL8qDF+hE2k8qfsy570wocU=,iv:HQleJtHWQ5uk4+Witn2aaqh0SvXqomfiSO/ExgPzVag=,tag:hlBmboddR8GDAmBpETi0Ow==,type:str]
|
||||
pgp: []
|
||||
unencrypted_suffix: _unencrypted
|
||||
version: 3.8.1
|
||||
@@ -1,22 +0,0 @@
|
||||
peerix:
|
||||
private: ENC[AES256_GCM,data:Oi8H5nqJ0Bf45wQepCjdZNHBOv4AlPxNN7L5Th3gcRQlW1FS77nusIWGSUvlmL2a5LTN0FV36o2GFPrrhiwmvnkQwuSZKc9VeDTf7SX0RRL1NLmRR/zy4WsRNJFxlqtjahieqg==,iv:6hJwqcdPayZaYZhJ0OfYLAtmeVndLEfeYZjUq5/3qJE=,tag:MiAfg8aZAHNYbB0JwcdStg==,type:str]
|
||||
sops:
|
||||
kms: []
|
||||
gcp_kms: []
|
||||
azure_kv: []
|
||||
hc_vault: []
|
||||
age:
|
||||
- recipient: age1geqqmsnng2e9sja6uxxmtlwlm4c6e5v6ch3l3yjenstq6tjq4fusr0305s
|
||||
enc: |
|
||||
-----BEGIN AGE ENCRYPTED FILE-----
|
||||
YWdlLWVuY3J5cHRpb24ub3JnL3YxCi0+IFgyNTUxOSBSMEIyck1xbVJ4Zm56Z3dM
|
||||
OGsxa1p0TGIvRE5DYXZzTDM3YUZFVTAxbUUwCllPd0FOUlRiZW5wT2QvLzZXYjRr
|
||||
S1A5WjZxLzNYQ1ZWVFFQTzRwMFQweFEKLS0tIHNoZUpHS2dDNmFKc3ZVNFZuUFU4
|
||||
L0M0MitMeDg1ZWYxcDNCQlVGUjRKeFkKvD2SKnuh517o2knPr2SOWq3kubMyI7UV
|
||||
j6HgXVbHUDjmKl2dY+YVTnmxrK54E+Q6iiu7mQnvLdzxYBK/EiNt9w==
|
||||
-----END AGE ENCRYPTED FILE-----
|
||||
lastmodified: "2024-04-21T08:17:51Z"
|
||||
mac: ENC[AES256_GCM,data:v4KQq3Y5ZxsyMxR+FS1BZkH/bPTIIHfQu800U44odaNycIbWnuwCnLWGyJK6Por76bWALycGppDbHPKKW/N1I1XLy/EAXo02+nhHNvKVi2cXSXciuEPc/Cl+6TbP39lx4+EOM8CZoNZ8HAiS3QPy2bwZdMjEw/OHl8TqlN07q9s=,iv:PIcv/b6t+54/yCTZj+12Yep15ors/wXNUnaXjLjpVbM=,tag:JxO5M3OYaWzqgf4gUhCzzg==,type:str]
|
||||
pgp: []
|
||||
unencrypted_suffix: _unencrypted
|
||||
version: 3.8.1
|
||||
@@ -1,21 +0,0 @@
|
||||
wg_preshared: ENC[AES256_GCM,data:k+aFYDNMojf5kktn6KJ4F5mH5oGdqxdF0MO88NcYpai9USnH394XRL9ASvs=,iv:L5LIXbADhrivKjK/V0E5QpRT7BDsktwIuKHgY+2qr84=,tag:pCW1naU/ygxAIDYWV2hHPQ==,type:str]
|
||||
sops:
|
||||
kms: []
|
||||
gcp_kms: []
|
||||
azure_kv: []
|
||||
hc_vault: []
|
||||
age:
|
||||
- recipient: age1geqqmsnng2e9sja6uxxmtlwlm4c6e5v6ch3l3yjenstq6tjq4fusr0305s
|
||||
enc: |
|
||||
-----BEGIN AGE ENCRYPTED FILE-----
|
||||
YWdlLWVuY3J5cHRpb24ub3JnL3YxCi0+IFgyNTUxOSBZSHZvYy9TTmVEb2ZSTncy
|
||||
ckJ1bXZGWVdJSkVHMGx2Vk5ZNlZ3Q2wzVFQ0Cmg1M3hKNFhnZk5nTE54RTdyR0Vs
|
||||
NVRiTEltSnkxdmhhdGlycHNPWjFLbncKLS0tIE02NVJRZTd0VmowT1c4cjhKNlZk
|
||||
Q01BQWNSVWtIMnFXRWpxR3JDMU8zYTAKIbfpM8uUb09cUlA8YWtgEOL5zvWf5omv
|
||||
baZINiAu0/f1avYmW6Qb+aLa2ALrSZaotj46Uwd9Lb5mtjJ/8v9IOg==
|
||||
-----END AGE ENCRYPTED FILE-----
|
||||
lastmodified: "2024-04-20T18:12:20Z"
|
||||
mac: ENC[AES256_GCM,data:4PWjwxOO0UuNsevCbzCLaiW7C+So4mEGivd9GzyLKx2JlkNFVB8wqPrY1Rl1ANMrT+7LKc8tVOA4zbweNc9idFG4y5DcvnDSieqKu9v1MeEMHqNpz5TTLbCP81g7qegjI/WKul2kaWIdPaioI/f5x2E6rEYnzFv+Di2mc3W+Qcc=,iv:iE9sali0O3sQIhOw30RGR/4ZQsAPcSxq1qxosfasojU=,tag:+9AOwph5A4oDXsK6Z3YeZA==,type:str]
|
||||
pgp: []
|
||||
unencrypted_suffix: _unencrypted
|
||||
version: 3.8.1
|
||||
@@ -1,21 +0,0 @@
|
||||
wg_privkey: ENC[AES256_GCM,data:XL9FU1kZXvBJfwyt3HpQe8k8zg9HT6Xm0BdjNMduSu9uAgcHbglpLc/qTB0=,iv:QgX1VsmLUsDozFXmzDVPukjPNTa4Lnh806AQ4qdgpa8=,tag:RNVlDbtx8vAAbG0rinLVOw==,type:str]
|
||||
sops:
|
||||
kms: []
|
||||
gcp_kms: []
|
||||
azure_kv: []
|
||||
hc_vault: []
|
||||
age:
|
||||
- recipient: age1geqqmsnng2e9sja6uxxmtlwlm4c6e5v6ch3l3yjenstq6tjq4fusr0305s
|
||||
enc: |
|
||||
-----BEGIN AGE ENCRYPTED FILE-----
|
||||
YWdlLWVuY3J5cHRpb24ub3JnL3YxCi0+IFgyNTUxOSBBSnkyM1ZrcnEvM3VHL0Nk
|
||||
THhUUDdGU2s5UFgrVGZ3WXhkYTRIVTlaeGs4CjR4eVpmRy9qUkZSWkpFZDZHRDZI
|
||||
ZWRXSmMzL2RWZkVrSlFPcC9ueGpDVFkKLS0tIDZWbENyS2hrSCtlNlBHaE56QTha
|
||||
eFJmWXk1SVJEbDJOc1Q1VFlzVS8yODgKFXRAtR+67x0dkQTqZPtMT0Hd+aW+5K17
|
||||
S/lhuHRhITt3woQnecVPMYklgJJlsyQ6blKhJw8dvhbVWWThZ853rQ==
|
||||
-----END AGE ENCRYPTED FILE-----
|
||||
lastmodified: "2024-04-21T08:18:59Z"
|
||||
mac: ENC[AES256_GCM,data:xPKsGZD5RKT/WMRupe4YTgoiUQRFq77KQyGaazeY1GEPI117gWxRHEpiyCLnfhZWcaekPWoXosm32wRLwDAXM/Femk567i5uKKG2wAqApWbc+FXTQ71w/CFr9uEWFApBjpEHpuBBaFV23qJfylsqeMp9r52d9Sp5eDQC4RJead0=,iv:oiNoZ/bqQUe+luqeuldw1M0KB2d4C5T7kXy+mLFZNZQ=,tag:5pK22TYGwbBNyWlfd/Ufxw==,type:str]
|
||||
pgp: []
|
||||
unencrypted_suffix: _unencrypted
|
||||
version: 3.8.1
|
||||
@@ -1,22 +0,0 @@
|
||||
wg_privkey_proton: ENC[AES256_GCM,data:qVVd+1s2T3sKDi03V+eMvgqW8LAVl/yEKwtG2EMn8NhBCN7RvlttC5SeIDM=,iv:/QcrtmMjCzZRulumIz5u9oxyaRt+HUq96ZiP8ecpvAo=,tag:1DCaJqVGfg3sfvKTQnmzZA==,type:str]
|
||||
wg_endpoint_proton: ENC[AES256_GCM,data:ggoWnB6nGjGc/kSOaCo=,iv:1r5J6SO5JYH7+bMhE2lGwfFETVFeS61eCXtej0Pl07M=,tag:p+0hhQ/vqZzZML24YReA0g==,type:str]
|
||||
sops:
|
||||
kms: []
|
||||
gcp_kms: []
|
||||
azure_kv: []
|
||||
hc_vault: []
|
||||
age:
|
||||
- recipient: age1geqqmsnng2e9sja6uxxmtlwlm4c6e5v6ch3l3yjenstq6tjq4fusr0305s
|
||||
enc: |
|
||||
-----BEGIN AGE ENCRYPTED FILE-----
|
||||
YWdlLWVuY3J5cHRpb24ub3JnL3YxCi0+IFgyNTUxOSAxdXZpL1lrOEYyYVdFTzNJ
|
||||
SHhXRVc5Y0o4ZzN2THRjM215UWczVjZOTXg4CjBJZ2VxN0t0ZFgzTmJMeXo5SWZk
|
||||
UjRlNmdRTVVPbHVEeXM3TWhoS0pSUTQKLS0tIEtkTURBc1A3d2lTalhmeEoxUkZj
|
||||
K3BHZnUzN3ZrL1dFQk8rWFpZR05pbFUKObrnIpY3NR1o3/lKhTfVpQU+eQRTi7wF
|
||||
SAjGZ5BRdCi5x1VWRxiT1Fvjqkm7kBEQFvdSvbqW2UK6lVHtWgt2Vg==
|
||||
-----END AGE ENCRYPTED FILE-----
|
||||
lastmodified: "2024-05-12T13:30:18Z"
|
||||
mac: ENC[AES256_GCM,data:3UqJGcNGPZDlLA3a0uNHUI0ykDC0ByxAR2ZsrsbWQMv3BS6zyBuc+zpTHQZoIPGsAMUetuB3OuA0IQNll3abg6u2AadEQBUf1PYMWlo58txLYlAs/q0g+575F+LhDSgmDMKOFXz4HqbFP0RYTHkPnmjWPMWWY3G9o6B3Iaw5+Kc=,iv:massJRpGcH4pDZxJrpQYy80XVViyw+qFsZ8Sk9Xze08=,tag:eDvuNadKGKBS/3jauvnuFQ==,type:str]
|
||||
pgp: []
|
||||
unencrypted_suffix: _unencrypted
|
||||
version: 3.8.1
|
||||
@@ -1 +0,0 @@
|
||||
ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIMPNCxE/8z02lVOC1unJbPMH+Ma+KRJfmz33oUfz3hKc root@nixy
|
||||
@@ -1 +0,0 @@
|
||||
oHVmhw80daHjDjo7nwt/Y9eKBaH5FoTiVeukwDObijM=
|
||||
@@ -1 +0,0 @@
|
||||
eoYSDh27qQFpvOcDmuVFzSTuPnrHQYXDMqatKmDAth0=
|
||||
@@ -1,120 +0,0 @@
|
||||
{ pkgs, lib, ... }:
|
||||
{
|
||||
home.sessionVariables = {
|
||||
/*ZDOTDIR = "\"$HOME/\".config/zsh";*/
|
||||
/*HISTFILE = "\"$XDG_STATE_HOME\"/zsh/history";*/
|
||||
};
|
||||
|
||||
programs.z-lua = {
|
||||
enableAliases = true;
|
||||
enableZshIntegration = true;
|
||||
};
|
||||
|
||||
programs.zsh = {
|
||||
autocd = true;
|
||||
enableCompletion = false;
|
||||
defaultKeymap = "viins";
|
||||
/* dotDir = "\"$XDG_CONFIG_HOME\"/zsh"; */
|
||||
|
||||
setOptions = [
|
||||
"c_bases"
|
||||
"completealiases"
|
||||
"completeinword"
|
||||
"nobeep"
|
||||
"nopromptcr"
|
||||
"notify"
|
||||
];
|
||||
|
||||
shellAliases = {
|
||||
cfind = "${pkgs.cscope}/bin/cscope -C -R -L1";
|
||||
chmod = "chmod -v";
|
||||
chown = "chown -v";
|
||||
cp = "cp -v";
|
||||
rm = "rm -v";
|
||||
ip = "ip --color=auto";
|
||||
f = "''$(${lib.getExe pkgs.pay-respects} zsh)";
|
||||
};
|
||||
|
||||
history = {
|
||||
expireDuplicatesFirst = true;
|
||||
extended = true;
|
||||
save = 100000;
|
||||
size = 100000;
|
||||
};
|
||||
|
||||
plugins = [
|
||||
{
|
||||
name = "nix_shell";
|
||||
src = pkgs.zsh-nix-shell;
|
||||
file = "share/zsh-nix-shell/nix-shell.plugin.zsh";
|
||||
}
|
||||
{
|
||||
name = "nix_completion";
|
||||
src = pkgs.nix-zsh-completions;
|
||||
file = "share/zsh/plugins/nix/nix-zsh-completions.plugin.zsh";
|
||||
}
|
||||
{
|
||||
name = "pure_prompt";
|
||||
src = pkgs.fetchFromGitHub {
|
||||
owner = "sindresorhus";
|
||||
repo = "pure";
|
||||
rev = "54bd501c802283dee0940457da6eb3e642bd1453";
|
||||
hash = "sha256-AZSxP2g6BWoxyiSQH7yzbbbfGcwD8jgnXPPfcYwJUL0=";
|
||||
};
|
||||
file = "pure.plugin.zsh";
|
||||
}
|
||||
{
|
||||
name = "fzf";
|
||||
src = pkgs.fzf-zsh;
|
||||
file = "share/zsh/plugins/fzf-zsh/fzf-zsh.plugin.zsh";
|
||||
}
|
||||
{
|
||||
name = "zsh-sudo";
|
||||
src = pkgs.oh-my-zsh;
|
||||
file = "share/oh-my-zsh/plugins/sudo/sudo.plugin.zsh";
|
||||
}
|
||||
{
|
||||
name = "zsh-fast-syntax-highlighting";
|
||||
src = pkgs.zsh-fast-syntax-highlighting;
|
||||
file = "share/zsh/plugins/fast-syntax-highlighting/fast-syntax-highlighting.plugin.zsh";
|
||||
}
|
||||
];
|
||||
|
||||
envExtra = '''';
|
||||
|
||||
initContent = ''
|
||||
# binds
|
||||
bindkey '^K' fzf-file-widget
|
||||
|
||||
RPS1=""
|
||||
|
||||
function chpwd() {
|
||||
ls;
|
||||
}
|
||||
|
||||
function osc7-pwd() {
|
||||
emulate -L zsh # also sets localoptions for us
|
||||
setopt extendedglob
|
||||
local LC_ALL=C
|
||||
printf '\e]7;file://%s%s\e\' $HOST ''${PWD//(#m)([^@-Za-z&-;_~])/%''${(l:2::0:)''$(([##16]#MATCH))}}
|
||||
}
|
||||
|
||||
function chpwd-osc7-pwd() {
|
||||
(( ZSH_SUBSHELL )) || osc7-pwd
|
||||
}
|
||||
add-zsh-hook -Uz chpwd chpwd-osc7-pwd
|
||||
|
||||
eval "$(direnv hook zsh)"
|
||||
zstyle ':completion:*' matcher-list 'm:{a-z}={A-Za-z}'
|
||||
|
||||
if [[ -n "$PS1" ]] && [[ -z "$TMUX" ]] && [[ -n "$SSH_CONNECTION" ]]; then
|
||||
TMUX_EXE="${lib.getExe pkgs.tmux}"
|
||||
systemd-run --scope --user $TMUX_EXE attach-session -t $USER || systemd-run --scope --user $TMUX_EXE new-session -s $USER
|
||||
fi
|
||||
|
||||
if [[ -n "$BUBBLEWRAP_DIR" ]]; then
|
||||
RPS1="{{$BUBBLEWRAP_DIR}}"
|
||||
fi
|
||||
'';
|
||||
};
|
||||
}
|
||||
@@ -1,375 +0,0 @@
|
||||
{ lib
|
||||
, pkgs
|
||||
, ...
|
||||
}:
|
||||
let
|
||||
qutebrowser_firejail = pkgs.writeShellScriptBin "qutebrowser" ''
|
||||
firejail -- ${lib.getExe pkgs.qutebrowser} "$@"
|
||||
'';
|
||||
in
|
||||
{
|
||||
imports = [
|
||||
../common/zsh.nix
|
||||
../common/i3status-rust.nix
|
||||
../common/sway.nix
|
||||
../common/i3.nix
|
||||
./home_packages.nix
|
||||
../common/whatsapp-for-linux.nix
|
||||
];
|
||||
|
||||
home.stateVersion = "22.11";
|
||||
home.username = "akill";
|
||||
home.homeDirectory = "/home/akill";
|
||||
|
||||
xdg.enable = true;
|
||||
xdg.mimeApps = {
|
||||
enable = true;
|
||||
defaultApplications = {
|
||||
"application/pdf" = "zathura.desktop";
|
||||
"default-web-browser" = "org.qutebrowser.qutebrowser.desktop";
|
||||
"text/html" = "org.qutebrowser.qutebrowser.desktop";
|
||||
"x-scheme-handler/about" = "org.qutebrowser.qutebrowser.desktop";
|
||||
"x-scheme-handler/http" = "org.qutebrowser.qutebrowser.desktop";
|
||||
"x-scheme-handler/https" = "org.qutebrowser.qutebrowser.desktop";
|
||||
"x-scheme-handler/unknown" = "org.qutebrowser.qutebrowser.desktop";
|
||||
};
|
||||
};
|
||||
|
||||
fonts.fontconfig.enable = true;
|
||||
|
||||
home.sessionVariables = rec {
|
||||
BROWSER = lib.getExe qutebrowser_firejail;
|
||||
DEFAULT_BROWSER = "${BROWSER}";
|
||||
EDITOR = "nvim";
|
||||
_JAVA_AWT_WM_NONREPARENTING = "1";
|
||||
MOZ_ENABLE_WAYLAND = "1";
|
||||
NIXOS_OZONE_WL = "1";
|
||||
QT_WAYLAND_DISABLE_WINDOWDECORATION = "1";
|
||||
SUDO_EDITOR = "nvim";
|
||||
WLR_RENDERER = "vulkan";
|
||||
};
|
||||
|
||||
home.pointerCursor = {
|
||||
package = pkgs.adwaita-icon-theme;
|
||||
name = "Adwaita";
|
||||
size = 38;
|
||||
};
|
||||
|
||||
wayland.windowManager = {
|
||||
sway.enable = true;
|
||||
hyprland.enable = false;
|
||||
};
|
||||
|
||||
programs = {
|
||||
home-manager.enable = true;
|
||||
|
||||
librewolf = {
|
||||
enable = true;
|
||||
settings = {
|
||||
"webgl.disable" = true;
|
||||
"middlemouse.paste" = false;
|
||||
};
|
||||
};
|
||||
|
||||
tmux = {
|
||||
enable = true;
|
||||
clock24 = true;
|
||||
keyMode = "vi";
|
||||
terminal = "screen-256color";
|
||||
plugins = with pkgs.tmuxPlugins; [
|
||||
sysstat
|
||||
net-speed
|
||||
gruvbox
|
||||
];
|
||||
};
|
||||
|
||||
mpv = {
|
||||
enable = true;
|
||||
scripts = [
|
||||
pkgs.mpvScripts.uosc
|
||||
pkgs.mpvScripts.autosubsync-mpv
|
||||
];
|
||||
config = {
|
||||
osc = "no";
|
||||
osd-bar = "no";
|
||||
border = "no";
|
||||
slang = "eng,en";
|
||||
alang = "eng,en";
|
||||
hwdec = "auto";
|
||||
vo = "dmabuf-wayland";
|
||||
ao = "pipewire";
|
||||
ytdl-format = "bestvideo[height<=1080]+bestaudio/best[height<=1080]";
|
||||
};
|
||||
|
||||
bindings = {
|
||||
"s" = "script-binding uosc/subtitles";
|
||||
"a" = "script-binding uosc/audio";
|
||||
WHEEL_UP = "ignore";
|
||||
WHEEL_DOWN = "ignore";
|
||||
WHEEL_LEFT = "ignore";
|
||||
WHEEL_RIGHT = "ignore";
|
||||
};
|
||||
};
|
||||
|
||||
alacritty = {
|
||||
enable = true;
|
||||
|
||||
settings = {
|
||||
font = {
|
||||
normal.family = "JetBrainsMono";
|
||||
italic.family = "JetBrainsMono";
|
||||
bold.family = "JetBrainsMono";
|
||||
bold_italic.family = "JetBrainsMono";
|
||||
size = 14.0;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
rofi = {
|
||||
enable = true;
|
||||
theme = "gruvbox-dark";
|
||||
};
|
||||
|
||||
foot = {
|
||||
enable = true;
|
||||
server.enable = true;
|
||||
settings = {
|
||||
main = {
|
||||
font = "JetBrainsMono:size=10";
|
||||
dpi-aware = "yes";
|
||||
};
|
||||
mouse = {
|
||||
hide-when-typing = "yes";
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
qutebrowser = {
|
||||
enable = true;
|
||||
keyBindings = {
|
||||
normal = {
|
||||
"j" = "scroll-px 0 25";
|
||||
"k" = "scroll-px 0 -25";
|
||||
"u" = "undo --window";
|
||||
";v" = "hint links spawn mpv {hint-url}";
|
||||
};
|
||||
};
|
||||
|
||||
settings = {
|
||||
content.notifications.enabled = false;
|
||||
content.pdfjs = true;
|
||||
content.webgl = false;
|
||||
fonts.completion.category = "14pt monospace";
|
||||
fonts.completion.entry = "14pt monospace";
|
||||
fonts.contextmenu = "14pt monospace";
|
||||
fonts.debug_console = "14pt monospace";
|
||||
fonts.downloads = "14pt monospace";
|
||||
fonts.hints = "14pt monospace";
|
||||
fonts.keyhint = "14pt monospace";
|
||||
fonts.messages.info = "14pt monospace";
|
||||
fonts.prompts = "14pt monospace";
|
||||
fonts.statusbar = "14pt monospace";
|
||||
hints.chars = "1qaz2wsx3edc4rfv5tgb6yhn7ujm8ik9ol0p";
|
||||
tabs.last_close = "close";
|
||||
tabs.position = "left";
|
||||
tabs.show = "multiple";
|
||||
tabs.tabs_are_windows = true;
|
||||
tabs.width = "12%";
|
||||
zoom.default = "125%";
|
||||
};
|
||||
};
|
||||
|
||||
git = {
|
||||
enable = true;
|
||||
settings = {
|
||||
user = {
|
||||
name = "Asmir A";
|
||||
email = "asmir.abdulahovic@gmail.com";
|
||||
};
|
||||
init.defaultBranch = "master";
|
||||
pull = {
|
||||
rebase = true;
|
||||
};
|
||||
credential = {
|
||||
helper = "store";
|
||||
};
|
||||
};
|
||||
signing.key = "020C42B7A9ABA3E2";
|
||||
signing.signByDefault = true;
|
||||
};
|
||||
|
||||
obs-studio = {
|
||||
enable = true;
|
||||
plugins = with pkgs.obs-studio-plugins; [
|
||||
obs-vkcapture
|
||||
input-overlay
|
||||
obs-multi-rtmp
|
||||
obs-pipewire-audio-capture
|
||||
wlrobs
|
||||
obs-vaapi
|
||||
];
|
||||
};
|
||||
|
||||
i3status-rust.enable = true;
|
||||
z-lua.enable = true;
|
||||
zsh.enable = true;
|
||||
};
|
||||
|
||||
services = {
|
||||
lorri.enable = false;
|
||||
mako.enable = true;
|
||||
cliphist.enable = true;
|
||||
gammastep = {
|
||||
enable = true;
|
||||
latitude = "44.53";
|
||||
longitude = "18.67";
|
||||
temperature.day = 5500;
|
||||
temperature.night = 2900;
|
||||
};
|
||||
|
||||
gnome-keyring.enable = true;
|
||||
|
||||
gpg-agent = {
|
||||
enable = true;
|
||||
defaultCacheTtl = 1800;
|
||||
enableSshSupport = true;
|
||||
};
|
||||
|
||||
swayidle =
|
||||
let
|
||||
locker = pkgs.writeShellScriptBin "swaylock_fancy" ''
|
||||
ALL_IMGS=""
|
||||
LOCK_ARGS=""
|
||||
for OUTPUT in $(${pkgs.sway}/bin/swaymsg -t get_outputs | ${lib.getExe pkgs.jq} -r '.[].name')
|
||||
do
|
||||
TMP_FILE=$(${pkgs.coreutils}/bin/mktemp /tmp/.swaylock_ss_XXXXXX.jpg)
|
||||
${lib.getExe pkgs.grim} -t ppm -o $OUTPUT - | \
|
||||
${lib.getExe pkgs.ffmpeg} -y -loglevel 0 -i - -vframes 1 -vf "boxblur=10" "$TMP_FILE"
|
||||
LOCK_ARGS="$LOCK_ARGS --image $OUTPUT:$TMP_FILE"
|
||||
ALL_IMGS="$ALL_IMGS $TMP_FILE"
|
||||
done
|
||||
${lib.getExe pkgs.swaylock} -f $LOCK_ARGS
|
||||
${pkgs.coreutils}/bin/shred $ALL_IMGS
|
||||
${pkgs.coreutils}/bin/rm $ALL_IMGS
|
||||
'';
|
||||
in
|
||||
/*
|
||||
refresh_i3status = pkgs.writeShellScriptBin "refresh_i3status" ''
|
||||
${pkgs.coreutils}/bin/sleep 1 && ${pkgs.procps}/bin/pkill -USR1 i3status-rs
|
||||
'';
|
||||
*/
|
||||
{
|
||||
enable = true;
|
||||
events = [
|
||||
{
|
||||
event = "before-sleep";
|
||||
command = "${locker}/bin/swaylock_fancy";
|
||||
}
|
||||
{
|
||||
event = "lock";
|
||||
command = "${locker}/bin/swaylock_fancy";
|
||||
}
|
||||
/*
|
||||
{
|
||||
event = "after-resume";
|
||||
command = "${refresh_i3status}/bin/refresh_i3status";
|
||||
}
|
||||
*/
|
||||
];
|
||||
timeouts = [
|
||||
{
|
||||
timeout = 15 * 60;
|
||||
command = "${locker}/bin/swaylock_fancy";
|
||||
}
|
||||
];
|
||||
};
|
||||
|
||||
kanshi = {
|
||||
enable = true;
|
||||
settings = [
|
||||
{
|
||||
profile.name = "undocked";
|
||||
profile.outputs = [
|
||||
{
|
||||
criteria = "eDP-1";
|
||||
}
|
||||
];
|
||||
}
|
||||
|
||||
{
|
||||
profile.name = "docked";
|
||||
profile.outputs = [
|
||||
{
|
||||
criteria = "eDP-1";
|
||||
position = "0,0";
|
||||
}
|
||||
{
|
||||
criteria = "Philips Consumer Electronics Company PHL 272S1 UHB2347026536";
|
||||
mode = "1920x1080@74.973Hz";
|
||||
position = "1920,0";
|
||||
}
|
||||
{
|
||||
criteria = "Philips Consumer Electronics Company PHL 272S1 UHB2347026535";
|
||||
mode = "1920x1080@74.973Hz";
|
||||
position = "3840,0";
|
||||
}
|
||||
];
|
||||
}
|
||||
];
|
||||
};
|
||||
};
|
||||
|
||||
systemd.user = {
|
||||
services = {
|
||||
|
||||
wayland-pipewire-idle-inhibit = {
|
||||
Unit.Description = "inhibit sleep while audio output is active";
|
||||
Service = {
|
||||
ExecStart = "${lib.getExe pkgs.wayland-pipewire-idle-inhibit}";
|
||||
Restart = "always";
|
||||
RestartSec = 10;
|
||||
};
|
||||
Install.WantedBy = [ "graphical-session.target" ];
|
||||
};
|
||||
|
||||
lisgd = {
|
||||
Unit = {
|
||||
Description = "Libinput gesture daemon";
|
||||
PartOf = [ "graphical-session.target" ];
|
||||
After = [ " graphical-session.target" ];
|
||||
};
|
||||
Service = {
|
||||
Environment = [
|
||||
"PATH=/run/current-system/sw/bin:/etc/profiles/per-user/%u/bin"
|
||||
];
|
||||
ExecStart = ''
|
||||
${pkgs.lisgd}/bin/lisgd -d \
|
||||
/dev/input/by-path/pci-0000:00:15.1-platform-i2c_designware.1-event \
|
||||
-g ''\'2,DU,*,*,B,${pkgs.procps}/bin/pkill -SIGRTMIN wvkbd-mobintl''\' \
|
||||
-g ''\'2,LR,*,*,swaymsg workspace prev''\' \
|
||||
-g ''\'2,RL,*,*,swaymsg workspace next''\' \
|
||||
-g ''\'3,DU,*,*,B,${pkgs.sway}/bin/swaymsg exec ${pkgs.kdePackages.dolphin}/bin/dolphin''\' \
|
||||
-g ''\'3,UD,*,*,B,${pkgs.sway}/bin/swaymsg exec ${lib.getExe pkgs.nwg-drawer}''\' \
|
||||
-g ''\'4,UD,*,*,B,${pkgs.sway}/bin/swaymsg kill''\' \
|
||||
'';
|
||||
Restart = "on-failure";
|
||||
};
|
||||
Install.WantedBy = [ "graphical-session.target" ];
|
||||
};
|
||||
|
||||
wvkbd = {
|
||||
Unit = {
|
||||
Description = "Wayland virtual keyboard";
|
||||
PartOf = [ "graphical-session.target" ];
|
||||
};
|
||||
Service = {
|
||||
ExecStart = "${pkgs.wvkbd}/bin/wvkbd-mobintl -l full --hidden";
|
||||
Restart = "on-failure";
|
||||
};
|
||||
Install.WantedBy = [ "graphical-session.target" ];
|
||||
};
|
||||
|
||||
|
||||
};
|
||||
};
|
||||
}
|
||||
@@ -1,193 +0,0 @@
|
||||
{ lib
|
||||
, pkgs
|
||||
, inputs
|
||||
, system
|
||||
, ...
|
||||
}:
|
||||
let
|
||||
chromium_teams = pkgs.writeShellScriptBin "chromium_teams" ''
|
||||
${lib.getExe pkgs.ungoogled-chromium} --socket=wayland org.chromium.Chromium --app=https://teams.microsoft.com/
|
||||
'';
|
||||
chromium_discord = pkgs.writeShellScriptBin "chromium_discord" ''
|
||||
${lib.getExe pkgs.ungoogled-chromium} --socket=wayland org.chromium.Chromium --app=https://discordapp.com/channels/@me
|
||||
'';
|
||||
chromium_stackfield = pkgs.writeShellScriptBin "chromium_stackfield" ''
|
||||
${lib.getExe pkgs.ungoogled-chromium} --socket=wayland org.chromium.Chromium --app=https://stackfield.com/
|
||||
'';
|
||||
nixy_switch = pkgs.writeShellScriptBin "nixy_switch" ''
|
||||
${pkgs.util-linux}/bin/ionice -c 3 -- \
|
||||
${pkgs.coreutils}/bin/nice -n 20 -- \
|
||||
${lib.getExe pkgs.nixos-rebuild} --flake ./#fuji switch
|
||||
'';
|
||||
qcad = pkgs.writeShellScriptBin "qcad" ''
|
||||
QT_QPA_PLATFORM=xcb ${lib.getExe pkgs.qcad} $@
|
||||
'';
|
||||
ssh_proxy = pkgs.writeShellScriptBin "ssh_proxy" ''
|
||||
if ${pkgs.coreutils}/bin/test $# -ne 1; then
|
||||
echo "Usage: $0 <user>@<ssh_host>"
|
||||
exit
|
||||
fi
|
||||
PROXY_PORT="1337"
|
||||
${lib.getExe pkgs.openssh} -D "$PROXY_PORT" -q -N "$@"
|
||||
'';
|
||||
wrap_sh =
|
||||
let
|
||||
bubblewrap = pkgs.callPackage ../../packages/bubblewrap/default.nix { };
|
||||
in
|
||||
pkgs.writeShellScriptBin "wrap.sh" ''
|
||||
if ${pkgs.coreutils-full}/bin/test $# -ne 1; then
|
||||
echo "Usage: $0 <directory>"
|
||||
exit
|
||||
fi
|
||||
FULL_PATH=$(${pkgs.coreutils-full}/bin/realpath "$1")
|
||||
BUBBLEWRAP_DIR="$1" ${bubblewrap}/bin/bwrap \
|
||||
--bind / / \
|
||||
--dev /dev \
|
||||
--overlay-src "$FULL_PATH" \
|
||||
--tmp-overlay "$FULL_PATH" \
|
||||
"$SHELL"
|
||||
'';
|
||||
in
|
||||
{
|
||||
home.packages =
|
||||
with pkgs;
|
||||
[
|
||||
alsa-tools
|
||||
alsa-utils
|
||||
appimage-run
|
||||
arp-scan
|
||||
birdtray
|
||||
blackmagic
|
||||
blender
|
||||
btop
|
||||
cached-nix-shell
|
||||
caddy
|
||||
calibre
|
||||
cargo
|
||||
cmake
|
||||
compsize
|
||||
cura-appimage
|
||||
deluge
|
||||
dfu-util
|
||||
discord
|
||||
dmenu-wayland
|
||||
drawio
|
||||
dualsensectl
|
||||
ffmpeg-full
|
||||
firefox
|
||||
freecad
|
||||
gcc
|
||||
gdb
|
||||
ghostscript
|
||||
glab
|
||||
glaxnimate
|
||||
gnumake
|
||||
go
|
||||
grim
|
||||
heimdall
|
||||
hyperfine
|
||||
icestorm
|
||||
iio-hyprland
|
||||
imagemagick
|
||||
imv
|
||||
inkscape
|
||||
#jellyfin-media-player
|
||||
kdePackages.ark
|
||||
kdePackages.dolphin
|
||||
kdePackages.kdegraphics-thumbnailers
|
||||
kdePackages.kdenlive
|
||||
kdePackages.okular
|
||||
kicad
|
||||
kodi-wayland
|
||||
komikku
|
||||
krita
|
||||
libinput
|
||||
libjxl
|
||||
libnotify
|
||||
libreoffice-qt6-fresh
|
||||
libva-utils
|
||||
lsix
|
||||
lsix
|
||||
mediainfo
|
||||
ncdu
|
||||
neovide
|
||||
nextpnr
|
||||
ngspice
|
||||
nix-init
|
||||
nixpkgs-fmt
|
||||
nix-prefetch-git
|
||||
nom
|
||||
openems
|
||||
openocd
|
||||
openscad
|
||||
pandoc
|
||||
#paraview
|
||||
pass-wayland
|
||||
patchelf
|
||||
pavucontrol
|
||||
pay-respects
|
||||
perf
|
||||
pirate-get
|
||||
poppler-utils
|
||||
powertop
|
||||
pulsemixer
|
||||
pwvucontrol
|
||||
python3
|
||||
python3Packages.west
|
||||
qucs-s
|
||||
radeontop
|
||||
remmina
|
||||
river-classic
|
||||
rizin
|
||||
rtorrent
|
||||
sbcl
|
||||
screen
|
||||
seer
|
||||
sioyek
|
||||
slurp
|
||||
steam-run
|
||||
stm32cubemx
|
||||
styluslabs-write
|
||||
swayimg
|
||||
tea
|
||||
teams-for-linux
|
||||
tectonic
|
||||
tessen
|
||||
texlive.combined.scheme-full
|
||||
thunderbird
|
||||
typst
|
||||
ungoogled-chromium
|
||||
upx
|
||||
viber
|
||||
wasistlos
|
||||
waybar
|
||||
wdisplays
|
||||
weechat
|
||||
wine
|
||||
wireshark
|
||||
wl-clipboard
|
||||
wlr-randr
|
||||
wofi
|
||||
x2goclient
|
||||
xournalpp
|
||||
yewtube
|
||||
yosys
|
||||
yt-dlp
|
||||
zapzap
|
||||
zathura
|
||||
zig
|
||||
]
|
||||
++ [
|
||||
chromium_discord
|
||||
chromium_stackfield
|
||||
chromium_teams
|
||||
nixy_switch
|
||||
qcad
|
||||
ssh_proxy
|
||||
wrap_sh
|
||||
]
|
||||
++ [
|
||||
inputs.swaysw.packages.${system}.swaysw
|
||||
(pkgs.callPackage ../../packages/bubblewrap/default.nix { })
|
||||
];
|
||||
}
|
||||
@@ -2,21 +2,12 @@
|
||||
lib,
|
||||
pkgs,
|
||||
...
|
||||
}:
|
||||
let
|
||||
}: let
|
||||
qutebrowser_firejail = pkgs.writeShellScriptBin "qutebrowser" ''
|
||||
firejail -- ${lib.getExe pkgs.qutebrowser} "$@"
|
||||
'';
|
||||
in
|
||||
{
|
||||
imports = [
|
||||
../common/zsh.nix
|
||||
../common/i3status-rust.nix
|
||||
../common/sway.nix
|
||||
../common/i3.nix
|
||||
./home_packages.nix
|
||||
../common/whatsapp-for-linux.nix
|
||||
];
|
||||
in {
|
||||
imports = [./zsh.nix ./i3status-rust.nix ./sway.nix ./i3.nix ./home_packages.nix ./whatsapp-for-linux.nix];
|
||||
|
||||
home.stateVersion = "22.11";
|
||||
home.username = "akill";
|
||||
@@ -50,9 +41,7 @@ in
|
||||
WLR_RENDERER = "vulkan";
|
||||
};
|
||||
|
||||
wayland.windowManager.sway = {
|
||||
enable = true;
|
||||
};
|
||||
wayland.windowManager.sway = {enable = true;};
|
||||
|
||||
programs = {
|
||||
home-manager.enable = true;
|
||||
@@ -71,11 +60,7 @@ in
|
||||
clock24 = true;
|
||||
keyMode = "vi";
|
||||
terminal = "screen-256color";
|
||||
plugins = with pkgs.tmuxPlugins; [
|
||||
sysstat
|
||||
net-speed
|
||||
gruvbox
|
||||
];
|
||||
plugins = with pkgs.tmuxPlugins; [sysstat net-speed gruvbox];
|
||||
};
|
||||
|
||||
mpv = {
|
||||
@@ -86,9 +71,7 @@ in
|
||||
hwdec = "auto";
|
||||
vo = "gpu-next";
|
||||
ao = "pipewire";
|
||||
osd-bar = "no";
|
||||
border = "no";
|
||||
script-opts-set = "";
|
||||
script-opts-set = "ytdl_hook-ytdl_path=yt-dlp,sponsorblock-local_database=no,sponsorblock-skip_categories=[sponsor,intro,selfpromo]";
|
||||
ytdl-format = "bestvideo[height<=?1080]+bestaudio/best";
|
||||
};
|
||||
|
||||
@@ -154,14 +137,13 @@ in
|
||||
font = "JetBrainsMono:size=10";
|
||||
dpi-aware = "yes";
|
||||
};
|
||||
mouse = {
|
||||
hide-when-typing = "yes";
|
||||
};
|
||||
mouse = {hide-when-typing = "yes";};
|
||||
};
|
||||
};
|
||||
|
||||
qutebrowser = {
|
||||
enable = true;
|
||||
package = qutebrowser_firejail;
|
||||
keyBindings = {
|
||||
normal = {
|
||||
"j" = "scroll-px 0 25";
|
||||
@@ -201,12 +183,8 @@ in
|
||||
userEmail = "asmir.abdulahovic@gmail.com";
|
||||
extraConfig = {
|
||||
init.defaultBranch = "master";
|
||||
pull = {
|
||||
rebase = true;
|
||||
};
|
||||
credential = {
|
||||
helper = "store";
|
||||
};
|
||||
pull = {rebase = true;};
|
||||
credential = {helper = "store";};
|
||||
};
|
||||
signing.key = "020C42B7A9ABA3E2";
|
||||
signing.signByDefault = true;
|
||||
@@ -214,14 +192,7 @@ in
|
||||
|
||||
obs-studio = {
|
||||
enable = true;
|
||||
plugins = with pkgs.obs-studio-plugins; [
|
||||
obs-vkcapture
|
||||
input-overlay
|
||||
obs-multi-rtmp
|
||||
obs-pipewire-audio-capture
|
||||
wlrobs
|
||||
obs-vaapi
|
||||
];
|
||||
plugins = with pkgs.obs-studio-plugins; [obs-vkcapture input-overlay obs-multi-rtmp obs-pipewire-audio-capture wlrobs obs-vaapi];
|
||||
};
|
||||
|
||||
i3status-rust.enable = true;
|
||||
@@ -249,30 +220,14 @@ in
|
||||
enableSshSupport = true;
|
||||
};
|
||||
|
||||
swayidle =
|
||||
let
|
||||
swayidle = let
|
||||
locker = pkgs.writeShellScriptBin "swaylock_fancy" ''
|
||||
ALL_IMGS=""
|
||||
LOCK_ARGS=""
|
||||
for OUTPUT in $(${pkgs.sway}/bin/swaymsg -t get_outputs | ${lib.getExe pkgs.jq} -r '.[].name')
|
||||
do
|
||||
TMP_FILE=$(${pkgs.coreutils}/bin/mktemp /tmp/.swaylock_ss_XXXXXX.jpg)
|
||||
${lib.getExe pkgs.grim} -t ppm -o $OUTPUT - | \
|
||||
${lib.getExe pkgs.ffmpeg} -y -loglevel 0 -i - -vframes 1 -vf "boxblur=10" "$TMP_FILE"
|
||||
LOCK_ARGS="$LOCK_ARGS --image $OUTPUT:$TMP_FILE"
|
||||
ALL_IMGS="$ALL_IMGS $TMP_FILE"
|
||||
done
|
||||
${lib.getExe pkgs.swaylock} -f $LOCK_ARGS
|
||||
${pkgs.coreutils}/bin/shred $ALL_IMGS
|
||||
${pkgs.coreutils}/bin/rm $ALL_IMGS
|
||||
${lib.getExe pkgs.grim} -t ppm - | ${pkgs.imagemagick}/bin/convert - -blur 0x12 "$TMP_FILE"
|
||||
${lib.getExe pkgs.swaylock} -f -i "$TMP_FILE"
|
||||
${pkgs.coreutils}/bin/rm "$TMP_FILE"
|
||||
'';
|
||||
in
|
||||
/*
|
||||
refresh_i3status = pkgs.writeShellScriptBin "refresh_i3status" ''
|
||||
${pkgs.coreutils}/bin/sleep 1 && ${pkgs.procps}/bin/pkill -USR1 i3status-rs
|
||||
'';
|
||||
*/
|
||||
{
|
||||
in {
|
||||
enable = true;
|
||||
events = [
|
||||
{
|
||||
@@ -283,12 +238,10 @@ in
|
||||
event = "lock";
|
||||
command = "${locker}/bin/swaylock_fancy";
|
||||
}
|
||||
/*
|
||||
{
|
||||
event = "after-resume";
|
||||
command = "${refresh_i3status}/bin/refresh_i3status";
|
||||
command = "${pkgs.procps}/bin/pkill -USR1 i3status-rs";
|
||||
}
|
||||
*/
|
||||
];
|
||||
timeouts = [
|
||||
{
|
||||
@@ -315,17 +268,14 @@ in
|
||||
profile.outputs = [
|
||||
{
|
||||
criteria = "eDP-1";
|
||||
position = "0,0";
|
||||
}
|
||||
{
|
||||
criteria = "Philips Consumer Electronics Company PHL 272S1 UHB2347026536";
|
||||
mode = "1920x1080@74.973Hz";
|
||||
position = "1920,0";
|
||||
}
|
||||
{
|
||||
criteria = "Philips Consumer Electronics Company PHL 272S1 UHB2347026535";
|
||||
mode = "1920x1080@74.973Hz";
|
||||
position = "3840,0";
|
||||
}
|
||||
];
|
||||
}
|
||||
@@ -335,17 +285,19 @@ in
|
||||
|
||||
systemd.user = {
|
||||
services = {
|
||||
wayland-pipewire-idle-inhibit = {
|
||||
Unit.Description = "inhibit sleep while audio output is active";
|
||||
/*
|
||||
himalaya = {
|
||||
Unit.Description = "Himalaya new messages notifier";
|
||||
Service = {
|
||||
ExecStart = "${lib.getExe pkgs.wayland-pipewire-idle-inhibit}";
|
||||
ExecStart = "himalaya notify";
|
||||
Restart = "always";
|
||||
RestartSec = 10;
|
||||
};
|
||||
Install = {
|
||||
WantedBy = [ "graphical-session.target" ];
|
||||
WantedBy = [ "multi-user.target" ];
|
||||
};
|
||||
};
|
||||
*/
|
||||
};
|
||||
};
|
||||
}
|
||||
@@ -4,8 +4,7 @@
|
||||
inputs,
|
||||
system,
|
||||
...
|
||||
}:
|
||||
let
|
||||
}: let
|
||||
chromium_teams = pkgs.writeShellScriptBin "chromium_teams" ''
|
||||
${lib.getExe pkgs.ungoogled-chromium} --socket=wayland org.chromium.Chromium --app=https://teams.microsoft.com/
|
||||
'';
|
||||
@@ -15,11 +14,6 @@ let
|
||||
chromium_stackfield = pkgs.writeShellScriptBin "chromium_stackfield" ''
|
||||
${lib.getExe pkgs.ungoogled-chromium} --socket=wayland org.chromium.Chromium --app=https://stackfield.com/
|
||||
'';
|
||||
nixy_switch = pkgs.writeShellScriptBin "nixy_switch" ''
|
||||
${pkgs.util-linux}/bin/ionice -c 3 -- \
|
||||
${pkgs.coreutils}/bin/nice -n 20 -- \
|
||||
${lib.getExe pkgs.nixos-rebuild} --flake ./#nixy switch
|
||||
'';
|
||||
qcad = pkgs.writeShellScriptBin "qcad" ''
|
||||
QT_QPA_PLATFORM=xcb ${lib.getExe pkgs.qcad} $@
|
||||
'';
|
||||
@@ -31,9 +25,8 @@ let
|
||||
PROXY_PORT="1337"
|
||||
${lib.getExe pkgs.openssh} -D "$PROXY_PORT" -q -N "$@"
|
||||
'';
|
||||
wrap_sh =
|
||||
let
|
||||
bubblewrap = pkgs.callPackage ../../packages/bubblewrap/default.nix { };
|
||||
wrap_sh = let
|
||||
bubblewrap = pkgs.callPackage ../packages/bubblewrap/default.nix {};
|
||||
in
|
||||
pkgs.writeShellScriptBin "wrap.sh" ''
|
||||
if ${pkgs.coreutils-full}/bin/test $# -ne 1; then
|
||||
@@ -48,10 +41,8 @@ let
|
||||
--tmp-overlay "$FULL_PATH" \
|
||||
"$SHELL"
|
||||
'';
|
||||
in
|
||||
{
|
||||
home.packages =
|
||||
with pkgs;
|
||||
in {
|
||||
home.packages = with pkgs;
|
||||
[
|
||||
anydesk
|
||||
appimage-run
|
||||
@@ -63,11 +54,10 @@ in
|
||||
cached-nix-shell
|
||||
caddy
|
||||
cargo
|
||||
ungoogled-chromium
|
||||
cmake
|
||||
compsize
|
||||
kdePackages.ark
|
||||
ungoogled-chromium
|
||||
# cura
|
||||
/*cura*/
|
||||
deluge
|
||||
dfu-util
|
||||
discord
|
||||
@@ -92,7 +82,7 @@ in
|
||||
imv
|
||||
inkscape
|
||||
jellyfin-media-player
|
||||
kdePackages.kdenlive
|
||||
kdenlive
|
||||
kicad
|
||||
kodi-wayland
|
||||
krita
|
||||
@@ -110,6 +100,7 @@ in
|
||||
nix-init
|
||||
nixpkgs-fmt
|
||||
nix-prefetch-git
|
||||
nodePackages.peerflix
|
||||
nom
|
||||
openems
|
||||
openocd
|
||||
@@ -129,12 +120,12 @@ in
|
||||
python3Packages.west
|
||||
remmina
|
||||
river
|
||||
rizin
|
||||
rtorrent
|
||||
sbcl
|
||||
screen
|
||||
seer
|
||||
sioyek
|
||||
skypeforlinux
|
||||
slurp
|
||||
steam-run
|
||||
stm32cubemx
|
||||
@@ -147,7 +138,6 @@ in
|
||||
thunderbird
|
||||
typst
|
||||
upx
|
||||
viber
|
||||
waybar
|
||||
wdisplays
|
||||
weechat
|
||||
@@ -163,20 +153,20 @@ in
|
||||
yt-dlp
|
||||
zapzap
|
||||
zathura
|
||||
# zeal-qt6
|
||||
/*zeal-qt6*/
|
||||
zig
|
||||
]
|
||||
++ [
|
||||
chromium_discord
|
||||
chromium_stackfield
|
||||
chromium_teams
|
||||
nixy_switch
|
||||
qcad
|
||||
ssh_proxy
|
||||
wrap_sh
|
||||
qcad
|
||||
]
|
||||
++ [
|
||||
inputs.swaysw.packages.${system}.swaysw
|
||||
(pkgs.callPackage ../../packages/bubblewrap/default.nix { })
|
||||
(pkgs.callPackage ../packages/viber/default.nix {})
|
||||
(pkgs.callPackage ../packages/bubblewrap/default.nix {})
|
||||
];
|
||||
}
|
||||
@@ -2,11 +2,9 @@
|
||||
lib,
|
||||
pkgs,
|
||||
...
|
||||
}:
|
||||
let
|
||||
}: let
|
||||
scratchpad_cmd = "floating enable, resize set 1502 845, move position center, move scratchpad, scratchpad show";
|
||||
in
|
||||
{
|
||||
in {
|
||||
xsession.windowManager.i3 = {
|
||||
enable = true;
|
||||
package = pkgs.i3;
|
||||
@@ -55,28 +53,24 @@ in
|
||||
"${modifier}+Escape" = "workspace back_and_forth";
|
||||
"${modifier}+p" = "exec ${pkgs.dmenu}/bin/dmenu_run";
|
||||
|
||||
"Mod4+l" =
|
||||
"exec i3-msg [instance=\"python3_scr\"] scratchpad show || exec alacritty --class python3_scr -e python3";
|
||||
"Mod4+l" = "exec i3-msg [instance=\"python3_scr\"] scratchpad show || exec alacritty --class python3_scr -e python3";
|
||||
"Mod4+j" = "exec i3-msg [class=\"ViberPC\"] scratchpad show || exec viber";
|
||||
"Mod4+m" = "exec i3-msg [class=\"Thunderbird\"] scratchpad show || exec thunderbird";
|
||||
"Mod4+y" =
|
||||
"exec i3-msg [instance=\"pulsemixer_scr\"] scratchpad show || exec alacritty --class pulsemixer_scr -e pulsemixer";
|
||||
"Mod4+y" = "exec i3-msg [instance=\"pulsemixer_scr\"] scratchpad show || exec alacritty --class pulsemixer_scr -e pulsemixer";
|
||||
};
|
||||
|
||||
window = {
|
||||
# border = 4;
|
||||
/*
|
||||
border = 4;
|
||||
*/
|
||||
commands = [
|
||||
{
|
||||
command = scratchpad_cmd;
|
||||
criteria = {
|
||||
instance = "pulsemixer_scr|python3_scr";
|
||||
};
|
||||
criteria = {instance = "pulsemixer_scr|python3_scr";};
|
||||
}
|
||||
{
|
||||
command = scratchpad_cmd;
|
||||
criteria = {
|
||||
class = "Thunderbird";
|
||||
};
|
||||
criteria = {class = "Thunderbird";};
|
||||
}
|
||||
{
|
||||
command = scratchpad_cmd;
|
||||
@@ -87,9 +81,7 @@ in
|
||||
}
|
||||
{
|
||||
command = "focus child, layout tabbed, focus";
|
||||
criteria = {
|
||||
class = "qutebrowser";
|
||||
};
|
||||
criteria = {class = "qutebrowser";};
|
||||
}
|
||||
];
|
||||
};
|
||||
@@ -98,10 +90,7 @@ in
|
||||
{
|
||||
position = "top";
|
||||
fonts = {
|
||||
names = [
|
||||
"DejaVu Sans Mono"
|
||||
"FontAwesome5Free"
|
||||
];
|
||||
names = ["DejaVu Sans Mono" "FontAwesome5Free"];
|
||||
style = "Fixed Bold SemiCondensed";
|
||||
size = 7.0;
|
||||
};
|
||||
@@ -1,15 +1,4 @@
|
||||
{ pkgs, ... }:
|
||||
let
|
||||
kbd_switch = pkgs.writeShellScriptBin "kbd_switch" ''
|
||||
declare -A -r KBD_CYCLE_MAP=(
|
||||
["English (US)"]="de"
|
||||
["German"]="ba"
|
||||
)
|
||||
LAYOUT="$(${pkgs.sway}/bin/swaymsg -t get_inputs -r | ${pkgs.jq}/bin/jq -r 'map(select(.type == "keyboard")).[0].xkb_layout_names.[]')"
|
||||
swaymsg input "*" xkb_layout ''${KBD_CYCLE_MAP["$LAYOUT"]:-"us"}
|
||||
'';
|
||||
in
|
||||
{
|
||||
{...}: {
|
||||
programs.i3status-rust = {
|
||||
bars.top = {
|
||||
icons = "awesome5";
|
||||
@@ -22,16 +11,6 @@ in
|
||||
};
|
||||
|
||||
blocks = [
|
||||
{
|
||||
block = "keyboard_layout";
|
||||
driver = "sway";
|
||||
click = [
|
||||
{
|
||||
cmd = "${kbd_switch}/bin/kbd_switch";
|
||||
button = "left";
|
||||
}
|
||||
];
|
||||
}
|
||||
{
|
||||
block = "battery";
|
||||
interval = 10;
|
||||
@@ -56,30 +35,20 @@ in
|
||||
{
|
||||
block = "net";
|
||||
device = "wlan0";
|
||||
if_command = "ip link show wlan0";
|
||||
interval = 2;
|
||||
}
|
||||
{
|
||||
block = "net";
|
||||
device = "enp5s0";
|
||||
if_command = "ip link show enp5s0";
|
||||
interval = 2;
|
||||
}
|
||||
{
|
||||
block = "net";
|
||||
device = "enp7s0f3u1u1";
|
||||
if_command = "ip link show enp7s0f3u1u1";
|
||||
interval = 2;
|
||||
}
|
||||
{
|
||||
block = "net";
|
||||
device = "enp7s0f4u1u1";
|
||||
if_command = "ip link show enp7s0f4u1u1";
|
||||
interval = 2;
|
||||
}
|
||||
{
|
||||
block = "net";
|
||||
if_command = "ip link show eno1";
|
||||
device = "eno1";
|
||||
interval = 2;
|
||||
}
|
||||
@@ -89,7 +58,7 @@ in
|
||||
{
|
||||
block = "cpu";
|
||||
interval = 1;
|
||||
format = "$utilization $barchart $frequency $max_frequency";
|
||||
format = "$utilization $barchart $frequency";
|
||||
}
|
||||
{
|
||||
block = "temperature";
|
||||
@@ -1,348 +0,0 @@
|
||||
{
|
||||
lib,
|
||||
pkgs,
|
||||
...
|
||||
}:
|
||||
let
|
||||
qutebrowser_firejail = pkgs.writeShellScriptBin "qutebrowser" ''
|
||||
firejail -- ${lib.getExe pkgs.qutebrowser} "$@"
|
||||
'';
|
||||
in
|
||||
{
|
||||
imports = [
|
||||
../common/zsh.nix
|
||||
./home_packages.nix
|
||||
../common/whatsapp-for-linux.nix
|
||||
];
|
||||
|
||||
home.stateVersion = "22.11";
|
||||
home.username = "akill";
|
||||
home.homeDirectory = "/home/akill";
|
||||
|
||||
xdg.enable = true;
|
||||
xdg.mimeApps = {
|
||||
enable = true;
|
||||
defaultApplications = {
|
||||
"application/pdf" = "sioyek.desktop";
|
||||
"default-web-browser" = "org.qutebrowser.qutebrowser.desktop";
|
||||
"text/html" = "org.qutebrowser.qutebrowser.desktop";
|
||||
"x-scheme-handler/about" = "org.qutebrowser.qutebrowser.desktop";
|
||||
"x-scheme-handler/http" = "org.qutebrowser.qutebrowser.desktop";
|
||||
"x-scheme-handler/https" = "org.qutebrowser.qutebrowser.desktop";
|
||||
"x-scheme-handler/unknown" = "org.qutebrowser.qutebrowser.desktop";
|
||||
};
|
||||
};
|
||||
|
||||
fonts.fontconfig.enable = true;
|
||||
|
||||
home.sessionVariables = rec {
|
||||
BROWSER = lib.getExe qutebrowser_firejail;
|
||||
DEFAULT_BROWSER = "${BROWSER}";
|
||||
EDITOR = "nvim";
|
||||
_JAVA_AWT_WM_NONREPARENTING = "1";
|
||||
MOZ_ENABLE_WAYLAND = "1";
|
||||
NIXOS_OZONE_WL = "1";
|
||||
QT_WAYLAND_DISABLE_WINDOWDECORATION = "1";
|
||||
SUDO_EDITOR = "nvim";
|
||||
WLR_RENDERER = "vulkan";
|
||||
};
|
||||
|
||||
wayland.windowManager.sway = {
|
||||
enable = false;
|
||||
};
|
||||
|
||||
programs = {
|
||||
home-manager.enable = true;
|
||||
|
||||
librewolf = {
|
||||
enable = true;
|
||||
package = pkgs.librewolf-wayland;
|
||||
settings = {
|
||||
"webgl.disable" = true;
|
||||
"middlemouse.paste" = false;
|
||||
};
|
||||
};
|
||||
|
||||
tmux = {
|
||||
enable = true;
|
||||
clock24 = true;
|
||||
keyMode = "vi";
|
||||
terminal = "screen-256color";
|
||||
plugins = with pkgs.tmuxPlugins; [
|
||||
sysstat
|
||||
net-speed
|
||||
gruvbox
|
||||
];
|
||||
};
|
||||
|
||||
mpv = {
|
||||
enable = true;
|
||||
config = {
|
||||
slang = "eng,en";
|
||||
alang = "eng,en";
|
||||
hwdec = "auto";
|
||||
vo = "gpu-next";
|
||||
ao = "pipewire";
|
||||
osd-bar = "no";
|
||||
border = "no";
|
||||
script-opts-set = "";
|
||||
ytdl-format = "bestvideo[height<=?1080]+bestaudio/best";
|
||||
};
|
||||
|
||||
bindings = {
|
||||
WHEEL_UP = "ignore";
|
||||
WHEEL_DOWN = "ignore";
|
||||
WHEEL_LEFT = "ignore";
|
||||
WHEEL_RIGHT = "ignore";
|
||||
};
|
||||
};
|
||||
|
||||
alacritty = {
|
||||
enable = true;
|
||||
|
||||
settings = {
|
||||
font = {
|
||||
normal.family = "JetBrainsMono";
|
||||
italic.family = "JetBrainsMono";
|
||||
bold.family = "JetBrainsMono";
|
||||
bold_italic.family = "JetBrainsMono";
|
||||
size = 14.0;
|
||||
};
|
||||
|
||||
selection = {
|
||||
text = "0xcfcfc2";
|
||||
background = "0x232629";
|
||||
|
||||
normal = {
|
||||
black = "0x1c1b19";
|
||||
red = "0xef2f27";
|
||||
green = "0x519f50";
|
||||
yellow = "0xfbb829";
|
||||
blue = "0x2c78bf";
|
||||
magenta = "0xe02c6d";
|
||||
cyan = "0x0aaeb3";
|
||||
white = "0x918175";
|
||||
};
|
||||
|
||||
bright = {
|
||||
black = "0x2D2C29";
|
||||
red = "0xf75341";
|
||||
green = "0x98bc37";
|
||||
yellow = "0xfed06e";
|
||||
blue = "0x68A8E4";
|
||||
magenta = "0xff5c8f";
|
||||
cyan = "0x53fde9";
|
||||
white = "0xfce8c3";
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
rofi = {
|
||||
enable = true;
|
||||
theme = "gruvbox-dark";
|
||||
};
|
||||
|
||||
foot = {
|
||||
enable = true;
|
||||
server.enable = true;
|
||||
settings = {
|
||||
main = {
|
||||
font = "JetBrainsMono:size=10";
|
||||
dpi-aware = "yes";
|
||||
};
|
||||
mouse = {
|
||||
hide-when-typing = "yes";
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
qutebrowser = {
|
||||
enable = true;
|
||||
keyBindings = {
|
||||
normal = {
|
||||
"j" = "scroll-px 0 25";
|
||||
"k" = "scroll-px 0 -25";
|
||||
"u" = "undo --window";
|
||||
";v" = "hint links spawn mpv {hint-url}";
|
||||
};
|
||||
};
|
||||
|
||||
settings = {
|
||||
content.notifications.enabled = false;
|
||||
content.pdfjs = true;
|
||||
content.webgl = false;
|
||||
fonts.completion.category = "14pt monospace";
|
||||
fonts.completion.entry = "14pt monospace";
|
||||
fonts.contextmenu = "14pt monospace";
|
||||
fonts.debug_console = "14pt monospace";
|
||||
fonts.downloads = "14pt monospace";
|
||||
fonts.hints = "14pt monospace";
|
||||
fonts.keyhint = "14pt monospace";
|
||||
fonts.messages.info = "14pt monospace";
|
||||
fonts.prompts = "14pt monospace";
|
||||
fonts.statusbar = "14pt monospace";
|
||||
hints.chars = "1qaz2wsx3edc4rfv5tgb6yhn7ujm8ik9ol0p";
|
||||
tabs.last_close = "close";
|
||||
tabs.position = "left";
|
||||
tabs.show = "multiple";
|
||||
tabs.tabs_are_windows = true;
|
||||
tabs.width = "12%";
|
||||
zoom.default = "125%";
|
||||
};
|
||||
};
|
||||
|
||||
git = {
|
||||
enable = true;
|
||||
userName = "Asmir A";
|
||||
userEmail = "asmir.abdulahovic@gmail.com";
|
||||
extraConfig = {
|
||||
init.defaultBranch = "master";
|
||||
pull = {
|
||||
rebase = true;
|
||||
};
|
||||
credential = {
|
||||
helper = "store";
|
||||
};
|
||||
};
|
||||
signing.key = "020C42B7A9ABA3E2";
|
||||
signing.signByDefault = true;
|
||||
};
|
||||
|
||||
obs-studio = {
|
||||
enable = true;
|
||||
plugins = with pkgs.obs-studio-plugins; [
|
||||
obs-vkcapture
|
||||
input-overlay
|
||||
obs-multi-rtmp
|
||||
obs-pipewire-audio-capture
|
||||
wlrobs
|
||||
obs-vaapi
|
||||
];
|
||||
};
|
||||
|
||||
i3status-rust.enable = false;
|
||||
z-lua.enable = true;
|
||||
zsh.enable = true;
|
||||
};
|
||||
|
||||
services = {
|
||||
lorri.enable = false;
|
||||
mako.enable = true;
|
||||
cliphist.enable = true;
|
||||
gammastep = {
|
||||
enable = true;
|
||||
latitude = "44.53";
|
||||
longitude = "18.67";
|
||||
temperature.day = 5500;
|
||||
temperature.night = 2900;
|
||||
};
|
||||
|
||||
gnome-keyring.enable = true;
|
||||
|
||||
gpg-agent = {
|
||||
enable = true;
|
||||
defaultCacheTtl = 1800;
|
||||
enableSshSupport = true;
|
||||
};
|
||||
|
||||
swayidle =
|
||||
let
|
||||
locker = pkgs.writeShellScriptBin "swaylock_fancy" ''
|
||||
ALL_IMGS=""
|
||||
LOCK_ARGS=""
|
||||
for OUTPUT in $(${pkgs.sway}/bin/swaymsg -t get_outputs | ${lib.getExe pkgs.jq} -r '.[].name')
|
||||
do
|
||||
TMP_FILE=$(${pkgs.coreutils}/bin/mktemp /tmp/.swaylock_ss_XXXXXX.jpg)
|
||||
${lib.getExe pkgs.grim} -t ppm -o $OUTPUT - | \
|
||||
${lib.getExe pkgs.ffmpeg} -y -loglevel 0 -i - -vframes 1 -vf "boxblur=10" "$TMP_FILE"
|
||||
LOCK_ARGS="$LOCK_ARGS --image $OUTPUT:$TMP_FILE"
|
||||
ALL_IMGS="$ALL_IMGS $TMP_FILE"
|
||||
done
|
||||
${lib.getExe pkgs.swaylock} -f $LOCK_ARGS
|
||||
${pkgs.coreutils}/bin/shred $ALL_IMGS
|
||||
${pkgs.coreutils}/bin/rm $ALL_IMGS
|
||||
'';
|
||||
in
|
||||
/*
|
||||
refresh_i3status = pkgs.writeShellScriptBin "refresh_i3status" ''
|
||||
${pkgs.coreutils}/bin/sleep 1 && ${pkgs.procps}/bin/pkill -USR1 i3status-rs
|
||||
'';
|
||||
*/
|
||||
{
|
||||
enable = false;
|
||||
events = [
|
||||
{
|
||||
event = "before-sleep";
|
||||
command = "${locker}/bin/swaylock_fancy";
|
||||
}
|
||||
{
|
||||
event = "lock";
|
||||
command = "${locker}/bin/swaylock_fancy";
|
||||
}
|
||||
/*
|
||||
{
|
||||
event = "after-resume";
|
||||
command = "${refresh_i3status}/bin/refresh_i3status";
|
||||
}
|
||||
*/
|
||||
];
|
||||
timeouts = [
|
||||
{
|
||||
timeout = 15 * 60;
|
||||
command = "${locker}/bin/swaylock_fancy";
|
||||
}
|
||||
];
|
||||
};
|
||||
|
||||
kanshi = {
|
||||
enable = false;
|
||||
settings = [
|
||||
{
|
||||
profile.name = "undocked";
|
||||
profile.outputs = [
|
||||
{
|
||||
criteria = "eDP-1";
|
||||
}
|
||||
];
|
||||
}
|
||||
|
||||
{
|
||||
profile.name = "docked";
|
||||
profile.outputs = [
|
||||
{
|
||||
criteria = "eDP-1";
|
||||
position = "0,0";
|
||||
}
|
||||
{
|
||||
criteria = "Philips Consumer Electronics Company PHL 272S1 UHB2347026536";
|
||||
mode = "1920x1080@74.973Hz";
|
||||
position = "1920,0";
|
||||
}
|
||||
{
|
||||
criteria = "Philips Consumer Electronics Company PHL 272S1 UHB2347026535";
|
||||
mode = "1920x1080@74.973Hz";
|
||||
position = "3840,0";
|
||||
}
|
||||
];
|
||||
}
|
||||
];
|
||||
};
|
||||
};
|
||||
|
||||
systemd.user = {
|
||||
services = {
|
||||
wayland-pipewire-idle-inhibit = {
|
||||
Unit.Description = "inhibit sleep while audio output is active";
|
||||
Service = {
|
||||
ExecStart = "${lib.getExe pkgs.wayland-pipewire-idle-inhibit}";
|
||||
Restart = "always";
|
||||
RestartSec = 10;
|
||||
};
|
||||
Install = {
|
||||
WantedBy = [ "graphical-session.target" ];
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
||||
@@ -1,58 +0,0 @@
|
||||
{ lib
|
||||
, pkgs
|
||||
, ...
|
||||
}:
|
||||
let
|
||||
chromium_discord = pkgs.writeShellScriptBin "chromium_discord" ''
|
||||
${lib.getExe pkgs.ungoogled-chromium} --socket=wayland org.chromium.Chromium --app=https://discordapp.com/channels/@me
|
||||
'';
|
||||
in
|
||||
{
|
||||
home.packages =
|
||||
with pkgs;
|
||||
[
|
||||
cached-nix-shell
|
||||
deluge
|
||||
dualsensectl
|
||||
ffmpeg-full
|
||||
firefox
|
||||
freetube
|
||||
imv
|
||||
inkscape
|
||||
jellyfin-media-player
|
||||
kodi-wayland
|
||||
libnotify
|
||||
libreoffice-qt6-fresh
|
||||
libva-utils
|
||||
nixpkgs-fmt
|
||||
nix-prefetch-git
|
||||
pandoc
|
||||
paraview
|
||||
pass-wayland
|
||||
pavucontrol
|
||||
pay-respects
|
||||
pirate-get
|
||||
poppler_utils
|
||||
pulsemixer
|
||||
pwvucontrol
|
||||
python3
|
||||
remmina
|
||||
rtorrent
|
||||
sioyek
|
||||
steam-run
|
||||
stremio
|
||||
swayimg
|
||||
tessen
|
||||
ungoogled-chromium
|
||||
wdisplays
|
||||
wine
|
||||
wl-clipboard
|
||||
wlr-randr
|
||||
wofi
|
||||
yt-dlp
|
||||
zathura
|
||||
]
|
||||
++ [
|
||||
chromium_discord
|
||||
];
|
||||
}
|
||||
@@ -1,363 +0,0 @@
|
||||
{ lib
|
||||
, pkgs
|
||||
, ...
|
||||
}:
|
||||
let
|
||||
qutebrowser_firejail = pkgs.writeShellScriptBin "qutebrowser" ''
|
||||
firejail -- ${lib.getExe pkgs.qutebrowser} "$@"
|
||||
'';
|
||||
in
|
||||
{
|
||||
imports = [
|
||||
../common/zsh.nix
|
||||
../common/i3status-rust.nix
|
||||
../common/sway.nix
|
||||
../common/i3.nix
|
||||
./home_packages.nix
|
||||
../common/whatsapp-for-linux.nix
|
||||
];
|
||||
|
||||
home.stateVersion = "22.11";
|
||||
home.username = "akill";
|
||||
home.homeDirectory = "/home/akill";
|
||||
|
||||
xdg.enable = true;
|
||||
xdg.mimeApps = {
|
||||
enable = true;
|
||||
defaultApplications = {
|
||||
"application/pdf" = "sioyek.desktop";
|
||||
"default-web-browser" = "org.qutebrowser.qutebrowser.desktop";
|
||||
"text/html" = "org.qutebrowser.qutebrowser.desktop";
|
||||
"x-scheme-handler/about" = "org.qutebrowser.qutebrowser.desktop";
|
||||
"x-scheme-handler/http" = "org.qutebrowser.qutebrowser.desktop";
|
||||
"x-scheme-handler/https" = "org.qutebrowser.qutebrowser.desktop";
|
||||
"x-scheme-handler/unknown" = "org.qutebrowser.qutebrowser.desktop";
|
||||
};
|
||||
};
|
||||
|
||||
fonts.fontconfig.enable = true;
|
||||
|
||||
home.sessionVariables = rec {
|
||||
BROWSER = lib.getExe qutebrowser_firejail;
|
||||
DEFAULT_BROWSER = "${BROWSER}";
|
||||
EDITOR = "nvim";
|
||||
_JAVA_AWT_WM_NONREPARENTING = "1";
|
||||
MOZ_ENABLE_WAYLAND = "1";
|
||||
NIXOS_OZONE_WL = "1";
|
||||
QT_WAYLAND_DISABLE_WINDOWDECORATION = "1";
|
||||
SUDO_EDITOR = "nvim";
|
||||
WLR_RENDERER = "vulkan";
|
||||
};
|
||||
|
||||
home.pointerCursor = {
|
||||
package = pkgs.adwaita-icon-theme;
|
||||
name = "Adwaita";
|
||||
size = 38;
|
||||
};
|
||||
|
||||
wayland.windowManager.sway = {
|
||||
enable = true;
|
||||
};
|
||||
|
||||
programs = {
|
||||
home-manager.enable = true;
|
||||
|
||||
librewolf = {
|
||||
enable = true;
|
||||
settings = {
|
||||
"webgl.disable" = true;
|
||||
"middlemouse.paste" = false;
|
||||
};
|
||||
};
|
||||
|
||||
tmux = {
|
||||
enable = true;
|
||||
clock24 = true;
|
||||
keyMode = "vi";
|
||||
terminal = "screen-256color";
|
||||
plugins = with pkgs.tmuxPlugins; [
|
||||
sysstat
|
||||
net-speed
|
||||
gruvbox
|
||||
];
|
||||
};
|
||||
|
||||
mpv = {
|
||||
enable = true;
|
||||
scripts = [
|
||||
pkgs.mpvScripts.uosc
|
||||
pkgs.mpvScripts.autosubsync-mpv
|
||||
];
|
||||
config = {
|
||||
osc = "no";
|
||||
osd-bar = "no";
|
||||
border = "no";
|
||||
slang = "eng,en";
|
||||
alang = "eng,en";
|
||||
hwdec = "auto";
|
||||
vo = "gpu-next";
|
||||
ao = "pipewire";
|
||||
ytdl-format = "bestvideo[height<=?1080]+bestaudio/best";
|
||||
};
|
||||
|
||||
bindings = {
|
||||
"s" = "script-binding uosc/subtitles";
|
||||
"a" = "script-binding uosc/audio";
|
||||
WHEEL_UP = "ignore";
|
||||
WHEEL_DOWN = "ignore";
|
||||
WHEEL_LEFT = "ignore";
|
||||
WHEEL_RIGHT = "ignore";
|
||||
};
|
||||
};
|
||||
|
||||
alacritty = {
|
||||
enable = true;
|
||||
|
||||
settings = {
|
||||
font = {
|
||||
normal.family = "JetBrainsMono";
|
||||
italic.family = "JetBrainsMono";
|
||||
bold.family = "JetBrainsMono";
|
||||
bold_italic.family = "JetBrainsMono";
|
||||
size = 14.0;
|
||||
};
|
||||
|
||||
selection = {
|
||||
text = "0xcfcfc2";
|
||||
background = "0x232629";
|
||||
|
||||
normal = {
|
||||
black = "0x1c1b19";
|
||||
red = "0xef2f27";
|
||||
green = "0x519f50";
|
||||
yellow = "0xfbb829";
|
||||
blue = "0x2c78bf";
|
||||
magenta = "0xe02c6d";
|
||||
cyan = "0x0aaeb3";
|
||||
white = "0x918175";
|
||||
};
|
||||
|
||||
bright = {
|
||||
black = "0x2D2C29";
|
||||
red = "0xf75341";
|
||||
green = "0x98bc37";
|
||||
yellow = "0xfed06e";
|
||||
blue = "0x68A8E4";
|
||||
magenta = "0xff5c8f";
|
||||
cyan = "0x53fde9";
|
||||
white = "0xfce8c3";
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
rofi = {
|
||||
enable = true;
|
||||
theme = "gruvbox-dark";
|
||||
};
|
||||
|
||||
foot = {
|
||||
enable = true;
|
||||
server.enable = true;
|
||||
settings = {
|
||||
main = {
|
||||
font = "JetBrainsMono:size=10";
|
||||
dpi-aware = "yes";
|
||||
};
|
||||
mouse = {
|
||||
hide-when-typing = "yes";
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
qutebrowser = {
|
||||
enable = true;
|
||||
keyBindings = {
|
||||
normal = {
|
||||
"j" = "scroll-px 0 25";
|
||||
"k" = "scroll-px 0 -25";
|
||||
"u" = "undo --window";
|
||||
";v" = "hint links spawn mpv {hint-url}";
|
||||
};
|
||||
};
|
||||
|
||||
settings = {
|
||||
content.notifications.enabled = false;
|
||||
content.pdfjs = true;
|
||||
content.webgl = false;
|
||||
fonts.completion.category = "14pt monospace";
|
||||
fonts.completion.entry = "14pt monospace";
|
||||
fonts.contextmenu = "14pt monospace";
|
||||
fonts.debug_console = "14pt monospace";
|
||||
fonts.downloads = "14pt monospace";
|
||||
fonts.hints = "14pt monospace";
|
||||
fonts.keyhint = "14pt monospace";
|
||||
fonts.messages.info = "14pt monospace";
|
||||
fonts.prompts = "14pt monospace";
|
||||
fonts.statusbar = "14pt monospace";
|
||||
hints.chars = "1qaz2wsx3edc4rfv5tgb6yhn7ujm8ik9ol0p";
|
||||
tabs.last_close = "close";
|
||||
tabs.position = "left";
|
||||
tabs.show = "multiple";
|
||||
tabs.tabs_are_windows = true;
|
||||
tabs.width = "12%";
|
||||
zoom.default = "125%";
|
||||
};
|
||||
};
|
||||
|
||||
git = {
|
||||
enable = true;
|
||||
settings = {
|
||||
user = {
|
||||
name = "Asmir A";
|
||||
email = "asmir.abdulahovic@gmail.com";
|
||||
};
|
||||
init.defaultBranch = "master";
|
||||
pull = {
|
||||
rebase = true;
|
||||
};
|
||||
credential = {
|
||||
helper = "store";
|
||||
};
|
||||
};
|
||||
signing.key = "020C42B7A9ABA3E2";
|
||||
signing.signByDefault = true;
|
||||
};
|
||||
|
||||
obs-studio = {
|
||||
enable = true;
|
||||
plugins = with pkgs.obs-studio-plugins; [
|
||||
obs-vkcapture
|
||||
input-overlay
|
||||
obs-multi-rtmp
|
||||
obs-pipewire-audio-capture
|
||||
wlrobs
|
||||
obs-vaapi
|
||||
];
|
||||
};
|
||||
|
||||
i3status-rust.enable = true;
|
||||
z-lua.enable = true;
|
||||
zsh.enable = true;
|
||||
};
|
||||
|
||||
services = {
|
||||
lorri.enable = false;
|
||||
mako.enable = true;
|
||||
cliphist.enable = true;
|
||||
gammastep = {
|
||||
enable = true;
|
||||
latitude = "44.53";
|
||||
longitude = "18.67";
|
||||
temperature.day = 5500;
|
||||
temperature.night = 2900;
|
||||
};
|
||||
|
||||
gnome-keyring.enable = true;
|
||||
|
||||
gpg-agent = {
|
||||
enable = true;
|
||||
defaultCacheTtl = 1800;
|
||||
enableSshSupport = true;
|
||||
};
|
||||
|
||||
swayidle =
|
||||
let
|
||||
locker = pkgs.writeShellScriptBin "swaylock_fancy" ''
|
||||
ALL_IMGS=""
|
||||
LOCK_ARGS=""
|
||||
for OUTPUT in $(${pkgs.sway}/bin/swaymsg -t get_outputs | ${lib.getExe pkgs.jq} -r '.[].name')
|
||||
do
|
||||
TMP_FILE=$(${pkgs.coreutils}/bin/mktemp /tmp/.swaylock_ss_XXXXXX.jpg)
|
||||
${lib.getExe pkgs.grim} -t ppm -o $OUTPUT - | \
|
||||
${lib.getExe pkgs.ffmpeg} -y -loglevel 0 -i - -vframes 1 -vf "boxblur=10" "$TMP_FILE"
|
||||
LOCK_ARGS="$LOCK_ARGS --image $OUTPUT:$TMP_FILE"
|
||||
ALL_IMGS="$ALL_IMGS $TMP_FILE"
|
||||
done
|
||||
${lib.getExe pkgs.swaylock} -f $LOCK_ARGS
|
||||
${pkgs.coreutils}/bin/shred $ALL_IMGS
|
||||
${pkgs.coreutils}/bin/rm $ALL_IMGS
|
||||
'';
|
||||
in
|
||||
/*
|
||||
refresh_i3status = pkgs.writeShellScriptBin "refresh_i3status" ''
|
||||
${pkgs.coreutils}/bin/sleep 1 && ${pkgs.procps}/bin/pkill -USR1 i3status-rs
|
||||
'';
|
||||
*/
|
||||
{
|
||||
enable = true;
|
||||
events = [
|
||||
{
|
||||
event = "before-sleep";
|
||||
command = "${locker}/bin/swaylock_fancy";
|
||||
}
|
||||
{
|
||||
event = "lock";
|
||||
command = "${locker}/bin/swaylock_fancy";
|
||||
}
|
||||
/*
|
||||
{
|
||||
event = "after-resume";
|
||||
command = "${refresh_i3status}/bin/refresh_i3status";
|
||||
}
|
||||
*/
|
||||
];
|
||||
timeouts = [
|
||||
{
|
||||
timeout = 15 * 60;
|
||||
command = "${locker}/bin/swaylock_fancy";
|
||||
}
|
||||
];
|
||||
};
|
||||
|
||||
kanshi = {
|
||||
enable = true;
|
||||
settings = [
|
||||
{
|
||||
profile.name = "undocked";
|
||||
profile.outputs = [
|
||||
{
|
||||
criteria = "eDP-1";
|
||||
}
|
||||
];
|
||||
}
|
||||
|
||||
{
|
||||
profile.name = "docked";
|
||||
profile.outputs = [
|
||||
{
|
||||
criteria = "eDP-1";
|
||||
position = "0,0";
|
||||
}
|
||||
{
|
||||
criteria = "Philips Consumer Electronics Company PHL 272S1 UHB2347026536";
|
||||
mode = "1920x1080@74.973Hz";
|
||||
position = "1920,0";
|
||||
}
|
||||
{
|
||||
criteria = "Philips Consumer Electronics Company PHL 272S1 UHB2347026535";
|
||||
mode = "1920x1080@74.973Hz";
|
||||
position = "3840,0";
|
||||
}
|
||||
];
|
||||
}
|
||||
];
|
||||
};
|
||||
};
|
||||
|
||||
systemd.user = {
|
||||
services = {
|
||||
wayland-pipewire-idle-inhibit = {
|
||||
Unit.Description = "inhibit sleep while audio output is active";
|
||||
Service = {
|
||||
ExecStart = "${lib.getExe pkgs.wayland-pipewire-idle-inhibit}";
|
||||
Restart = "always";
|
||||
RestartSec = 10;
|
||||
};
|
||||
Install = {
|
||||
WantedBy = [ "graphical-session.target" ];
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
||||
@@ -1,183 +0,0 @@
|
||||
{
|
||||
lib,
|
||||
pkgs,
|
||||
inputs,
|
||||
system,
|
||||
...
|
||||
}:
|
||||
let
|
||||
chromium_teams = pkgs.writeShellScriptBin "chromium_teams" ''
|
||||
${lib.getExe pkgs.ungoogled-chromium} --socket=wayland org.chromium.Chromium --app=https://teams.microsoft.com/
|
||||
'';
|
||||
chromium_discord = pkgs.writeShellScriptBin "chromium_discord" ''
|
||||
${lib.getExe pkgs.ungoogled-chromium} --socket=wayland org.chromium.Chromium --app=https://discordapp.com/channels/@me
|
||||
'';
|
||||
chromium_stackfield = pkgs.writeShellScriptBin "chromium_stackfield" ''
|
||||
${lib.getExe pkgs.ungoogled-chromium} --socket=wayland org.chromium.Chromium --app=https://stackfield.com/
|
||||
'';
|
||||
nixy_switch = pkgs.writeShellScriptBin "nixy_switch" ''
|
||||
${pkgs.util-linux}/bin/ionice -c 3 -- \
|
||||
${pkgs.coreutils}/bin/nice -n 20 -- \
|
||||
${lib.getExe pkgs.nixos-rebuild} --flake ./#nixy switch
|
||||
'';
|
||||
qcad = pkgs.writeShellScriptBin "qcad" ''
|
||||
QT_QPA_PLATFORM=xcb ${lib.getExe pkgs.qcad} $@
|
||||
'';
|
||||
ssh_proxy = pkgs.writeShellScriptBin "ssh_proxy" ''
|
||||
if ${pkgs.coreutils}/bin/test $# -ne 1; then
|
||||
echo "Usage: $0 <user>@<ssh_host>"
|
||||
exit
|
||||
fi
|
||||
PROXY_PORT="1337"
|
||||
${lib.getExe pkgs.openssh} -D "$PROXY_PORT" -q -N "$@"
|
||||
'';
|
||||
wrap_sh =
|
||||
let
|
||||
bubblewrap = pkgs.callPackage ../../packages/bubblewrap/default.nix { };
|
||||
in
|
||||
pkgs.writeShellScriptBin "wrap.sh" ''
|
||||
if ${pkgs.coreutils-full}/bin/test $# -ne 1; then
|
||||
echo "Usage: $0 <directory>"
|
||||
exit
|
||||
fi
|
||||
FULL_PATH=$(${pkgs.coreutils-full}/bin/realpath "$1")
|
||||
BUBBLEWRAP_DIR="$1" ${bubblewrap}/bin/bwrap \
|
||||
--bind / / \
|
||||
--dev /dev \
|
||||
--overlay-src "$FULL_PATH" \
|
||||
--tmp-overlay "$FULL_PATH" \
|
||||
"$SHELL"
|
||||
'';
|
||||
in
|
||||
{
|
||||
home.packages =
|
||||
with pkgs;
|
||||
[
|
||||
anydesk
|
||||
appimage-run
|
||||
arp-scan
|
||||
birdtray
|
||||
blackmagic
|
||||
blender
|
||||
btop
|
||||
cached-nix-shell
|
||||
caddy
|
||||
cargo
|
||||
cmake
|
||||
compsize
|
||||
kdePackages.ark
|
||||
ungoogled-chromium
|
||||
cura-appimage
|
||||
deluge
|
||||
dfu-util
|
||||
discord
|
||||
dmenu-wayland
|
||||
drawio
|
||||
dualsensectl
|
||||
ffmpeg-full
|
||||
firefox
|
||||
freecad
|
||||
gcc
|
||||
gdb
|
||||
ghostscript
|
||||
glab
|
||||
glaxnimate
|
||||
gnumake
|
||||
go
|
||||
grim
|
||||
heimdall
|
||||
hyperfine
|
||||
icestorm
|
||||
imagemagick
|
||||
imv
|
||||
inkscape
|
||||
#jellyfin-media-player
|
||||
kdePackages.kdenlive
|
||||
kicad
|
||||
kodi-wayland
|
||||
krita
|
||||
libnotify
|
||||
libreoffice-qt6-fresh
|
||||
libva-utils
|
||||
perf
|
||||
lsix
|
||||
lsix
|
||||
mediainfo
|
||||
ncdu
|
||||
neovide
|
||||
nextpnr
|
||||
ngspice
|
||||
nix-init
|
||||
nixpkgs-fmt
|
||||
nix-prefetch-git
|
||||
nom
|
||||
openems
|
||||
openocd
|
||||
openscad
|
||||
pandoc
|
||||
#paraview
|
||||
pass-wayland
|
||||
patchelf
|
||||
pavucontrol
|
||||
pay-respects
|
||||
pirate-get
|
||||
poppler-utils
|
||||
powertop
|
||||
pulsemixer
|
||||
pwvucontrol
|
||||
python3
|
||||
python3Packages.west
|
||||
qucs-s
|
||||
radeontop
|
||||
remmina
|
||||
river-classic
|
||||
rizin
|
||||
rtorrent
|
||||
sbcl
|
||||
screen
|
||||
seer
|
||||
sioyek
|
||||
slurp
|
||||
steam-run
|
||||
stm32cubemx
|
||||
swayimg
|
||||
tea
|
||||
teams-for-linux
|
||||
tectonic
|
||||
tessen
|
||||
texlive.combined.scheme-full
|
||||
thunderbird
|
||||
typst
|
||||
upx
|
||||
viber
|
||||
waybar
|
||||
wdisplays
|
||||
weechat
|
||||
wasistlos
|
||||
wine
|
||||
wireshark
|
||||
wl-clipboard
|
||||
wlr-randr
|
||||
wofi
|
||||
x2goclient
|
||||
yewtube
|
||||
yosys
|
||||
yt-dlp
|
||||
zapzap
|
||||
zathura
|
||||
zig
|
||||
]
|
||||
++ [
|
||||
chromium_discord
|
||||
chromium_stackfield
|
||||
chromium_teams
|
||||
nixy_switch
|
||||
qcad
|
||||
ssh_proxy
|
||||
wrap_sh
|
||||
]
|
||||
++ [
|
||||
inputs.swaysw.packages.${system}.swaysw
|
||||
(pkgs.callPackage ../../packages/bubblewrap/default.nix { })
|
||||
];
|
||||
}
|
||||
@@ -1,10 +1,11 @@
|
||||
{ pkgs
|
||||
, inputs
|
||||
, system
|
||||
, lib
|
||||
, ...
|
||||
}:
|
||||
let
|
||||
{
|
||||
config,
|
||||
pkgs,
|
||||
inputs,
|
||||
system,
|
||||
lib,
|
||||
...
|
||||
}: let
|
||||
cliphist_sway = pkgs.writeShellScriptBin "cliphist_sway" ''
|
||||
${lib.getExe pkgs.cliphist} list | \
|
||||
${lib.getExe pkgs.wofi} --dmenu --insensitive | \
|
||||
@@ -15,29 +16,15 @@ let
|
||||
GEOM="$(${lib.getExe pkgs.slurp} -d)"
|
||||
${lib.getExe pkgs.grim} -g "$GEOM" - | ${pkgs.wl-clipboard}/bin/wl-copy
|
||||
'';
|
||||
switch_laptop_mode = pkgs.writeShellScriptBin "switch_laptop_mode" ''
|
||||
${pkgs.procps}/bin/pkill rot8 && \
|
||||
${pkgs.sway}/bin/swaymsg output eDP-1 transform 0
|
||||
'';
|
||||
switch_tablet_mode = pkgs.writeShellScriptBin "switch_tablet_mode" ''
|
||||
${lib.getExe pkgs.rot8} \
|
||||
--invert-y \
|
||||
--hooks ''\'systemctl --user restart lisgd.service''\'
|
||||
'';
|
||||
swaysw = inputs.swaysw.packages.${system}.swaysw;
|
||||
viber = pkgs.callPackage ../packages/viber/default.nix {};
|
||||
term = "${pkgs.foot}/bin/footclient";
|
||||
in
|
||||
{
|
||||
in {
|
||||
wayland.windowManager.sway = {
|
||||
enable = true;
|
||||
extraSessionCommands = "";
|
||||
extraConfigEarly = '''';
|
||||
|
||||
extraConfig = ''
|
||||
bindswitch tablet:on exec ${switch_tablet_mode}/bin/switch_tablet_mode
|
||||
bindswitch tablet:off exec ${switch_laptop_mode}/bin/switch_laptop_mode
|
||||
'';
|
||||
|
||||
config = {
|
||||
fonts = {
|
||||
names = ["JetBrainsMono"];
|
||||
@@ -48,21 +35,15 @@ in
|
||||
window.commands = [
|
||||
{
|
||||
command = "move scratchpad, resize set 1152 648";
|
||||
criteria = {
|
||||
app_id = "pulsemixer|python3|com.rtosta.zapzap|whatsapp-for-linux|com.viber";
|
||||
};
|
||||
criteria = {app_id = "pulsemixer|python3|com.rtosta.zapzap|whatsapp-for-linux|com.viber";};
|
||||
}
|
||||
{
|
||||
command = "move scratchpad, resize set 1502 845";
|
||||
criteria = {
|
||||
app_id = "com.viber";
|
||||
};
|
||||
criteria = {app_id = "com.viber";};
|
||||
}
|
||||
{
|
||||
command = "floating enable";
|
||||
criteria = {
|
||||
app_id = "sws_cli";
|
||||
};
|
||||
criteria = {app_id = "sws_cli";};
|
||||
}
|
||||
];
|
||||
|
||||
@@ -81,25 +62,16 @@ in
|
||||
};
|
||||
|
||||
input = {
|
||||
"type:keyboard" = {
|
||||
repeat_delay = "150";
|
||||
};
|
||||
"type:keyboard" = {
|
||||
repeat_rate = "70";
|
||||
};
|
||||
"type:touchpad" = {
|
||||
tap = "enabled";
|
||||
};
|
||||
"type:keyboard" = {repeat_delay = "150";};
|
||||
"type:keyboard" = {repeat_rate = "70";};
|
||||
"type:touchpad" = {tap = "enabled";};
|
||||
};
|
||||
|
||||
bars = [
|
||||
{
|
||||
position = "top";
|
||||
fonts = {
|
||||
names = [
|
||||
"Iosevka"
|
||||
"FontAwesome"
|
||||
];
|
||||
names = ["Iosevka" "FontAwesome"];
|
||||
style = "Bold Semi-Condensed";
|
||||
size = 12.0;
|
||||
};
|
||||
@@ -111,8 +83,8 @@ in
|
||||
"Alt+Shift+q" = "kill";
|
||||
"Alt+Shift+Return" = "exec ${term}";
|
||||
"Alt+p" = "exec ${pkgs.bemenu}/bin/bemenu-run";
|
||||
"Alt+c" = "exec ${pkgs.moreutils}/bin/lckdo /tmp/.cliphist_sway.lck ${cliphist_sway}/bin/cliphist_sway";
|
||||
"Print" = "exec ${pkgs.moreutils}/bin/lckdo /tmp/.screenshot_clip.lck ${screenshot_clip}/bin/screenshot_clip";
|
||||
"Alt+c" = "exec ${pkgs.moreutils}/bin/lckdo cliphist_sway ${cliphist_sway}/bin/cliphist_sway";
|
||||
"Print" = "exec ${pkgs.moreutils}/bin/lckdo screenshot_clip ${screenshot_clip}/bin/screenshot_clip";
|
||||
|
||||
"Alt+Shift+space" = "floating toggle";
|
||||
"Alt+space" = "focus mode_toggle";
|
||||
@@ -147,20 +119,18 @@ in
|
||||
"Alt+j" = "focus down";
|
||||
"Alt+k" = "focus up";
|
||||
"Alt+l" = "focus right";
|
||||
"Alt+slash" = "exec ${pkgs.moreutils}/bin/lckdo /tmp/.swaysw.lck ${swaysw}/bin/swaysw";
|
||||
"Alt+slash" = "exec ${pkgs.moreutils}/bin/lckdo swaysw ${swaysw}/bin/swaysw";
|
||||
"Alt+Escape" = "workspace back_and_forth";
|
||||
"Alt+f" = "fullscreen enable";
|
||||
"Alt+bracketright" = "focus output right";
|
||||
"Alt+bracketleft" = "focus output left";
|
||||
|
||||
"Mod4+l" =
|
||||
''exec ${pkgs.sway}/bin/swaymsg [app_id="python3"] scratchpad show || exec ${term} -a python3 ${lib.getExe pkgs.python3}'';
|
||||
"Mod4+j" =
|
||||
"exec ${pkgs.sway}/bin/swaymsg [app_id=com.rtosta.zapzap] scratchpad show || exec ${lib.getExe pkgs.zapzap}";
|
||||
"Mod4+h" =
|
||||
"exec ${pkgs.sway}/bin/swaymsg [app_id=com.viber] scratchpad show || exec ${pkgs.viber}/bin/viber";
|
||||
"Mod4+y" =
|
||||
''exec ${pkgs.sway}/bin/swaymsg [app_id="pulsemixer"] scratchpad show || exec ${term} -a pulsemixer ${lib.getExe pkgs.pulsemixer}'';
|
||||
"Mod4+l" = ''
|
||||
exec ${pkgs.sway}/bin/swaymsg [app_id="python3"] scratchpad show || exec ${term} -a python3 ${lib.getExe pkgs.python3}'';
|
||||
"Mod4+h" = "exec ${pkgs.sway}/bin/swaymsg [app_id=com.rtosta.zapzap] scratchpad show || exec ${lib.getExe pkgs.zapzap}";
|
||||
"Mod4+j" = "exec ${pkgs.sway}/bin/swaymsg [app_id=com.viber] scratchpad show || exec ${viber}/bin/viber";
|
||||
"Mod4+y" = ''
|
||||
exec ${pkgs.sway}/bin/swaymsg [app_id="pulsemixer"] scratchpad show || exec ${term} -a pulsemixer ${lib.getExe pkgs.pulsemixer}'';
|
||||
"Mod4+p" = "exec ${lib.getExe pkgs.tessen} -a copy";
|
||||
};
|
||||
};
|
||||
@@ -1,6 +1,5 @@
|
||||
{lib, ...}:
|
||||
with lib;
|
||||
{
|
||||
with lib; {
|
||||
xdg.configFile."whatsapp-for-linux/settings.conf".source = builtins.toFile "settings.conf" (
|
||||
generators.toINI {} {
|
||||
General = {
|
||||
103
home/zsh.nix
Normal file
103
home/zsh.nix
Normal file
@@ -0,0 +1,103 @@
|
||||
{pkgs, ...}: {
|
||||
programs.z-lua = {
|
||||
enableAliases = true;
|
||||
enableZshIntegration = true;
|
||||
};
|
||||
|
||||
programs.zsh = {
|
||||
autocd = true;
|
||||
enableCompletion = false;
|
||||
syntaxHighlighting.enable = true;
|
||||
defaultKeymap = "viins";
|
||||
|
||||
shellAliases = {
|
||||
cfind = "cscope -C -R -L1";
|
||||
chmod = "chmod -v";
|
||||
chown = "chown -v";
|
||||
cp = "cp -v";
|
||||
rm = "rm -v";
|
||||
ip = "ip --color=auto";
|
||||
f = "''$(pay-respects zsh)";
|
||||
};
|
||||
|
||||
history = {
|
||||
expireDuplicatesFirst = true;
|
||||
extended = true;
|
||||
save = 100000;
|
||||
size = 100000;
|
||||
};
|
||||
|
||||
plugins = [
|
||||
{
|
||||
name = "nix_shell";
|
||||
src = pkgs.zsh-nix-shell;
|
||||
file = "share/zsh-nix-shell/nix-shell.plugin.zsh";
|
||||
}
|
||||
{
|
||||
name = "nix_completion";
|
||||
src = pkgs.nix-zsh-completions;
|
||||
file = "share/zsh/plugins/nix/nix-zsh-completions.plugin.zsh";
|
||||
}
|
||||
{
|
||||
name = "pure_prompt";
|
||||
src = pkgs.fetchFromGitHub {
|
||||
owner = "sindresorhus";
|
||||
repo = "pure";
|
||||
rev = "a02209d36c8509c0e62f44324127632999c9c0cf";
|
||||
hash = "sha256-BmQO4xqd/3QnpLUitD2obVxL0UulpboT8jGNEh4ri8k=";
|
||||
};
|
||||
file = "pure.plugin.zsh";
|
||||
}
|
||||
{
|
||||
name = "fzf";
|
||||
src = pkgs.fzf-zsh;
|
||||
file = "share/zsh/plugins/fzf-zsh/fzf-zsh.plugin.zsh";
|
||||
}
|
||||
{
|
||||
name = "zsh-sudo";
|
||||
src = pkgs.fetchFromGitHub {
|
||||
owner = "hcgraf";
|
||||
repo = "zsh-sudo";
|
||||
rev = "d8084def6bb1bde2482e7aa636743f40c69d9b32";
|
||||
sha256 = "1dpm51w3wjxil8sxqw4qxim5kmf6afmkwz1yfhldpdlqm7rfwpi3";
|
||||
};
|
||||
file = "sudo.plugin.zsh";
|
||||
}
|
||||
];
|
||||
|
||||
envExtra = '''';
|
||||
|
||||
initExtra = ''
|
||||
# binds
|
||||
bindkey '^K' fzf-file-widget
|
||||
|
||||
# options
|
||||
setopt nobeep
|
||||
setopt nopromptcr
|
||||
setopt c_bases
|
||||
setopt completeinword
|
||||
setopt completealiases
|
||||
setopt notify
|
||||
|
||||
#
|
||||
RPS1=""
|
||||
|
||||
#
|
||||
function chpwd() {
|
||||
ls;
|
||||
}
|
||||
|
||||
eval "$(direnv hook zsh)"
|
||||
zstyle ':completion:*' matcher-list 'm:{a-z}={A-Za-z}'
|
||||
|
||||
if [[ -n "$PS1" ]] && [[ -z "$TMUX" ]] && [[ -n "$SSH_CONNECTION" ]]; then
|
||||
TMUX_EXE="${pkgs.tmux}/bin/tmux"
|
||||
systemd-run --scope --user $TMUX_EXE attach-session -t $USER || systemd-run --scope --user $TMUX_EXE new-session -s $USER
|
||||
fi
|
||||
|
||||
if [[ -n "$BUBBLEWRAP_DIR" ]]; then
|
||||
RPS1="{{$BUBBLEWRAP_DIR}}"
|
||||
fi
|
||||
'';
|
||||
};
|
||||
}
|
||||
@@ -1,29 +1,27 @@
|
||||
{ config
|
||||
, pkgs
|
||||
, lib
|
||||
, project-cloud
|
||||
, nvim
|
||||
, system
|
||||
, ...
|
||||
}:
|
||||
{
|
||||
config,
|
||||
pkgs,
|
||||
lib,
|
||||
project-cloud,
|
||||
nvim,
|
||||
system,
|
||||
...
|
||||
}: {
|
||||
imports = [];
|
||||
|
||||
nix.optimise.automatic = true;
|
||||
nix.settings.experimental-features = [
|
||||
"nix-command"
|
||||
"flakes"
|
||||
];
|
||||
nix.settings.experimental-features = ["nix-command" "flakes"];
|
||||
system.switch = {
|
||||
enable = false;
|
||||
enableNg = true;
|
||||
};
|
||||
|
||||
# Use the systemd-boot EFI boot loader.
|
||||
boot.loader.systemd-boot.enable = true;
|
||||
boot.loader.systemd-boot.configurationLimit = 2;
|
||||
boot.loader.efi.canTouchEfiVariables = true;
|
||||
boot.kernelPackages = pkgs.linuxPackages_latest;
|
||||
boot.kernelParams = [
|
||||
"ip=dhcp"
|
||||
"console=tty"
|
||||
];
|
||||
boot.kernelParams = ["ip=dhcp"];
|
||||
boot.kernel.sysctl = {
|
||||
"net.core.default_qdisc" = "fq";
|
||||
"net.ipv4.tcp_congestion_control" = "bbr";
|
||||
@@ -31,10 +29,7 @@
|
||||
|
||||
boot.initrd = {
|
||||
compressor = "zstd";
|
||||
availableKernelModules = [
|
||||
"virtio-pci"
|
||||
"virtio-gpu"
|
||||
];
|
||||
availableKernelModules = ["virtio-pci"];
|
||||
systemd.enable = true;
|
||||
network = {
|
||||
enable = true;
|
||||
@@ -75,23 +70,14 @@
|
||||
|
||||
programs.mosh.enable = true;
|
||||
|
||||
/* Srv settings found on SrvOS */
|
||||
fonts.fontconfig.enable = lib.mkDefault false;
|
||||
xdg.autostart.enable = lib.mkDefault false;
|
||||
xdg.icons.enable = lib.mkDefault false;
|
||||
xdg.menus.enable = lib.mkDefault false;
|
||||
xdg.mime.enable = lib.mkDefault false;
|
||||
xdg.sounds.enable = lib.mkDefault false;
|
||||
|
||||
mailserver = {
|
||||
enable = true;
|
||||
debug.all = false;
|
||||
debug = false;
|
||||
fqdn = "mail.project-cloud.net";
|
||||
domains = ["project-cloud.net"];
|
||||
enableSubmissionSsl = true;
|
||||
enableImap = false;
|
||||
enableImapSsl = true;
|
||||
stateVersion = 3;
|
||||
|
||||
# A list of all login accounts. To create the password hashes, use
|
||||
# nix-shell -p mkpasswd --run 'mkpasswd -sm bcrypt'
|
||||
@@ -109,7 +95,7 @@
|
||||
};
|
||||
|
||||
services.journald.extraConfig = ''SystemMaxUse=50M '';
|
||||
services.logind.settings.Login = { KillUserProcesses = true; };
|
||||
services.logind.extraConfig = ''KillUserProcesses=yes '';
|
||||
services.openssh.settings.PermitRootLogin = "prohibit-password";
|
||||
services.openssh.enable = true;
|
||||
services.openssh.listenAddresses = [
|
||||
@@ -118,11 +104,7 @@
|
||||
port = 22;
|
||||
}
|
||||
];
|
||||
|
||||
services.opendkim = {
|
||||
enable = true;
|
||||
selector = "mail";
|
||||
};
|
||||
services.opendkim.enable = true;
|
||||
|
||||
services.miniflux = {
|
||||
enable = false;
|
||||
@@ -173,6 +155,7 @@
|
||||
|
||||
services.nginx = {
|
||||
enable = true;
|
||||
package = pkgs.nginxQuic;
|
||||
recommendedGzipSettings = true;
|
||||
recommendedOptimisation = true;
|
||||
recommendedProxySettings = true;
|
||||
@@ -253,21 +236,22 @@
|
||||
REGISTER_EMAIL_CONFIRM = true;
|
||||
};
|
||||
|
||||
settings."markup.restructuredtext" =
|
||||
let
|
||||
docutils = pkgs.python3.withPackages (
|
||||
ps: with ps; [
|
||||
docutils
|
||||
pygments
|
||||
]
|
||||
);
|
||||
in
|
||||
{
|
||||
settings."markup.restructuredtext" = let
|
||||
docutils =
|
||||
pkgs.python3.withPackages (ps: with ps; [docutils pygments]);
|
||||
in {
|
||||
ENABLED = true;
|
||||
FILE_EXTENSIONS = ".rst";
|
||||
RENDER_COMMAND = "${docutils}/bin/rst2html.py";
|
||||
IS_INPUT_FILE = false;
|
||||
};
|
||||
|
||||
settings."markup.typst" = {
|
||||
ENABLED = true;
|
||||
FILE_EXTENSIONS = ".typ";
|
||||
RENDER_COMMAND = "timeout 30s ${lib.getExe pkgs.python3Packages.pygments} -f html -O full";
|
||||
IS_INPUT_FILE = false;
|
||||
};
|
||||
};
|
||||
|
||||
services.nfs.server.enable = false;
|
||||
@@ -296,7 +280,15 @@
|
||||
startAt = "daily";
|
||||
};
|
||||
|
||||
# needed for sendmail mail functionality
|
||||
services.seafile = {
|
||||
enable = false;
|
||||
initialAdminPassword = "admin";
|
||||
adminEmail = "asmir.abdulahovic" + "@" + "gmail.com";
|
||||
};
|
||||
|
||||
/*
|
||||
needed for sendmail mail functionality
|
||||
*/
|
||||
users.users.gitea.extraGroups = ["postdrop"];
|
||||
systemd.services.gitea.serviceConfig = {
|
||||
RestrictAddressFamilies = ["AF_NETLINK"];
|
||||
@@ -334,28 +326,16 @@
|
||||
};
|
||||
|
||||
networking.hostName = "magpie";
|
||||
networking.nftables.enable = true;
|
||||
networking.firewall = {
|
||||
enable = true;
|
||||
allowedTCPPorts = [
|
||||
80
|
||||
443
|
||||
587
|
||||
2049
|
||||
]; # http, mail, mail, nfs
|
||||
allowedUDPPorts = [
|
||||
443
|
||||
51820
|
||||
]; # mail, wireguard
|
||||
allowPing = true;
|
||||
logRefusedConnections = lib.mkDefault false;
|
||||
};
|
||||
|
||||
networking.nat = {
|
||||
enable = true;
|
||||
externalInterface = "enp1s0";
|
||||
internalInterfaces = [ "wg0" ];
|
||||
};
|
||||
networking.firewall.enable = true;
|
||||
networking.firewall.allowedTCPPorts = [80 443 587 2049]; # http, mail, mail, nfs
|
||||
networking.firewall.allowedUDPPorts = [443 51820]; #mail, wireguard
|
||||
networking.firewall.allowPing = true;
|
||||
networking.firewall.logRefusedConnections = lib.mkDefault false;
|
||||
|
||||
networking.nat.enable = true;
|
||||
networking.nat.externalInterface = "enp1s0";
|
||||
networking.nat.internalInterfaces = ["wg0"];
|
||||
|
||||
networking.networkmanager.enable = true;
|
||||
networking.wireless.enable = false;
|
||||
@@ -367,13 +347,13 @@
|
||||
|
||||
# This allows the wireguard server to route your traffic to the internet and hence be like a VPN
|
||||
# For this to work you have to set the dnsserver IP of your router (or dnsserver of choice) in your clients
|
||||
#postSetup = ''
|
||||
# ${pkgs.nftables}/bin/nft add rule ip nat POSTROUTING oifname "eth0" ip saddr 10.100.0.0/24 counter masquerade
|
||||
#'';
|
||||
# This undoes the above command, TODO fix command below to be more specific
|
||||
#postShutdown = ''
|
||||
# ${pkgs.nftables}/bin/nft flush table ip nat
|
||||
#'';
|
||||
postSetup = ''
|
||||
${pkgs.iptables}/bin/iptables -t nat -A POSTROUTING -s 10.100.0.0/24 -o eth0 -j MASQUERADE
|
||||
'';
|
||||
# This undoes the above command
|
||||
postShutdown = ''
|
||||
${pkgs.iptables}/bin/iptables -t nat -D POSTROUTING -s 10.100.0.0/24 -o eth0 -j MASQUERADE
|
||||
'';
|
||||
privateKeyFile = config.sops.secrets."wg_privkey".path;
|
||||
|
||||
peers = [
|
||||
|
||||
@@ -5,18 +5,12 @@
|
||||
lib,
|
||||
modulesPath,
|
||||
...
|
||||
}:
|
||||
{
|
||||
}: {
|
||||
imports = [
|
||||
(modulesPath + "/installer/scan/not-detected.nix")
|
||||
];
|
||||
|
||||
boot.initrd.availableKernelModules = [
|
||||
"xhci_pci"
|
||||
"virtio_pci"
|
||||
"usbhid"
|
||||
"sr_mod"
|
||||
];
|
||||
boot.initrd.availableKernelModules = ["xhci_pci" "virtio_pci" "usbhid" "sr_mod"];
|
||||
boot.initrd.kernelModules = [];
|
||||
boot.kernelModules = [];
|
||||
boot.extraModulePackages = [];
|
||||
|
||||
@@ -1,22 +1,18 @@
|
||||
{ config
|
||||
, nvim
|
||||
, pkgs
|
||||
, system
|
||||
, zremap
|
||||
, ...
|
||||
}:
|
||||
let
|
||||
USER = "akill";
|
||||
in
|
||||
# Edit this configuration file to define what should be installed on
|
||||
# your system. Help is available in the configuration.nix(5) man page
|
||||
# and in the NixOS manual (accessible by running ‘nixos-help’).
|
||||
{
|
||||
config,
|
||||
pkgs,
|
||||
zremap,
|
||||
system,
|
||||
nvim,
|
||||
...
|
||||
}: {
|
||||
imports = [];
|
||||
|
||||
system.stateVersion = "23.05";
|
||||
system.autoUpgrade.enable = false;
|
||||
system.switch = {
|
||||
enable = true;
|
||||
enableNg = true;
|
||||
};
|
||||
|
||||
sops.age.sshKeyPaths = ["/etc/ssh/ssh_host_ed25519_key"];
|
||||
sops.secrets."peerix/private" = {
|
||||
@@ -40,11 +36,7 @@ in
|
||||
gc.options = "--delete-older-than 7d";
|
||||
package = pkgs.nixVersions.latest;
|
||||
settings = {
|
||||
experimental-features = [
|
||||
"nix-command"
|
||||
"flakes"
|
||||
];
|
||||
trusted-users = [ "akill" "root" ];
|
||||
experimental-features = ["nix-command" "flakes"];
|
||||
};
|
||||
};
|
||||
|
||||
@@ -78,36 +70,26 @@ in
|
||||
readOnlyNixStore = true;
|
||||
supportedFilesystems = ["btrfs"];
|
||||
tmp.useTmpfs = true;
|
||||
tmp.tmpfsSize = "80%";
|
||||
};
|
||||
|
||||
security = {
|
||||
rtkit.enable = true;
|
||||
allowSimultaneousMultithreading = true;
|
||||
sudo.enable = true;
|
||||
doas.enable = true;
|
||||
doas.extraRules = [
|
||||
{
|
||||
users = [ USER ];
|
||||
keepEnv = true;
|
||||
persist = true;
|
||||
}
|
||||
];
|
||||
acme = {
|
||||
acceptTerms = true;
|
||||
defaults.email = "aasmir@gmx.com";
|
||||
};
|
||||
};
|
||||
|
||||
powerManagement = {
|
||||
enable = true;
|
||||
cpuFreqGovernor = "ondemand";
|
||||
};
|
||||
|
||||
networking = {
|
||||
nftables.enable = true;
|
||||
firewall = {
|
||||
enable = true;
|
||||
allowedTCPPorts = [
|
||||
80
|
||||
443
|
||||
51820
|
||||
8020
|
||||
];
|
||||
allowedTCPPorts = [80 443 51820];
|
||||
};
|
||||
|
||||
hostName = "mediabox";
|
||||
@@ -116,21 +98,16 @@ in
|
||||
useDHCP = false;
|
||||
wireless.enable = false;
|
||||
wireless.interfaces = ["wlp3s0"];
|
||||
nameservers = [
|
||||
"127.0.0.1"
|
||||
"::1"
|
||||
];
|
||||
nameservers = ["127.0.0.1" "::1"];
|
||||
dhcpcd.extraConfig = "nohook resolv.conf";
|
||||
|
||||
networkmanager.dns = "none";
|
||||
extraHosts = ''
|
||||
192.168.1.173 nixy.lan
|
||||
192.168.88.171 jellyfin.mediabox.lan
|
||||
192.168.88.171 jellyseerr.mediabox.lan
|
||||
192.168.88.171 mediabox.lan
|
||||
192.168.88.171 qbittorrent.mediabox.lan
|
||||
192.168.88.1 router.lan
|
||||
192.168.88.231 workstation.lan
|
||||
192.168.88.121 ender.lan
|
||||
'';
|
||||
|
||||
wireguard.interfaces = {
|
||||
@@ -161,47 +138,44 @@ in
|
||||
};
|
||||
};
|
||||
|
||||
programs = {
|
||||
steam = {
|
||||
enable = true;
|
||||
remotePlay.openFirewall = true;
|
||||
dedicatedServer.openFirewall = false;
|
||||
localNetworkGameTransfers.openFirewall = true;
|
||||
};
|
||||
gnupg.agent = {
|
||||
programs.gnupg.agent = {
|
||||
enable = true;
|
||||
enableSSHSupport = true;
|
||||
};
|
||||
appimage = {
|
||||
enable = true;
|
||||
binfmt = true;
|
||||
};
|
||||
nix-ld = {
|
||||
enable = false;
|
||||
libraries = with pkgs; [
|
||||
stdenv.cc.cc.lib
|
||||
zlib
|
||||
];
|
||||
};
|
||||
zsh.enable = true;
|
||||
firejail.enable = true;
|
||||
};
|
||||
programs.zsh.enable = true;
|
||||
programs.light.enable = true;
|
||||
programs.firejail.enable = true;
|
||||
programs.adb.enable = false;
|
||||
programs.wireshark.enable = true;
|
||||
programs.sway.enable = true;
|
||||
|
||||
# List services that you want to enable:
|
||||
systemd = {
|
||||
services = {
|
||||
"zremap@" = {
|
||||
enable = true;
|
||||
restartIfChanged = true;
|
||||
"macchanger-wireless" = {
|
||||
after = ["sys-subsystem-net-devices-wlp3s0.device"];
|
||||
before = ["network-pre.target"];
|
||||
bindsTo = ["sys-subsystem-net-devices-wlp3s0.device"];
|
||||
description = "Changes MAC of my wireless interface for privacy reasons";
|
||||
stopIfChanged = false;
|
||||
wantedBy = ["multi-user.target"];
|
||||
wants = ["network-pre.target"];
|
||||
script = ''
|
||||
${pkgs.macchanger}/bin/macchanger -e wlp3s0 || true
|
||||
'';
|
||||
serviceConfig.Type = "oneshot";
|
||||
};
|
||||
|
||||
"zremap" = {
|
||||
description = "Intercepts keyboard udev events";
|
||||
wants = ["systemd-udevd.service"];
|
||||
wantedBy = ["multi-user.target"];
|
||||
serviceConfig.Nice = -20;
|
||||
unitConfig = {
|
||||
Description = "zremap on %I";
|
||||
ConditionPathExists = "%I";
|
||||
};
|
||||
serviceConfig = {
|
||||
Type = "simple";
|
||||
ExecStart = "${zremap.defaultPackage.${system}}/bin/zremap %I";
|
||||
};
|
||||
script = ''
|
||||
sleep 1
|
||||
${zremap.defaultPackage.${system}}/bin/zremap \
|
||||
/dev/input/by-path/platform-i8042-serio-0-event-kbd
|
||||
'';
|
||||
};
|
||||
|
||||
"wakeonlan" = {
|
||||
@@ -211,32 +185,33 @@ in
|
||||
Type = "oneshot";
|
||||
ExecStart = "${pkgs.ethtool}/sbin/ethtool -s enp0s25 wol m";
|
||||
};
|
||||
wantedBy = [
|
||||
"default.target"
|
||||
"suspend.target"
|
||||
"shutdown.target"
|
||||
];
|
||||
};
|
||||
wantedBy = ["default.target" "suspend.target" "shutdown.target"];
|
||||
};
|
||||
|
||||
coredump.enable = false;
|
||||
extraConfig = ''
|
||||
DefaultTimeoutStartSec=30s
|
||||
DefaultTimeoutStopSec=30s
|
||||
/*
|
||||
"cpu_setting" = {
|
||||
description = "Enable turboot boost and undervolt cpu after suspend";
|
||||
wantedBy = ["post-resume.target" "multi-user.target"];
|
||||
after = ["post-resume.target"];
|
||||
script = ''
|
||||
echo 1 > /sys/devices/system/cpu/intel_pstate/no_turbo
|
||||
echo 0 > /sys/devices/system/cpu/intel_pstate/no_turbo
|
||||
${pkgs.undervolt}/bin/undervolt --core -105 --cache -105 --uncore -105 --gpu -15 -p1 47 28 -p2 57 0.0025
|
||||
'';
|
||||
serviceConfig.Type = "oneshot";
|
||||
};
|
||||
*/
|
||||
};
|
||||
};
|
||||
|
||||
services = {
|
||||
acpid.enable = true;
|
||||
btrfs.autoScrub.enable = true;
|
||||
dbus.enable = true;
|
||||
dbus.implementation = "broker";
|
||||
envfs.enable = true;
|
||||
fstrim.enable = true;
|
||||
fwupd.enable = true;
|
||||
ntp.enable = true;
|
||||
openssh.enable = true;
|
||||
openssh.settings.PermitRootLogin = "yes";
|
||||
thinkfan.enable = false;
|
||||
|
||||
xrdp = {
|
||||
@@ -250,13 +225,13 @@ in
|
||||
};
|
||||
|
||||
jellyfin = {
|
||||
enable = false;
|
||||
enable = true;
|
||||
user = "akill";
|
||||
openFirewall = true;
|
||||
};
|
||||
|
||||
jellyseerr = {
|
||||
enable = false;
|
||||
enable = true;
|
||||
openFirewall = true;
|
||||
};
|
||||
|
||||
@@ -267,105 +242,58 @@ in
|
||||
pulse.enable = true;
|
||||
};
|
||||
|
||||
avahi = {
|
||||
deluge = {
|
||||
enable = false;
|
||||
nssmdns4 = false;
|
||||
user = "akill";
|
||||
openFirewall = true;
|
||||
};
|
||||
|
||||
libinput.enable = true;
|
||||
xserver = {
|
||||
dataDir = "/home/akill/.config/deluge";
|
||||
web = {
|
||||
enable = true;
|
||||
dpi = 144;
|
||||
desktopManager.xterm.enable = false;
|
||||
desktopManager.plasma5.bigscreen.enable = true;
|
||||
#desktopManager.plasma6.enable = true;
|
||||
displayManager = {
|
||||
lightdm.enable = false;
|
||||
startx.enable = true;
|
||||
sddm.enable = true;
|
||||
sddm.wayland.enable = true;
|
||||
openFirewall = false;
|
||||
};
|
||||
config = {
|
||||
download_location = "/media";
|
||||
allow_remote = true;
|
||||
daemon_port = 58846;
|
||||
};
|
||||
windowManager.i3.enable = false;
|
||||
};
|
||||
|
||||
udev = {
|
||||
packages = [ ];
|
||||
extraRules = ''
|
||||
#zremap on new keyboard
|
||||
ACTION=="add", SUBSYSTEM=="input", ATTRS{phys}!="", KERNEL=="event[0-9]*", ENV{ID_INPUT_KEY}=="1", ENV{ID_INPUT_KEYBOARD}=="1", TAG+="systemd", ENV{SYSTEMD_WANTS}+="zremap@$env{DEVNAME}.service"
|
||||
'';
|
||||
};
|
||||
|
||||
tlp = {
|
||||
transmission = {
|
||||
enable = false;
|
||||
};
|
||||
|
||||
batteryNotifier = {
|
||||
enable = false;
|
||||
notifyCapacity = 20;
|
||||
suspendCapacity = 10;
|
||||
};
|
||||
|
||||
actkbd = {
|
||||
enable = true;
|
||||
bindings = [
|
||||
{
|
||||
keys = [ 115 ];
|
||||
events = [ "key" ];
|
||||
command = "XDG_RUNTIME_DIR=/run/user/$(id -u ${USER}) ${pkgs.wireplumber}/bin/wpctl set-volume @DEFAULT_AUDIO_SINK@ 5%+";
|
||||
}
|
||||
|
||||
{
|
||||
keys = [ 114 ];
|
||||
events = [
|
||||
"key"
|
||||
"rep"
|
||||
];
|
||||
command = "XDG_RUNTIME_DIR=/run/user/$(id -u ${USER}) ${pkgs.wireplumber}/bin/wpctl set-volume @DEFAULT_AUDIO_SINK@ 5%-";
|
||||
}
|
||||
|
||||
{
|
||||
keys = [ 113 ];
|
||||
events = [
|
||||
"key"
|
||||
"rep"
|
||||
];
|
||||
command = "XDG_RUNTIME_DIR=/run/user/$(id -u ${USER}) ${pkgs.wireplumber}/bin/wpctl set-mute @DEFAULT_AUDIO_SINK@ toggle";
|
||||
}
|
||||
|
||||
{
|
||||
keys = [ 224 ];
|
||||
events = [ "key" ];
|
||||
command = "${pkgs.light}/bin/light -U 5";
|
||||
}
|
||||
|
||||
{
|
||||
keys = [ 225 ];
|
||||
events = [ "key" ];
|
||||
command = "${pkgs.light}/bin/light -A 5";
|
||||
}
|
||||
];
|
||||
};
|
||||
|
||||
dnscrypt-proxy2 = {
|
||||
enable = true;
|
||||
openFirewall = true;
|
||||
settings = {
|
||||
ipv6_servers = true;
|
||||
require_dnssec = true;
|
||||
require_nolog = true;
|
||||
require_nofilter = true;
|
||||
http3 = true;
|
||||
|
||||
sources.public-resolvers = {
|
||||
urls = [
|
||||
"https://raw.githubusercontent.com/DNSCrypt/dnscrypt-resolvers/master/v3/public-resolvers.md"
|
||||
"https://download.dnscrypt.info/resolvers-list/v3/public-resolvers.md"
|
||||
];
|
||||
cache_file = "/var/lib/dnscrypt-proxy/public-resolvers.md";
|
||||
minisign_key = "RWQf6LRCGA9i53mlYecO4IzT51TGPpvWucNSCh1CBM0QTaLn73Y7GFO3";
|
||||
rpc-whitelist = "192.168.88.*";
|
||||
download-dir = "/media";
|
||||
};
|
||||
};
|
||||
|
||||
qbittorrent = {
|
||||
enable = true;
|
||||
user = "akill";
|
||||
openFirewall = true;
|
||||
dataDir = "/home/akill/.config/qbittorrent";
|
||||
port = 8081;
|
||||
};
|
||||
|
||||
nginx = {
|
||||
enable = true;
|
||||
recommendedGzipSettings = true;
|
||||
recommendedOptimisation = true;
|
||||
recommendedProxySettings = true;
|
||||
recommendedTlsSettings = true;
|
||||
|
||||
virtualHosts."deluge.mediabox.lan" = {
|
||||
locations."/".proxyPass = "http://localhost:8112/";
|
||||
};
|
||||
virtualHosts."qbittorrent.mediabox.lan" = {
|
||||
locations."/".proxyPass = "http://localhost:8081/";
|
||||
};
|
||||
virtualHosts."jellyfin.mediabox.lan" = {
|
||||
locations."/".proxyPass = "http://localhost:8096/";
|
||||
};
|
||||
virtualHosts."jellyseerr.mediabox.lan" = {
|
||||
locations."/".proxyPass = "http://localhost:5055/";
|
||||
};
|
||||
};
|
||||
|
||||
journald.extraConfig = ''
|
||||
@@ -376,53 +304,114 @@ in
|
||||
KillUserProcesses=yes
|
||||
'';
|
||||
|
||||
xserver = {
|
||||
enable = true;
|
||||
libinput.enable = true;
|
||||
desktopManager.xterm.enable = false;
|
||||
displayManager.lightdm.enable = false;
|
||||
displayManager.defaultSession = "none+icewm";
|
||||
windowManager.icewm.enable = true;
|
||||
};
|
||||
|
||||
fonts = {
|
||||
fontconfig = {
|
||||
cache32Bit = true;
|
||||
allowBitmaps = true;
|
||||
useEmbeddedBitmaps = true;
|
||||
defaultFonts = {
|
||||
monospace = [ "JetBrainsMono" ];
|
||||
};
|
||||
udev.packages = [];
|
||||
|
||||
tlp = {
|
||||
enable = true;
|
||||
settings = {};
|
||||
};
|
||||
|
||||
packages = with pkgs; [
|
||||
dejavu_fonts
|
||||
dina-font
|
||||
fira-code
|
||||
fira-code-symbols
|
||||
font-awesome_6
|
||||
inconsolata
|
||||
iosevka
|
||||
jetbrains-mono
|
||||
liberation_ttf
|
||||
libertine
|
||||
noto-fonts
|
||||
noto-fonts-cjk-sans
|
||||
noto-fonts-color-emoji
|
||||
noto-fonts-emoji
|
||||
proggyfonts
|
||||
siji
|
||||
terminus_font
|
||||
terminus_font_ttf
|
||||
ubuntu_font_family
|
||||
vistafonts
|
||||
actkbd = {
|
||||
enable = true;
|
||||
bindings = [
|
||||
{
|
||||
keys = [121];
|
||||
events = ["key"];
|
||||
command = "${pkgs.alsaUtils}/bin/amixer -q set Master toggle";
|
||||
}
|
||||
{
|
||||
keys = [122];
|
||||
events = ["key" "rep"];
|
||||
command = "${pkgs.alsaUtils}/bin/amixer -q set Master ${config.sound.mediaKeys.volumeStep}- unmute";
|
||||
}
|
||||
{
|
||||
keys = [123];
|
||||
events = ["key" "rep"];
|
||||
command = "${pkgs.alsaUtils}/bin/amixer -q set Master ${config.sound.mediaKeys.volumeStep}+ unmute";
|
||||
}
|
||||
{
|
||||
keys = [224];
|
||||
events = ["key"];
|
||||
command = "/run/current-system/sw/bin/light -U 5";
|
||||
}
|
||||
{
|
||||
keys = [225];
|
||||
events = ["key"];
|
||||
command = "/run/current-system/sw/bin/light -A 5";
|
||||
}
|
||||
];
|
||||
};
|
||||
|
||||
mpd = {
|
||||
musicDirectory = "/home/mpd/music";
|
||||
enable = false;
|
||||
extraConfig = ''
|
||||
audio_output {
|
||||
type "pulse"
|
||||
name "pulsee srv"
|
||||
server "127.0.0.1"
|
||||
}
|
||||
'';
|
||||
};
|
||||
|
||||
batteryNotifier = {
|
||||
enable = true;
|
||||
notifyCapacity = 20;
|
||||
suspendCapacity = 10;
|
||||
};
|
||||
|
||||
dnscrypt-proxy2 = {
|
||||
enable = true;
|
||||
settings = {
|
||||
ipv6_servers = true;
|
||||
require_dnssec = true;
|
||||
|
||||
sources.public-resolvers = {
|
||||
urls = [
|
||||
"https://raw.githubusercontent.com/DNSCrypt/dnscrypt-resolvers/master/v3/public-resolvers.md"
|
||||
"https://download.dnscrypt.info/resolvers-list/v3/public-resolvers.md"
|
||||
];
|
||||
cache_file = "/var/lib/dnscrypt-proxy/public-resolvers.md";
|
||||
minisign_key = "RWQf6LRCGA9i53mlYecO4IzT51TGPpvWucNSCh1CBM0QTaLn73Y7GFO3";
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
fonts.packages = with pkgs; [
|
||||
dina-font
|
||||
fira-code
|
||||
fira-code-symbols
|
||||
font-awesome
|
||||
font-awesome_4
|
||||
iosevka
|
||||
jetbrains-mono
|
||||
liberation_ttf
|
||||
proggyfonts
|
||||
siji
|
||||
];
|
||||
|
||||
virtualisation = {
|
||||
podman = {
|
||||
enable = false;
|
||||
autoPrune.enable = true;
|
||||
enable = true;
|
||||
dockerCompat = true;
|
||||
};
|
||||
};
|
||||
|
||||
sound.enable = true;
|
||||
|
||||
hardware = {
|
||||
bluetooth = {
|
||||
enable = true;
|
||||
enable = false;
|
||||
settings = {
|
||||
General = {
|
||||
Enable = "Source,Sink,Media,Socket";
|
||||
@@ -430,9 +419,14 @@ in
|
||||
};
|
||||
};
|
||||
|
||||
graphics = {
|
||||
opengl = {
|
||||
enable = true;
|
||||
extraPackages = [ ];
|
||||
driSupport = true;
|
||||
driSupport32Bit = true;
|
||||
extraPackages = with pkgs; [
|
||||
intel-media-driver
|
||||
vaapiIntel
|
||||
];
|
||||
};
|
||||
};
|
||||
|
||||
@@ -441,15 +435,10 @@ in
|
||||
algorithm = "zstd";
|
||||
};
|
||||
|
||||
users.users.${USER} = {
|
||||
users.users.akill = {
|
||||
isNormalUser = true;
|
||||
shell = pkgs.zsh;
|
||||
extraGroups = [
|
||||
"wheel"
|
||||
"tty"
|
||||
"audio"
|
||||
"sound"
|
||||
];
|
||||
extraGroups = ["wireshark" "wheel" "kvm" "tty" "audio" "sound" "adbusers" "transmission"];
|
||||
openssh.authorizedKeys.keys = [
|
||||
(builtins.readFile ../nixy/ssh_pubkey)
|
||||
];
|
||||
@@ -458,12 +447,7 @@ in
|
||||
users.users.ado = {
|
||||
isNormalUser = true;
|
||||
shell = pkgs.zsh;
|
||||
extraGroups = [
|
||||
"wheel"
|
||||
"tty"
|
||||
"audio"
|
||||
"sound"
|
||||
];
|
||||
extraGroups = ["wireshark" "wheel" "kvm" "tty" "audio" "sound" "adbusers" "transmission"];
|
||||
};
|
||||
|
||||
users.users.mediauser = {
|
||||
|
||||
@@ -5,20 +5,12 @@
|
||||
lib,
|
||||
modulesPath,
|
||||
...
|
||||
}:
|
||||
{
|
||||
}: {
|
||||
imports = [
|
||||
(modulesPath + "/installer/scan/not-detected.nix")
|
||||
];
|
||||
|
||||
boot.initrd.availableKernelModules = [
|
||||
"xhci_pci"
|
||||
"ehci_pci"
|
||||
"ahci"
|
||||
"usb_storage"
|
||||
"sd_mod"
|
||||
"rtsx_pci_sdmmc"
|
||||
];
|
||||
boot.initrd.availableKernelModules = ["xhci_pci" "ehci_pci" "ahci" "usb_storage" "sd_mod" "rtsx_pci_sdmmc"];
|
||||
boot.initrd.kernelModules = [];
|
||||
boot.kernelModules = ["kvm-intel"];
|
||||
boot.extraModulePackages = [];
|
||||
@@ -26,11 +18,7 @@
|
||||
fileSystems."/" = {
|
||||
device = "/dev/disk/by-uuid/ae774285-60dc-4b08-ab26-8208e8f4e81e";
|
||||
fsType = "btrfs";
|
||||
options = [
|
||||
"subvol=root"
|
||||
"compress=lzo"
|
||||
"noatime"
|
||||
];
|
||||
options = ["subvol=root" "compress=lzo" "noatime"];
|
||||
};
|
||||
|
||||
boot.initrd.luks.devices."enc".device = "/dev/disk/by-uuid/60aa7671-bfee-451b-b871-ac7c5a4a9f3a";
|
||||
@@ -38,41 +26,25 @@
|
||||
fileSystems."/home" = {
|
||||
device = "/dev/disk/by-uuid/ae774285-60dc-4b08-ab26-8208e8f4e81e";
|
||||
fsType = "btrfs";
|
||||
options = [
|
||||
"subvol=home"
|
||||
"compress=lzo"
|
||||
"noatime"
|
||||
];
|
||||
options = ["subvol=home" "compress=lzo" "noatime"];
|
||||
};
|
||||
|
||||
fileSystems."/nix" = {
|
||||
device = "/dev/disk/by-uuid/ae774285-60dc-4b08-ab26-8208e8f4e81e";
|
||||
fsType = "btrfs";
|
||||
options = [
|
||||
"subvol=nix"
|
||||
"compress=lzo"
|
||||
"noatime"
|
||||
];
|
||||
options = ["subvol=nix" "compress=lzo" "noatime"];
|
||||
};
|
||||
|
||||
fileSystems."/persist" = {
|
||||
device = "/dev/disk/by-uuid/ae774285-60dc-4b08-ab26-8208e8f4e81e";
|
||||
fsType = "btrfs";
|
||||
options = [
|
||||
"subvol=persist"
|
||||
"compress=lzo"
|
||||
"noatime"
|
||||
];
|
||||
options = ["subvol=persist" "compress=lzo" "noatime"];
|
||||
};
|
||||
|
||||
fileSystems."/var/log" = {
|
||||
device = "/dev/disk/by-uuid/ae774285-60dc-4b08-ab26-8208e8f4e81e";
|
||||
fsType = "btrfs";
|
||||
options = [
|
||||
"subvol=log"
|
||||
"compress=lzo"
|
||||
"noatime"
|
||||
];
|
||||
options = ["subvol=log" "compress=lzo" "noatime"];
|
||||
neededForBoot = true;
|
||||
};
|
||||
|
||||
|
||||
@@ -2,8 +2,7 @@
|
||||
config,
|
||||
pkgs,
|
||||
...
|
||||
}:
|
||||
{
|
||||
}: {
|
||||
# Enable Nginx
|
||||
services.nginx = {
|
||||
enable = true;
|
||||
|
||||
@@ -4,13 +4,11 @@
|
||||
pkgs,
|
||||
...
|
||||
}:
|
||||
with lib;
|
||||
let
|
||||
with lib; let
|
||||
cfg = config.services.qbittorrent;
|
||||
configDir = "${cfg.dataDir}/.config";
|
||||
openFilesLimit = 4096;
|
||||
in
|
||||
{
|
||||
in {
|
||||
options.services.qbittorrent = {
|
||||
enable = mkOption {
|
||||
type = types.bool;
|
||||
@@ -112,10 +110,7 @@ in
|
||||
};
|
||||
};
|
||||
|
||||
users.groups = mkIf (cfg.group == "qbittorrent") {
|
||||
qbittorrent = {
|
||||
gid = null;
|
||||
};
|
||||
};
|
||||
users.groups =
|
||||
mkIf (cfg.group == "qbittorrent") {qbittorrent = {gid = null;};};
|
||||
};
|
||||
}
|
||||
|
||||
@@ -1,21 +1,19 @@
|
||||
{ config
|
||||
, nvim
|
||||
, pkgs
|
||||
, system
|
||||
, zremap
|
||||
, ...
|
||||
}:
|
||||
let
|
||||
USER = "akill";
|
||||
in
|
||||
{
|
||||
config,
|
||||
nix-xilinx,
|
||||
nvim,
|
||||
pkgs,
|
||||
system,
|
||||
zremap,
|
||||
...
|
||||
}: {
|
||||
imports = [];
|
||||
|
||||
system = {
|
||||
stateVersion = "23.05";
|
||||
autoUpgrade.enable = false;
|
||||
etc.overlay.enable = true;
|
||||
nixos-init.enable = true;
|
||||
system.stateVersion = "23.05";
|
||||
system.autoUpgrade.enable = false;
|
||||
system.switch = {
|
||||
enable = false;
|
||||
enableNg = true;
|
||||
};
|
||||
|
||||
sops = {
|
||||
@@ -46,12 +44,12 @@ in
|
||||
|
||||
"borgbase_enc_key" = {
|
||||
sopsFile = ./secrets/borgbase_enc_key.yaml;
|
||||
owner = config.users.users.${USER}.name;
|
||||
owner = config.users.users.akill.name;
|
||||
};
|
||||
|
||||
"borgbase_ssh_key" = {
|
||||
sopsFile = ./secrets/borgbase_ssh_key.yaml;
|
||||
owner = config.users.users.${USER}.name;
|
||||
owner = config.users.users.akill.name;
|
||||
};
|
||||
};
|
||||
};
|
||||
@@ -63,36 +61,21 @@ in
|
||||
package = pkgs.nixVersions.latest;
|
||||
settings = {
|
||||
sandbox = true;
|
||||
experimental-features = [
|
||||
"nix-command"
|
||||
"flakes"
|
||||
];
|
||||
experimental-features = ["nix-command" "flakes"];
|
||||
};
|
||||
};
|
||||
|
||||
boot = {
|
||||
extraModulePackages = with config.boot.kernelPackages; [
|
||||
usbip
|
||||
v4l2loopback
|
||||
];
|
||||
extraModulePackages = with config.boot.kernelPackages; [usbip v4l2loopback];
|
||||
initrd.compressor = "zstd";
|
||||
initrd.kernelModules = [];
|
||||
initrd.systemd.enable = true;
|
||||
binfmt.emulatedSystems = [
|
||||
"wasm32-wasi"
|
||||
"x86_64-windows"
|
||||
];
|
||||
kernelParams = [
|
||||
"psmouse.synaptics_intertouch=0"
|
||||
"mem_sleep_default=deep"
|
||||
"amdgpu.sg_display=0"
|
||||
"amdgpu.gttsize=2048"
|
||||
];
|
||||
binfmt.emulatedSystems = ["wasm32-wasi" "x86_64-windows"];
|
||||
kernelPackages = pkgs.linuxPackages_latest;
|
||||
kernelParams = ["psmouse.synaptics_intertouch=0" "mem_sleep_default=deep"];
|
||||
kernel.sysctl = {
|
||||
"net.core.default_qdisc" = "fq";
|
||||
"net.ipv4.tcp_congestion_control" = "bbr";
|
||||
"kernel.unprivileged_userns_clone" = "1"; /* Needed with harderned kernel */
|
||||
};
|
||||
loader.efi.canTouchEfiVariables = true;
|
||||
loader.systemd-boot = {
|
||||
@@ -100,10 +83,8 @@ in
|
||||
enable = true;
|
||||
memtest86.enable = true;
|
||||
};
|
||||
nixStoreMountOpts = [ "ro" ];
|
||||
supportedFilesystems = [
|
||||
"xfs"
|
||||
];
|
||||
readOnlyNixStore = true;
|
||||
supportedFilesystems = ["f2fs" "xfs"];
|
||||
tmp.useTmpfs = true;
|
||||
};
|
||||
|
||||
@@ -114,7 +95,7 @@ in
|
||||
doas.enable = true;
|
||||
doas.extraRules = [
|
||||
{
|
||||
users = [ USER ];
|
||||
users = ["akill"];
|
||||
keepEnv = true;
|
||||
persist = true;
|
||||
}
|
||||
@@ -126,22 +107,13 @@ in
|
||||
};
|
||||
|
||||
networking = {
|
||||
nftables.enable = true;
|
||||
firewall = {
|
||||
enable = true;
|
||||
allowedTCPPorts = [
|
||||
80
|
||||
443
|
||||
51820
|
||||
8020
|
||||
];
|
||||
allowedTCPPorts = [80 443 51820 8020];
|
||||
};
|
||||
|
||||
hostName = "nixy";
|
||||
nameservers = [
|
||||
"127.0.0.1"
|
||||
"::1"
|
||||
];
|
||||
nameservers = ["127.0.0.1" "::1"];
|
||||
dhcpcd.extraConfig = "nohook resolv.conf";
|
||||
|
||||
extraHosts = ''
|
||||
@@ -203,9 +175,7 @@ in
|
||||
time.timeZone = "Europe/Sarajevo";
|
||||
|
||||
nixpkgs.config.allowUnfree = true;
|
||||
nixpkgs.overlays = [
|
||||
nvim.overlays.${system}.overlay
|
||||
];
|
||||
nixpkgs.overlays = [nix-xilinx.overlay nvim.overlays.${system}.overlay];
|
||||
environment = {
|
||||
etc = {
|
||||
"firejail/qutebrowser.local".text = ''
|
||||
@@ -236,13 +206,6 @@ in
|
||||
enable = true;
|
||||
binfmt = true;
|
||||
};
|
||||
nix-ld = {
|
||||
enable = false;
|
||||
libraries = with pkgs; [
|
||||
stdenv.cc.cc.lib
|
||||
zlib
|
||||
];
|
||||
};
|
||||
zsh.enable = true;
|
||||
firejail.enable = true;
|
||||
adb.enable = true;
|
||||
@@ -254,15 +217,7 @@ in
|
||||
|
||||
# List services that you want to enable:
|
||||
systemd = {
|
||||
#sysusers.enable = true;
|
||||
services = {
|
||||
# Fix issue where systemd-vconsole-setup failes to find keymap
|
||||
systemd-vconsole-setup = {
|
||||
unitConfig = {
|
||||
After = "local-fs.target";
|
||||
};
|
||||
};
|
||||
|
||||
"zremap@" = {
|
||||
enable = true;
|
||||
restartIfChanged = true;
|
||||
@@ -292,9 +247,9 @@ in
|
||||
description = "wg network interface";
|
||||
bindsTo = ["netns@wg.service"];
|
||||
requires = ["network-online.target"];
|
||||
wants = [ "dnscrypt-proxy_proton.service" ];
|
||||
wants = ["dnscrypt-proxy2_proton.service"];
|
||||
after = ["netns@wg.service"];
|
||||
before = [ "dnscrypt-proxy_proton.service" ];
|
||||
before = ["dnscrypt-proxy2_proton.service"];
|
||||
serviceConfig = {
|
||||
Type = "oneshot";
|
||||
RemainAfterExit = true;
|
||||
@@ -305,9 +260,7 @@ in
|
||||
${pkgs.iproute2}/bin/ip link set proton_wg netns wg
|
||||
${pkgs.iproute2}/bin/ip -n wg address add 10.2.0.2/32 dev proton_wg
|
||||
${pkgs.iproute2}/bin/ip netns exec wg \
|
||||
${pkgs.wireguard-tools}/bin/wg set "proton_wg" private-key "${
|
||||
config.sops.secrets."wg_privkey_proton".path
|
||||
}"
|
||||
${pkgs.wireguard-tools}/bin/wg set "proton_wg" private-key "${config.sops.secrets."wg_privkey_proton".path}"
|
||||
${pkgs.iproute2}/bin/ip netns exec wg \
|
||||
${pkgs.wireguard-tools}/bin/wg set "proton_wg" peer "g6DkXWKI/68RsLjROIwCEcyB/ZhyK5Q7OWcz1TtqER0=" \
|
||||
endpoint "$ENDPOINT_IP:51820" \
|
||||
@@ -324,7 +277,7 @@ in
|
||||
};
|
||||
};
|
||||
|
||||
"dnscrypt-proxy_proton" = {
|
||||
"dnscrypt-proxy2_proton" = {
|
||||
description = "DNSCrypt-proxy client proton";
|
||||
wants = [
|
||||
"network-online.target"
|
||||
@@ -337,7 +290,7 @@ in
|
||||
AmbientCapabilities = "CAP_NET_BIND_SERVICE";
|
||||
CacheDirectory = "dnscrypt-proxy";
|
||||
DynamicUser = true;
|
||||
ExecStart = "${pkgs.dnscrypt-proxy}/bin/dnscrypt-proxy -config ${config.services.dnscrypt-proxy.configFile}";
|
||||
ExecStart = "${pkgs.dnscrypt-proxy}/bin/dnscrypt-proxy -config ${config.services.dnscrypt-proxy2.configFile}";
|
||||
LockPersonality = true;
|
||||
LogsDirectory = "dnscrypt-proxy";
|
||||
MemoryDenyWriteExecute = true;
|
||||
@@ -376,24 +329,21 @@ in
|
||||
};
|
||||
};
|
||||
|
||||
coredump.enable = false;
|
||||
settings.Manager = {
|
||||
DefaultTimeoutStartSec = "30s";
|
||||
DefaultTimeoutStopSec = "30s";
|
||||
};
|
||||
extraConfig = ''
|
||||
DefaultTimeoutStartSec=30s
|
||||
DefaultTimeoutStopSec=30s
|
||||
'';
|
||||
};
|
||||
|
||||
services = {
|
||||
acpid.enable = true;
|
||||
dbus.enable = true;
|
||||
dbus.implementation = "broker";
|
||||
envfs.enable = true;
|
||||
fstrim.enable = true;
|
||||
fwupd.enable = true;
|
||||
ntp.enable = true;
|
||||
openssh.enable = true;
|
||||
printing.enable = true;
|
||||
userborn.enable = true;
|
||||
|
||||
pipewire = {
|
||||
enable = true;
|
||||
@@ -421,10 +371,7 @@ in
|
||||
};
|
||||
|
||||
udev = {
|
||||
packages = [
|
||||
pkgs.openhantek6022
|
||||
pkgs.openocd
|
||||
];
|
||||
packages = [pkgs.openhantek6022 pkgs.openocd];
|
||||
extraRules = ''
|
||||
#Xilinx FTDI
|
||||
ACTION=="add", ATTR{idVendor}=="0403", ATTR{manufacturer}=="Xilinx", MODE:="666"
|
||||
@@ -443,43 +390,33 @@ in
|
||||
|
||||
tlp = {
|
||||
enable = true;
|
||||
settings = {
|
||||
START_CHARGE_THRESH_BAT0 = 70;
|
||||
STOP_CHARGE_THRESH_BAT0 = 86;
|
||||
};
|
||||
};
|
||||
|
||||
batteryNotifier = {
|
||||
enable = true;
|
||||
notifyCapacity = 12;
|
||||
suspendCapacity = 5;
|
||||
notifyCapacity = 20;
|
||||
suspendCapacity = 10;
|
||||
};
|
||||
|
||||
actkbd = {
|
||||
enable = true;
|
||||
bindings = [
|
||||
{
|
||||
keys = [ 115 ];
|
||||
keys = [113];
|
||||
events = ["key"];
|
||||
command = "XDG_RUNTIME_DIR=/run/user/$(id -u ${USER}) ${pkgs.wireplumber}/bin/wpctl set-volume @DEFAULT_AUDIO_SINK@ 5%+";
|
||||
command = "/run/current-system/sw/bin/runuser -l akill -c 'amixer -q set Master toggle'";
|
||||
}
|
||||
|
||||
{
|
||||
keys = [114];
|
||||
events = [
|
||||
"key"
|
||||
"rep"
|
||||
];
|
||||
command = "XDG_RUNTIME_DIR=/run/user/$(id -u ${USER}) ${pkgs.wireplumber}/bin/wpctl set-volume @DEFAULT_AUDIO_SINK@ 5%-";
|
||||
events = ["key" "rep"];
|
||||
command = "/run/current-system/sw/bin/runuser -l akill -c 'amixer -q set Master 5%- unmute'";
|
||||
}
|
||||
|
||||
{
|
||||
keys = [ 113 ];
|
||||
events = [
|
||||
"key"
|
||||
"rep"
|
||||
];
|
||||
command = "XDG_RUNTIME_DIR=/run/user/$(id -u ${USER}) ${pkgs.wireplumber}/bin/wpctl set-mute @DEFAULT_AUDIO_SINK@ toggle";
|
||||
keys = [115];
|
||||
events = ["key" "rep"];
|
||||
command = "/run/current-system/sw/bin/runuser -l akill -c 'amixer -q set Master 5%+ unmute'";
|
||||
}
|
||||
|
||||
{
|
||||
@@ -496,7 +433,7 @@ in
|
||||
];
|
||||
};
|
||||
|
||||
dnscrypt-proxy = {
|
||||
dnscrypt-proxy2 = {
|
||||
enable = true;
|
||||
settings = {
|
||||
ipv6_servers = true;
|
||||
@@ -510,18 +447,16 @@ in
|
||||
"https://raw.githubusercontent.com/DNSCrypt/dnscrypt-resolvers/master/v3/public-resolvers.md"
|
||||
"https://download.dnscrypt.info/resolvers-list/v3/public-resolvers.md"
|
||||
];
|
||||
cache_file = "/var/lib/dnscrypt-proxy/public-resolvers.md";
|
||||
cache_file = "public-resolvers.md";
|
||||
minisign_key = "RWQf6LRCGA9i53mlYecO4IzT51TGPpvWucNSCh1CBM0QTaLn73Y7GFO3";
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
borgbackup.jobs."borgbase" =
|
||||
let
|
||||
user = config.users.users.${USER};
|
||||
borgbackup.jobs."borgbase" = let
|
||||
user = config.users.users.akill;
|
||||
home = user.home;
|
||||
in
|
||||
{
|
||||
in {
|
||||
user = user.name;
|
||||
paths = [
|
||||
(home + "/pic/priv")
|
||||
@@ -555,10 +490,26 @@ in
|
||||
SystemMaxUse=50M
|
||||
'';
|
||||
|
||||
logind.settings.Login = {
|
||||
KillUserProcesses = true;
|
||||
};
|
||||
logind.extraConfig = ''
|
||||
KillUserProcesses=yes
|
||||
'';
|
||||
|
||||
seafile = {
|
||||
enable = false;
|
||||
initialAdminPassword = "admin";
|
||||
adminEmail = "asmir.abdulahovic@gmail.com";
|
||||
ccnetSettings = {
|
||||
General = {
|
||||
SERVICE_URL = "http://127.0.0.1:8020";
|
||||
};
|
||||
};
|
||||
seafileSettings = {
|
||||
fileserver = {
|
||||
host = "0.0.0.0";
|
||||
port = 8082;
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
fonts = {
|
||||
@@ -585,24 +536,17 @@ in
|
||||
noto-fonts
|
||||
noto-fonts-cjk-sans
|
||||
noto-fonts-color-emoji
|
||||
noto-fonts-emoji
|
||||
proggyfonts
|
||||
siji
|
||||
terminus_font
|
||||
terminus_font_ttf
|
||||
ubuntu-classic
|
||||
vista-fonts
|
||||
ubuntu_font_family
|
||||
vistafonts
|
||||
];
|
||||
};
|
||||
|
||||
virtualisation = {
|
||||
waydroid.enable = false;
|
||||
libvirtd = {
|
||||
enable = true;
|
||||
allowedBridges = [
|
||||
"virbr0"
|
||||
"br0"
|
||||
];
|
||||
};
|
||||
spiceUSBRedirection.enable = true;
|
||||
containers.storage.settings = {
|
||||
storage = {
|
||||
@@ -622,7 +566,6 @@ in
|
||||
enable = true;
|
||||
settings = {
|
||||
General = {
|
||||
Experimental = true;
|
||||
Enable = "Source,Sink,Media,Socket";
|
||||
};
|
||||
};
|
||||
@@ -636,24 +579,13 @@ in
|
||||
};
|
||||
|
||||
zramSwap = {
|
||||
enable = true;
|
||||
enable = false;
|
||||
algorithm = "zstd";
|
||||
};
|
||||
|
||||
users.users.${USER} = {
|
||||
users.users.akill = {
|
||||
isNormalUser = true;
|
||||
initialHashedPassword = "$y$j9T$XGffGsmN/u.wO5wZ.cBml/$9iCw3eWY0GSUH/aA8ESCAxKeTCAMqY21XQF7b5ujxD6";
|
||||
shell = pkgs.zsh;
|
||||
extraGroups = [
|
||||
"adbusers"
|
||||
"audio"
|
||||
"dialout"
|
||||
"kvm"
|
||||
"plugdev"
|
||||
"sound"
|
||||
"tty"
|
||||
"wheel"
|
||||
"wireshark"
|
||||
];
|
||||
extraGroups = ["wireshark" "kvm" "tty" "audio" "sound" "adbusers" "dialout" "wheel"];
|
||||
};
|
||||
}
|
||||
|
||||
@@ -1,60 +1,39 @@
|
||||
# Do not modify this file! It was generated by ‘nixos-generate-config’
|
||||
# and may be overwritten by future invocations. Please make changes
|
||||
# to /etc/nixos/configuration.nix instead.
|
||||
{
|
||||
config,
|
||||
lib,
|
||||
pkgs,
|
||||
modulesPath,
|
||||
...
|
||||
}:
|
||||
{ config, lib, pkgs, modulesPath, ... }:
|
||||
|
||||
{
|
||||
imports = [
|
||||
(modulesPath + "/installer/scan/not-detected.nix")
|
||||
imports =
|
||||
[ (modulesPath + "/installer/scan/not-detected.nix")
|
||||
];
|
||||
|
||||
boot.initrd.luks.devices."crypt_dev".device =
|
||||
"/dev/disk/by-uuid/e10821b9-5426-4f03-b716-1645a64fcd6a";
|
||||
boot.initrd.luks.devices."crypt_dev".device = "/dev/disk/by-uuid/e10821b9-5426-4f03-b716-1645a64fcd6a";
|
||||
boot.initrd.luks.devices."crypt_dev".allowDiscards = true;
|
||||
boot.initrd.availableKernelModules = [
|
||||
"nvme"
|
||||
"ehci_pci"
|
||||
"xhci_pci"
|
||||
"uas"
|
||||
"usb_storage"
|
||||
"sd_mod"
|
||||
"rtsx_pci_sdmmc"
|
||||
];
|
||||
boot.initrd.availableKernelModules = [ "nvme" "ehci_pci" "xhci_pci" "uas" "usb_storage" "sd_mod" "rtsx_pci_sdmmc" ];
|
||||
boot.initrd.kernelModules = [ "dm-snapshot" ];
|
||||
boot.kernelModules = [
|
||||
"kvm-amd"
|
||||
"amd-gpu"
|
||||
];
|
||||
boot.kernelModules = [ "kvm-amd" "amd-gpu" ];
|
||||
boot.extraModulePackages = [ ];
|
||||
|
||||
fileSystems."/" = {
|
||||
device = "/dev/disk/by-uuid/c461c971-54ca-4fb7-91e8-6ac70de53ef2";
|
||||
fileSystems."/" =
|
||||
{ device = "/dev/disk/by-uuid/c461c971-54ca-4fb7-91e8-6ac70de53ef2";
|
||||
fsType = "xfs";
|
||||
};
|
||||
|
||||
fileSystems."/nix" = {
|
||||
device = "/dev/disk/by-uuid/eeaa6fab-d67d-400f-b6d4-b1f44c2e0047";
|
||||
fileSystems."/nix" =
|
||||
{ device = "/dev/disk/by-uuid/eeaa6fab-d67d-400f-b6d4-b1f44c2e0047";
|
||||
fsType = "xfs";
|
||||
};
|
||||
|
||||
fileSystems."/home" = {
|
||||
device = "/dev/disk/by-uuid/aeaa71ca-a439-4ef3-9ab8-db7ae8f59376";
|
||||
fileSystems."/home" =
|
||||
{ device = "/dev/disk/by-uuid/aeaa71ca-a439-4ef3-9ab8-db7ae8f59376";
|
||||
fsType = "xfs";
|
||||
};
|
||||
|
||||
fileSystems."/boot" = {
|
||||
device = "/dev/disk/by-uuid/828E-F3C3";
|
||||
fileSystems."/boot" =
|
||||
{ device = "/dev/disk/by-uuid/828E-F3C3";
|
||||
fsType = "vfat";
|
||||
options = [
|
||||
"fmask=0022"
|
||||
"dmask=0022"
|
||||
];
|
||||
options = [ "fmask=0022" "dmask=0022" ];
|
||||
};
|
||||
|
||||
swapDevices = [ ];
|
||||
|
||||
@@ -115,8 +115,7 @@ stdenv.mkDerivation {
|
||||
xorg.libxkbfile
|
||||
];
|
||||
|
||||
installPhase =
|
||||
let
|
||||
installPhase = let
|
||||
viberWrap = writeShellScriptBin "viberWrap" ''
|
||||
${bubblewrap}/bin/bwrap --bind / / \
|
||||
--dev /dev \
|
||||
@@ -125,8 +124,7 @@ stdenv.mkDerivation {
|
||||
--bind $HOME/Downloads/ $HOME/Downloads \
|
||||
$@
|
||||
'';
|
||||
in
|
||||
''
|
||||
in ''
|
||||
dpkg-deb -x $src $out
|
||||
mkdir -p $out/bin
|
||||
|
||||
|
||||
Reference in New Issue
Block a user