Compare commits

..

No commits in common. "develop" and "wsl" have entirely different histories.
develop ... wsl

179 changed files with 1646 additions and 6444 deletions

View File

@ -1,25 +0,0 @@
keys:
- &admin_odie age1ac27ksfvxydn20g29s09j66mag45vee3cgk5namsnup5e4l9v3sq7kypg7
- &server_asgard age1nnx85asl5nmxmurr3g8mazcsggvtazt0hpauw42l7v4k3de74s6s649w0k
#- &server_pi0 age1v522tvf0gclgjnnu8q0mekl0rcmpdk7d7lwravwazstfn9zqhecsngvhpf
- &server_pi0 age19wm2y96tr02uz20yuqskvhwltygf47feenf7zuxqhegtqfu4le8q9adqdd
#- &server_pi1 age1u6k49fuphu4n5p7hhuxd03ktwhujr55mrs72cqe6ttfagljpc5asa0jsgx
- &server_pi1 age16vz5m0stsh39ajn3zhkzj7x7zfgexlx3zzk2k9vrrrsn78tyzd2qmjkt2a
- &server_nixos age1j8wprrs23m46h7xl26su3k6uztnvza5k89c9uk9rwwzefv8a4yvqpscxun
- &workstation_wanaheim age1jerjsfhnenzzqtnuxez8g79kc0xxulxyhu2evp9p6gjyswu2syqskgt62v
creation_rules:
- path_regex: secrets/[^/]+\.(yaml|json|env|ini)$
key_groups:
- age:
- *admin_odie
- *server_asgard
- *server_pi0
- *server_pi1
- *server_nixos
- *workstation_wanaheim
- path_regex: modules/nixos/mediacenter/kodi/secrets/[^/]+\.(yaml|json|env|ini|xml)$
key_groups:
- age:
- *admin_odie
- *server_pi0

View File

@ -1,13 +0,0 @@
# WARN: this file will get overwritten by $ cachix use <name>
{ pkgs, lib, ... }:
let
folder = ./cachix;
toImport = name: value: folder + ("/" + name);
filterCaches = key: value: value == "regular" && lib.hasSuffix ".nix" key;
imports = lib.mapAttrsToList toImport (lib.filterAttrs filterCaches (builtins.readDir folder));
in {
inherit imports;
nix.settings.substituters = ["https://cache.nixos.org/"];
}

View File

@ -1,13 +0,0 @@
{
nix = {
settings = {
substituters = [
"https://cuda-maintainers.cachix.org"
];
trusted-public-keys = [
"cuda-maintainers.cachix.org-1:0dq3bujKpuEPMCX6U4WylrUDZ9JyUG0VpVZa7CNfq5E="
];
};
};
}

View File

@ -70,5 +70,8 @@ text = "#1E1E2E"
cursor = "#B4BEFE"
text = "#1E1E2E"
[env]
TERM = "xterm-256color"
[font]
size = 11
size = 10

View File

@ -1,32 +1,24 @@
zstyle ':completion:*' completer _extensions _complete _approximate
#zstyle ':completion:*' matcher-list '' 'm:{a-zA-Z}={A-Za-z}' 'r:|[._-]=* r:|=*' 'l:|=* r:|=*'
zstyle ':completion:*' matcher-list 'm:{a-zA-Z}={A-Za-z}' 'r:|[._-]=* r:|=*' 'l:|=* r:|=*'
zstyle ':completion:*' menu select
zstyle ':completion:*' list-colors "${(s.:.)LS_COLORS}"
zstyle ':completion:complete:*' gain-privileges 1
#zstyle ':completion:*' use-cache on
#zstyle ':completion:*' cache-path "$XDG_CACHE_HOME/zsh/.zcompcache"
zstyle ':completion:*:git-checkout:*' sort false
zstyle ':completion:*:descriptions' format '[%d]'
#zstyle ':completion:*' group-name ''
#zstyle ':completion:*' file-list all
zstyle ':completion:*:messages' format ' %F{purple} -- %d --%f'
zstyle ':completion:*:warnings' format ' %F{red}-- no matches found --%f'
#zstyle ':completion:*:*:*:*:descriptions' format '%F{green}-- %d --%f'
#zstyle ':completion:*:*:*:*:corrections' format '%F{yellow}!- %d (errors: %e) -!%f'
#zstyle ':fzf-tab:*' fzf-command ftb-tmux-popup
zstyle ':fzf-tab:complete:(cd|lsd|eza|nvim|vim|vi):*' fzf-preview 'eza -1 --color=always --icons=always $realpath'
zstyle ':fzf-tab:*' fzf-min-height 20
#zstyle ':fzf-tab:*' popup-min-size 80 12
#zstyle ':fzf-tab:*' popup-pad 0 0
zle -N up-line-or-beginning-search
zle -N down-line-or-beginning-search
zstyle ':completion:*' completer _extensions _complete _approximate
zstyle ':completion:*' use-cache on
zstyle ':completion:*' cache-path "$XDG_CACHE_HOME/zsh/.zcompcache"
zstyle ':completion:*' matcher-list '' 'm:{a-zA-Z}={A-Za-z}' 'r:|[._-]=* r:|=*' 'l:|=* r:|=*'
zstyle ':completion:*:messages' format ' %F{purple} -- %d --%f'
zstyle ':completion:*:warnings' format ' %F{red}-- no matches found --%f'
zstyle ':completion:*:*:*:*:descriptions' format '%F{green}-- %d --%f'
zstyle ':completion:*:*:*:*:corrections' format '%F{yellow}!- %d (errors: %e) -!%f'
zstyle ':completion:*' menu select
zstyle ':completion:*' group-name ''
zstyle ':completion:*' list-colors ''${(s.:.)LS_COLORS}
zstyle ':completion:*' file-list all
zstyle ':completion:complete:*' gain-privileges 1
# disable sort when completing `git checkout`
zstyle ':completion:*:git-checkout:*' sort false
# set descriptions format to enable group support
zstyle ':completion:*:descriptions' format '[%d]'
zmodload zsh/complist
bindkey -M menuselect 'h' vi-backward-char
bindkey -M menuselect 'k' vi-up-line-or-history
@ -100,3 +92,11 @@ _gitignoreio () {
}
compdef _gitignoreio gi
compdef _symfony_complete symfony
compdef _symfony_complete composer
compdef _symfony_complete console
compdef _symfony_complete artisan
compdef _symfony_complete phpstan
compdef _symfony_complete php-cs-fixer
compdef _symfony_complete phpspec

1309
flake.lock

File diff suppressed because it is too large Load Diff

300
flake.nix
View File

@ -1,25 +1,19 @@
{
description = "My Nix Configs";
outputs =
{ self
, nixpkgs
, flake-utils
, ...
}:
let
outputs = {
self,
nixpkgs,
flake-utils,
...
}: let
inherit (self) inputs outputs;
flakeLib = import ./lib;
neorgWorkspaces = [ "default" "general" "games" "btc" ];
genNeorgWorkspaces = root: workspaces: (builtins.listToAttrs (map (n: { name = n; value = "${root}/${n}"; }) workspaces));
vars = rec {
name = "Patrick Neff";
username = "odie";
extraGroups = [ ];
homeDirectory = "/home/${username}";
locale = "de_DE.UTF-8";
email = "odie86@gmail.com";
@ -28,15 +22,35 @@
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIByWNNmKhjVk5VEjk3aSKosOXzglCbiq7q8IQ8mA0qQe odie"
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIA1QZO6fF2RLcmjMKdG1eZi0RLw3joa+VBXaKvfmA7Tg odie"
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAINs89u4Kvwlmq67eV+H/n+x9M8gsKDxQU+dCPSEb2vJe odie"
"ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIKoBcSKQSPmPo3Y/zvnaIaIpT6dHX4ZQYUirj4x7a8wB odie@pi0"
];
domain = "odie.home.arpa";
neorg.workspaces = genNeorgWorkspaces "${homeDirectory}/Notes" neorgWorkspaces;
};
overlays = import ./overlays { inherit inputs; };
overlays = [
inputs.nixvim.overlays.default
inputs.neovim-nightly-overlay.overlays.default
inputs.nur.overlay
inputs.nixgl.overlay
inputs.neorg-overlay.overlays.default
outputs.overlays.kodi
];
in
{
overlays = {
kodi = final: prev: {
kodi-standalone =
final.kodi-wayland.withPackages
(kodiPkgs:
with kodiPkgs; [
youtube
pvr-iptvsimple
keymap
inputstream-adaptive
inputstream-ffmpegdirect
requests-cache
inputstreamhelper
]);
};
};
nixosModules = {
base = import ./modules/nixos/base;
desktop = import ./modules/nixos/desktop;
@ -45,39 +59,18 @@
qemu = import ./modules/nixos/qemu;
home-manager = import ./modules/nixos/home-manager;
server = import ./modules/nixos/server;
games = import ./modules/nixos/games;
sops = import ./modules/nixos/sops;
raspberry-pi = import ./modules/nixos/raspberry-pi;
};
nixosConfigurations =
flakeLib.mkNixosConfiguration
{
flakeLib.mkNixosConfiguration {
inherit inputs nixpkgs outputs vars flakeLib overlays;
system = "x86_64-linux";
hostName = "vm";
}
// flakeLib.mkNixosConfiguration {
inherit inputs nixpkgs outputs flakeLib overlays;
vars = vars // {
neorg.workspaces = genNeorgWorkspaces "/mnt/c/Users/odie/Sync/norg" neorgWorkspaces;
extraGroups = [ "minecraft" ];
};
inherit inputs nixpkgs outputs vars flakeLib overlays;
system = "x86_64-linux";
hostName = "wsl-dev";
}
// flakeLib.mkNixosConfiguration {
inherit inputs nixpkgs outputs flakeLib overlays vars;
system = "x86_64-linux";
hostName = "pi-installer";
modules = [
inputs.raspberry-pi-nix.nixosModules.sd-image
];
}
// flakeLib.mkNixosConfiguration {
inherit inputs outputs nixpkgs vars flakeLib overlays;
system = "aarch64-linux";
hostName = "pi0";
}
// flakeLib.mkNixosConfiguration {
inherit inputs outputs nixpkgs vars flakeLib overlays;
system = "aarch64-linux";
@ -98,11 +91,9 @@
mediacenter = import ./modules/home-manager/mediacenter;
user = import ./modules/home-manager/user;
binary-cache = import ./modules/home-manager/binary-cache;
sops = import ./modules/home-manager/sops;
};
homeConfigurations =
flakeLib.mkHomeConfiguration
{
flakeLib.mkHomeConfiguration {
inherit inputs outputs nixpkgs flakeLib overlays;
vars = vars // {hostName = "wanaheim";};
system = "x86_64-linux";
@ -118,207 +109,50 @@
vars
// {
hostName = "odie-dev";
domain = "niederkassel.neff-steindesign.de";
domain = "niederkasse.neff-steindesign.de";
};
system = "x86_64-linux";
};
templates = {
empty = {
path = ./templates/empty;
description = "";
};
go = {
path = ./templates/go;
description = "";
};
rust = {
path = ./templates/rust;
description = "";
};
cpp = {
path = ./templates/cpp;
description = "";
};
};
images = {
pi-installer = self.outputs.nixosConfigurations.pi-installer.config.system.build.sdImage;
};
}
// flake-utils.lib.eachDefaultSystem (system: let
pkgs = import nixpkgs {
inherit system;
};
in {
devShells.default = pkgs.mkShell {
packages = with pkgs; [(nixos{}).nixos-rebuild];
// flake-utils.lib.eachDefaultSystem (system: {
packages = {
neovim-ide = import ./pkgs/nixvim {inherit inputs system flakeLib nixpkgs;};
};
});
inputs = {
# System
nixpkgs.url = "github:nixos/nixpkgs"; # Use master
#nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable"; # Use unstable
nur = {
url = "github:nix-community/NUR";
inputs = {
nixpkgs.follows = "nixpkgs";
flake-parts.follows = "flake-parts";
};
};
#nixpkgs.url = "github:nixos/nixpkgs/nixos-23.11";
#nixpkgs-unstable.url = "github:nixos/nixpkgs/nixos-unstable";
nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable";
nur.url = "github:nix-community/NUR";
nix-colors.url = "github:misterio77/nix-colors";
systems.url = "github:nix-systems/default";
flake-parts.url = "github:hercules-ci/flake-parts";
flake-compat.url = "github:edolstra/flake-compat";
nixos-hardware.url = "github:nixos/nixos-hardware";
home-manager = {
url = "github:nix-community/home-manager";
inputs.nixpkgs.follows = "nixpkgs";
};
nixgl = {
url = "github:nix-community/nixGL/9b4887dbf16933bdc124296434b3898d810b3608";
inputs.nixpkgs.follows = "nixpkgs";
};
nixvim = {
url = "github:nix-community/nixvim";
inputs.nixpkgs.follows = "nixpkgs";
};
neovim-nightly-overlay = {
url = "github:nix-community/neovim-nightly-overlay";
inputs.nixpkgs.follows = "nixpkgs";
};
flake-utils = {
url = "github:numtide/flake-utils";
inputs.systems.follows = "systems";
};
sops-nix = {
url = "github:Mic92/sops-nix";
inputs.nixpkgs.follows = "nixpkgs";
};
nixos-wsl = {
url = "github:nix-community/NixOS-WSL";
inputs = {
nixpkgs.follows = "nixpkgs";
flake-compat.follows = "flake-compat";
};
};
raspberry-pi-nix = {
url = "github:nix-community/raspberry-pi-nix";
inputs = {
nixpkgs.follows = "nixpkgs";
};
};
nixgl = {
url = "github:nix-community/nixGL";
inputs.nixpkgs.follows = "nixpkgs";
inputs.flake-utils.follows = "flake-utils";
};
catppuccin.url = "github:catppuccin/nix";
# Neovim
nixvim = {
url = "github:nix-community/nixvim";
inputs = {
nixpkgs.follows = "nixpkgs";
home-manager.follows = "home-manager";
flake-parts.follows = "flake-parts";
flake-compat.follows = "flake-compat";
};
};
neovim-nightly-overlay = {
url = "github:nix-community/neovim-nightly-overlay";
inputs = {
nixpkgs.follows = "nixpkgs";
flake-parts.follows = "flake-parts";
flake-compat.follows = "flake-compat";
};
};
nvim-spell-de-utf8-dictionary = {
url = "https://ftp.uni-bayreuth.de/packages/editors/vim/runtime/spell/de.utf-8.spl";
flake = false;
};
nvim-spell-de-utf8-suggestions = {
url = "https://ftp.uni-bayreuth.de/packages/editors/vim/runtime/spell/de.utf-8.sug";
flake = false;
};
nvim-spell-de-latin1-dictionary = {
url = "https://ftp.uni-bayreuth.de/packages/editors/vim/runtime/spell/de.latin1.spl";
flake = false;
};
nvim-spell-de-latin1-suggestions = {
url = "https://ftp.uni-bayreuth.de/packages/editors/vim/runtime/spell/de.latin1.sug";
flake = false;
};
guihua = {
url = "github:ray-x/guihua.lua";
flake = false;
};
neorg-overlay = {
url = "github:nvim-neorg/nixpkgs-neorg-overlay";
inputs = {
nixpkgs.follows = "nixpkgs";
flake-utils.follows = "flake-utils";
};
};
lazydev = {
url = "github:folke/lazydev.nvim";
flake = false;
};
luavit-meta = {
url = "github:Bilal2453/luvit-meta";
flake = false;
};
norg = {
url = "github:nvim-neorg/tree-sitter-norg/dev";
inputs = {
nixpkgs.follows = "nixpkgs";
flake-utils.follows = "flake-utils";
flake-compat.follows = "flake-compat";
};
};
norg-meta = {
url = "github:nvim-neorg/tree-sitter-norg-meta";
inputs = {
nixpkgs.follows = "nixpkgs";
flake-utils.follows = "flake-utils";
flake-compat.follows = "flake-compat";
};
};
neorg = {
url = "github:nvim-neorg/neorg";
flake = false;
};
neorg-telescope = {
url = "github:nvim-neorg/neorg-telescope";
flake = false;
};
vim-mcfunction = {
url = "github:CrystalAlpha358/vim-mcfunction";
flake = false;
};
# Games
nix-minecraft = {
url = "github:Infinidoge/nix-minecraft";
inputs = {
nixpkgs.follows = "nixpkgs";
flake-utils.follows = "flake-utils";
flake-compat.follows = "flake-compat";
};
};
minecraft-server-flake = {
url = "git+ssh://git@git.gaja-group.com/gaja-group/minecraft-server-flake.git";
#url = "git+file:///home/odie/Code/nix/minecraft-server-flake?ref=update/1.21.4";
#url = "git+file:///home/odie/Code/nix/minecraft-server-flake?ref=master";
inputs = {
nixpkgs.follows = "nixpkgs";
flake-utils.follows = "flake-utils";
systems.follows = "systems";
nix-minecraft.follows = "nix-minecraft";
};
};
gokosync = {
url = "git+ssh://git@git.gaja-group.com/odie/gokosync.git";
inputs = {
nixpkgs.follows = "nixpkgs";
flake-utils.follows = "flake-utils";
systems.follows = "systems";
};
};
# Misc
csleeptimer = {
url = "git+ssh://gitea@git.niederkassel.neff-steindesign.de/odie/csleeptimer.git";
inputs = {
@ -327,30 +161,12 @@
systems.follows = "systems";
};
};
yazi-plugins = {
url = "github:yazi-rs/plugins";
flake = false;
};
starship-yazi = {
url = "github:Rolv-Apneseth/starship.yazi";
flake = false;
};
mediainfo-yazi = {
url = "github:boydaihungst/mediainfo.yazi";
flake = false;
};
open-with-cmd-yazi = {
url = "github:Ape/open-with-cmd.yazi";
flake = false;
neorg-overlay = {
url = "github:nvim-neorg/nixpkgs-neorg-overlay";
inputs = {
nixpkgs.follows = "nixpkgs";
flake-utils.follows = "flake-utils";
};
};
nixConfig = {
extra-substituters = [ "https://nix-community.cachix.org" ];
extra-trusted-public-keys = [
"nix-community.cachix.org-1:mB9FSh9qf2dCimDSUo8Zy7bkq5CX+/rkCWyvRCYg3Fs="
];
};
}

View File

@ -1,6 +1,10 @@
{
mkPkgs = import ./mkPkgs.nix;
mkNixVim = import ./mkNixVim.nix;
mkNixVimLib = import ./mkNixVimLib.nix;
mkNixVimModule = import ./mkNixVimModule.nix;
mkNixosConfiguration = import ./mkNixosConfiguration.nix;
mkHomeConfiguration = import ./mkHomeConfiguration.nix;
mkNixvim = import ./mkNixvim.nix;
mkHomeManagerDefaults = import ./mkHomeManagerDefaults.nix;
mkNixosHomeConfiguration = import ./mkNixosHomeConfiguration.nix;
}

View File

@ -1,30 +0,0 @@
{ name, dataDir, user, domain, wantedBy ? [], Before ? [] }: { pkgs, ... }:
{
systemd.services."create-${name}-cert" = {
description = "Create a certificate for ${domain}";
script = ''
${pkgs.openssl}/bin/openssl req -x509 -newkey rsa:4096 -keyout ${domain}.key -out ${domain}.crt -nodes -subj '/CN=${domain}'
${pkgs.openssl}/bin/openssl pkcs12 -export -out ${domain}.pfx -inkey ${domain}.key -in ${domain}.crt -passout pass:
cat ${domain}.crt ${domain}.key > ${domain}.pem
chmod 644 ${domain}.crt
chmod 640 ${domain}.pfx
chmod 640 ${domain}.key
chmod 640 ${domain}.pem
'';
wantedBy = [ "multi-user.target" ] ++ wantedBy;
unitConfig = {
Before = [ "multi-user.target" ] ++ Before;
ConditionPathExists = "!${dataDir}/${domain}.pfx";
};
serviceConfig = {
User = user;
Type = "oneshot";
WorkingDirectory = dataDir;
RemainAfterExit = true;
};
};
}

View File

@ -1,7 +1,6 @@
{
moduleInputs @ {
nixpkgs,
inputs,
outputs,
flakeLib,
system,
vars,
@ -12,18 +11,14 @@
profile = "${username}@${hostName}";
in {
${profile} = let
config = flakeLib.mkHomeManagerDefaults moduleInputs;
pkgs = flakeLib.mkPkgs {
inherit nixpkgs system overlays;
};
in
inputs.home-manager.lib.homeManagerConfiguration {
inherit pkgs;
extraSpecialArgs = {
inherit inputs outputs vars flakeLib;
inherit (inputs) nix-colors;
};
#useGlobalPkgs = true;
#useUserPackages = true;
inherit (config) extraSpecialArgs;
modules = [
../profiles/home-manager/${profile}/home.nix

View File

@ -0,0 +1,14 @@
{
inputs,
outputs,
vars,
flakeLib,
...
}: {
extraSpecialArgs = {
inherit inputs outputs vars flakeLib;
inherit (inputs) nix-colors;
};
useGlobalPkgs = true;
useUserPackages = true;
}

10
lib/mkNixVim.nix Normal file
View File

@ -0,0 +1,10 @@
{
pkgs,
module,
inputs,
...
}: let
nixvim' = inputs.nixvim.legacyPackages.${pkgs.system};
nvim = nixvim'.makeNixvimWithModule module;
in
nvim

11
lib/mkNixVimLib.nix Normal file
View File

@ -0,0 +1,11 @@
let
mkNixVimLib = {
inputs,
system,
...
}: let
nixvimLib = inputs.nixvim.lib.${system};
in
nixvimLib;
in
mkNixVimLib

8
lib/mkNixVimModule.nix Normal file
View File

@ -0,0 +1,8 @@
{
pkgs,
module,
extraSpecialArgs ? {},
...
}: {
inherit pkgs module extraSpecialArgs;
}

View File

@ -1,13 +1,13 @@
{ inputs
, outputs
, flakeLib
, overlays
, system
, hostName
, nixpkgs
, vars
, modules ? [ ]
, ...
{
inputs,
outputs,
flakeLib,
overlays,
system,
hostName,
nixpkgs,
vars,
...
}: {
${hostName} = nixpkgs.lib.nixosSystem {
inherit system;
@ -21,6 +21,6 @@
};
modules = [
../profiles/nixos/${hostName}/configuration.nix
] ++ modules;
];
};
}

View File

@ -0,0 +1,10 @@
{vars, ...}: let
inherit (vars) username hostName;
profile = "${username}@${hostName}";
in {
${username} = {
imports = [
../profiles/home-manager/${profile}/home.nix
];
};
}

View File

@ -1,16 +0,0 @@
{ inputs
, pkgs
, vars
, ...
}:
let
nixvim' = inputs.nixvim.legacyPackages.${pkgs.system};
module = {
inherit pkgs;
extraSpecialArgs = {
inherit inputs vars;
};
module = import ../modules/nixvim;
};
in
nixvim'.makeNixvimWithModule module

View File

@ -1,16 +1,10 @@
{pkgs, inputs, ...}: {
{pkgs, ...}: {
imports = [
./news.nix
./nixpkgs.nix
inputs.catppuccin.homeManagerModules.catppuccin
];
# programs.home-manager.enable = true;
home.packages = with pkgs; [
home-manager
];
catppuccin = {
enable = true;
flavor = "mocha";
};
}

View File

@ -1,6 +1,3 @@
{pkgs, lib, ...}: with lib; {
nixpkgs = {
config.allowUnfree = true;
};
nix.package = mkForce pkgs.nix;
{
nixpkgs.config.allowUnfree = true;
}

View File

@ -3,7 +3,7 @@ _: {
# package = pkgs.nix;
settings = {
substituters = [
"http://nix-cache.gaja-group.intranet:5000"
"http://nixcache.odie.home.arpa"
"https://nix-community.cachix.org"
"https://cache.nixos.org/"
];

View File

@ -24,6 +24,8 @@ lib.mkIf config.desktop.awesome.enable {
};
};
services.gnome-keyring.enable = true;
xsession = {
windowManager.awesome = {
enable = true;

View File

@ -14,12 +14,6 @@
require("awful.hotkeys_popup.keys")
local vicious = require("vicious")
awful.spawn.with_shell(
'if (xrdb -query | grep -q "^awesome\\.started:\\s*true$"); then exit; fi;' ..
'xrdb -merge <<< "awesome.started:true";' ..
'dex --environment Awesome --autostart --search-paths "$${XDG_CONFIG_HOME:-$HOME/.config}/autostart:$${XDG_CONFIG_DIRS:-/etc/xdg}/autostart";'
)
-- {{{ Error handling
if awesome.startup_errors then
naughty.notify({

View File

@ -46,7 +46,6 @@
./darkman
./pcmanfm
./thunar
./hyprland
];
config = lib.mkIf config.desktop.enable {
desktop = {
@ -61,7 +60,6 @@
kitty.enable = lib.mkDefault true;
};
services = {
gnome-keyring.enable = true;
nextcloud-client.enable = lib.mkDefault true;
udiskie = {
enable = lib.mkDefault true;

View File

@ -1,166 +0,0 @@
{ lib, config, ... }: {
options = {
desktop = {
hyprland = {
enable = lib.mkEnableOption "Hyprland";
};
};
};
config = {
wayland.windowManager.hyprland = lib.mkIf config.desktop.awesome.enable {
enable = true;
xwayland.enable = true;
settings = {
#source = [ "~/.config/hypr/themes/catppuccin/mocha.conf" "~/.config/hypr/monitors.conf" ];
env = [
"LIBVA_DRIVER_NAME,nvidia"
"XDG_SESSION_TYPE,wayland"
"GBM_BACKEND,nvidia-drm"
"__GLX_VENDOR_LIBRARY_NAME,nvidia"
];
cursor = {
no_hardware_cursors = true;
};
input = {
kb_layout = "de";
kb_variant = "nodeadkeys";
follow_mouse = 1;
numlock_by_default = 1;
touchpad = {
natural_scroll = false;
};
sensitivity = 0;
accel_profile = "flat";
force_no_accel = true;
};
general = {
gaps_in = 3;
gaps_out = 6;
border_size = 2;
col.active_border = "0xaa$blueAlpha";
col.inactive_border = "0xaa$surface0Alpha";
layout = "dwindle";
};
decoration = {
rounding = 3;
};
animations = {
enabled = true;
bezier = "easyInCubic, 0.32, 0, 0.67, 0";
animation = [
"windows, 1, 1.125, easyInCubic"
"windowsOut, 1, 1.125, easyInCubic, popin 80%"
"fade, 1, 1.125, easyInCubic"
"workspaces, 1, 1.125, easyInCubic"
];
};
dwindle = {
pseudotile = true;
preserve_split = true;
default_split_ratio = 1;
};
master = {
new_is_master = true;
};
gestures = {
workspace_swipe = false;
};
# See https://wiki.hyprland.org/Configuring/Keywords/ for more
"$mainMod" = "SUPER";
"$term" = "kitty";
"$browser" = "firefox";
"$filemanager" = "thunar";
"$launcher" = "wofi -bt kitty --show drun";
bind = [
"$mainMod, return, exec, $term"
"$mainMod, W, exec, $browser"
"$mainMod SHIFT, Q, exit,"
"$mainMod, Q, killactive,"
"$mainMod, F, togglefloating,"
"$mainMod SHIFT, F, fullscreen,"
"$mainMod, P, pseudo, # dwindle"
"$mainMod, N, togglesplit, # dwindle"
# Launchers
"$mainMod, E, exec, $filemanager"
"$mainMod, R, exec, $launcher"
"$mainMod, O, exec, wofi-emoji"
"$mainMod SHIFT, X, exec, eww open powermenu"
"$mainMod, V, exec, cliphist list | wofi --dmenu | cliphist decode | wl-copy"
# Move focus with mainMod + arrow keys
"ALT, Tab, cyclenext,"
"ALT, Tab, bringactivetotop,"
"$mainMod, H, movefocus, l"
"$mainMod, L, movefocus, r"
"$mainMod, K, movefocus, u"
"$mainMod, J, movefocus, d"
"$mainMod SHIFT, H, movewindow, l"
"$mainMod SHIFT, L, movewindow, r"
"$mainMod SHIFT, K, movewindow, u"
"$mainMod SHIFT, J, movewindow, d"
"$mainMod CONTROL, H, resizeactive, -50 0"
"$mainMod CONTROL, L, resizeactive, 50 0"
"$mainMod CONTROL, K, resizeactive, 0 -50"
"$mainMod CONTROL, J, resizeactive, 0 50"
# Switch workspaces with mainMod + [0-9]
"$mainMod, 1, workspace, 1"
"$mainMod, 2, workspace, 2"
"$mainMod, 3, workspace, 3"
"$mainMod, 4, workspace, 4"
"$mainMod, 5, workspace, 5"
"$mainMod, 6, workspace, 6"
"$mainMod, 7, workspace, 7"
"$mainMod, 8, workspace, 8"
"$mainMod, 9, workspace, 9"
"$mainMod, 0, workspace, 10"
# Move active window to a workspace with mainMod + SHIFT + [0-9]
"$mainMod SHIFT, 1, movetoworkspacesilent, 1"
"$mainMod SHIFT, 2, movetoworkspacesilent, 2"
"$mainMod SHIFT, 3, movetoworkspacesilent, 3"
"$mainMod SHIFT, 4, movetoworkspacesilent, 4"
"$mainMod SHIFT, 5, movetoworkspacesilent, 5"
"$mainMod SHIFT, 6, movetoworkspacesilent, 6"
"$mainMod SHIFT, 7, movetoworkspacesilent, 7"
"$mainMod SHIFT, 8, movetoworkspacesilent, 8"
"$mainMod SHIFT, 9, movetoworkspacesilent, 9"
"$mainMod SHIFT, 0, movetoworkspacesilent, 10"
# Volume
",XF86AudioRaiseVolume, exec, pactl set-sink-volume @DEFAULT_SINK@ +5%"
",XF86AudioLowerVolume, exec, pactl set-sink-volume @DEFAULT_SINK@ -5%"
",XF86AudioMute, exec, pactl set-sink-mute @DEFAULT_SINK@ toggle"
# Playback controls
",XF86AudioPlay, exec, playerctl play-pause"
",XF86AudioStop, exec, playerctl stop"
",XF86AudioNext, exec, playerctl next"
",XF86AudioPrev, exec, playerctl previous"
];
bindm = [
# Move/resize windows with mainMod + LMB/RMB and dragging
"$mainMod, mouse:272, movewindow"
"$mainMod, mouse:273, resizewindow"
];
};
};
};
}

View File

@ -17,7 +17,7 @@
window_padding_width = 0;
symbol_map = "U+E5FA-U+E62B,U+E700-U+E7C5,U+F000-U+F2E0,U+E200-U+E2A9,U+F500-U+FD46,U+E300-U+E3EB,U+F400-U+F4A8,U+2665,U+26A1,U+F27C,U+E0A3,U+E0B4-U+E0C8,U+E0CA,U+E0CC-U+E0D2,U+E0D4,U+23FB-U+23FE,U+2B58,U+F300-U+F313,U+E000-U+E00D Symbols Nerd Font Mono";
};
#theme = "Catppuccin-Mocha";
theme = "Catppuccin-Mocha";
};
};
}

View File

@ -19,7 +19,7 @@
package = pkgs.papirus-icon-theme;
};
theme = {
name = "catppuccin-mocha-blue-standard";
name = "Catppuccin-Mocha-Standard-Blue-Dark";
package = pkgs.catppuccin-gtk;
};
};

View File

@ -6,6 +6,5 @@ with lib; {
];
options = {
desktop.xserver.enable = mkEnableOption "xserver";
desktop.xresources.enable = mkEnableOption "xresources";
};
}

View File

@ -3,7 +3,7 @@
lib,
...
}: let
cfg = config.desktop.xresources;
cfg = config.desktop.xserver;
in
with lib;
mkIf cfg.enable {
@ -32,8 +32,8 @@ in
"URxvt.saveline" = "10480";
"URxvt.scrollBar" = "false";
"URxvt.urgentOnBell" = "true";
"URxvt.font" = "xft:JetBrains Mono Nerd Font:size=11";
"URxvt.fontBold" = "xft:JetBrains Mono Nerd Font:bold:size=11";
"URxvt.font" = "xft:FiraCode Nerd Font Mono:size=9";
"URxvt.fontBold" = "xft:FiraCode Nerd Font Mono:bold:size=9";
"URxvt.depth" = "32";
"URxvt.background" = "[95]#1E1E2E";
"Xft.autohint" = "0";
@ -42,6 +42,6 @@ in
"Xft.hinting" = "1";
"Xft.antialias" = "1";
"Xft.rgba" = "rgb";
"XTerm*faceName" = "JetBrains Mono Nerd Font:bold:size=11";
"XTerm*faceName" = "FiraCode Nerd Font Mono:bold:size=9";
};
}

View File

@ -1,13 +1,12 @@
{lib, ...}: {
_: {
imports = [
./gitea
./neovim-ide
./ghidra
];
programs = {
lazygit.enable = lib.mkDefault true;
gitea-cli.enable = lib.mkDefault true;
neovim-ide.enable = lib.mkDefault true;
lazygit.enable = true;
gitea-cli.enable = true;
neovim-ide.enable = true;
};
}

View File

@ -1,11 +0,0 @@
{ pkgs, lib, config, ... }:
{
options = {
programs.ghidra.enable = lib.mkEnableOption "ghidra";
};
config = lib.mkIf config.programs.ghidra.enable {
home.packages = [
pkgs.ghidra
];
};
}

View File

@ -1,34 +1,16 @@
{ inputs
, pkgs
, config
, lib
, vars
, ...
}:
let
flakeLib = import ../../../../lib;
neovim-ide = flakeLib.mkNixvim {
inherit pkgs inputs vars;
};
in
{
outputs,
pkgs,
config,
lib,
...
}: {
options = {
programs.neovim-ide.enable = lib.mkEnableOption "neovim-ide";
};
config = lib.mkIf config.programs.neovim-ide.enable {
home = {
packages = [ neovim-ide ];
sessionPath = [
"/home/odie/go/bin"
];
file = {
"${config.xdg.configHome}/nvim/spell/de.utf-8.spl".source = inputs.nvim-spell-de-utf8-dictionary;
"${config.xdg.configHome}/nvim/spell/de.utf-8.sug".source = inputs.nvim-spell-de-utf8-suggestions;
"${config.xdg.configHome}/nvim/spell/de.latin1.spl".source = inputs.nvim-spell-de-latin1-dictionary;
"${config.xdg.configHome}/nvim/spell/de.latin1.sug".source = inputs.nvim-spell-de-latin1-suggestions;
};
packages = [outputs.packages.${pkgs.system}.neovim-ide];
};
};
}

View File

@ -7,11 +7,7 @@ with lib; {
];
config = {
games = {
unnethack.enable = mkDefault false;
dsda-doom.enable = mkDefault true;
woof.enable = mkDefault true;
eternity.enable = mkDefault true;
};
games.unnethack.enable = mkDefault true;
games.dsda-doom.enable = mkDefault true;
};
}

View File

@ -1,7 +1,5 @@
{
imports = [
./dsda-doom.nix
./woof.nix
./eternity.nix
];
}

View File

@ -1,18 +0,0 @@
{
pkgs,
config,
lib,
...
}: let
cfg = config.games.eternity;
in
with lib; {
options = {
games.eternity.enable = mkEnableOption "eternity-engine";
};
config = mkIf cfg.enable {
home.packages = with pkgs; [
eternity
];
};
}

View File

@ -1,18 +0,0 @@
{
pkgs,
config,
lib,
...
}: let
cfg = config.games.dsda-doom;
in
with lib; {
options = {
games.woof.enable = mkEnableOption "woof-doom";
};
config = mkIf cfg.enable {
home.packages = with pkgs; [
woof-doom
];
};
}

View File

@ -0,0 +1,74 @@
{
vars,
mysql,
media,
...
}: let
inherit (vars) timeZone hostName domain;
datadirs = "smb://${media.host}/kodi/userdata";
in {
addons = {
unknownsources = "true";
};
services = {
devicename = "${hostName}.${domain}";
webserver = "true";
webserverauthentication = "false";
webserverusername = "kodi";
webserverpassword = "kodi";
webserverport = "8000";
webserverssl = "false";
zeroconf = "true";
wsdiscovery = "true";
upnp = "true";
upnpserver = "true";
airplay = "true";
airplayvideosupport = "true";
};
locale = {
language = "resource.language.de_de";
country = "Deutschland";
timezone = timeZone;
};
lookandfeed = {
enablerssfeeds = "false";
};
videodatabase = {
inherit (mysql) user pass host;
type = "mysql";
port = builtins.toString mysql.port;
};
musicdatabase = {
inherit (mysql) user pass host;
type = "mysql";
port = builtins.toString mysql.port;
};
videolibrary = {
importwatchedstate = "true";
importresumepoint = "true";
};
pathsubstitution = {
substitute = [
{
from = "special://profile/playlists/";
to = "${datadirs}/playlists/";
}
{
from = "special://profile/sources.xml";
to = "${datadirs}/sources.xml";
}
{
from = "special://profile/mediasources.xml";
to = "${datadirs}/mediasources.xml";
}
{
from = "special://profile/RssFeeds.xml";
to = "${datadirs}/RssFeeds.xml";
}
{
from = "special://profile/favourites.xml";
to = "${datadirs}/favourites.xml";
}
];
};
}

View File

@ -0,0 +1,64 @@
{
vars,
pkgs,
config,
lib,
...
}: let
cfg = config.mediacenter.kodi;
inherit (lib) types;
in
with lib; {
options.mediacenter.kodi = {
# enable = mkEnableOption "kodi";
media = {
host = mkOption {
type = types.str;
default = "media";
};
user = mkOption {
type = types.str;
default = "kodi";
};
pass = mkOption {
type = types.str;
default = "kodi";
};
};
mysql = {
host = mkOption {
type = types.str;
default = "localhost";
};
port = mkOption {
type = types.int;
default = 3306;
};
user = mkOption {
type = types.str;
default = "kodi";
};
pass = mkOption {
type = types.str;
default = "kodi";
};
};
};
imports = [./kodi.nix]; # import overridden kodi module
config = mkIf cfg.enable {
#programs.kodi = {
mediacenter.kodi = {
# enable = true;
package = pkgs.kodi-standalone;
settings = import ./advancedsettings.nix {inherit vars; inherit (cfg) mysql media;};
};
home.file = {
"kodi-passwords.xml" = {
target = ".kodi/userdata/passwords.xml";
text = import ./passwords.nix {
inherit (cfg) media;
};
};
};
};
}

View File

@ -1,171 +1,262 @@
{ pkgs, ... }:
{
home.file = {
aelProfiles = {
text = ''
<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<advanced_emulator_launcher version="1">
<control>
<update_timestamp>1659964681.6420453</update_timestamp>
</control>
<launcher>
<id>6bc2506af9af35bc7326d70b7356af51</id>
<m_name>retroarch</m_name>
<m_year />
<m_genre />
<m_developer />
<m_rating />
<m_plot />
<platform>Unknown</platform>
<categoryID>root_category</categoryID>
<application>${pkgs.retroarch}/bin/retroarch</application>
<args />
<rompath />
<romext />
<romextrapath />
<finished>False</finished>
<toggle_window>False</toggle_window>
<non_blocking>True</non_blocking>
<multidisc>True</multidisc>
<roms_base_noext />
<audit_state>Audit OFF</audit_state>
<audit_auto_dat_file />
<audit_custom_dat_file />
<audit_display_mode>All ROMs</audit_display_mode>
<launcher_display_mode>Flat mode</launcher_display_mode>
<num_roms>0</num_roms>
<num_parents>0</num_parents>
<num_clones>0</num_clones>
<num_have>0</num_have>
<num_miss>0</num_miss>
<num_unknown>0</num_unknown>
<num_extra>0</num_extra>
<timestamp_launcher>1659942644.8321931</timestamp_launcher>
<timestamp_report>0.0</timestamp_report>
<default_icon>s_icon</default_icon>
<default_fanart>s_fanart</default_fanart>
<default_banner>s_banner</default_banner>
<default_poster>s_poster</default_poster>
<default_clearlogo>s_clearlogo</default_clearlogo>
<default_controller>s_controller</default_controller>
<Asset_Prefix />
<s_icon />
<s_fanart />
<s_banner />
<s_poster />
<s_clearlogo />
<s_controller />
<s_trailer />
<roms_default_icon>s_boxfront</roms_default_icon>
<roms_default_fanart>s_fanart</roms_default_fanart>
<roms_default_banner>s_banner</roms_default_banner>
<roms_default_poster>s_flyer</roms_default_poster>
<roms_default_clearlogo>s_clearlogo</roms_default_clearlogo>
<ROM_asset_path />
<path_3dbox />
<path_title />
<path_snap />
<path_boxfront />
<path_boxback />
<path_cartridge />
<path_fanart />
<path_banner />
<path_clearlogo />
<path_flyer />
<path_map />
<path_manual />
<path_trailer />
</launcher>
</advanced_emulator_launcher>
config,
lib,
pkgs,
...
}:
with lib; let
stylesheetCommonHeader = ''
<?xml version="1.0"?>
<xsl:stylesheet xmlns:xsl='http://www.w3.org/1999/XSL/Transform' version='1.0'>
<xsl:output method="xml" indent="yes" omit-xml-declaration="yes"/>
<xsl:strip-space elements="*"/>
'';
target =
".kodi/userdata/addon_data/plugin.program.advanced.emulator.launcher/categories.xml";
};
germanIptv = {
text = ''
<settings version="2">
<setting id="kodi_addon_instance_name">IPTV Deutsch</setting>
<setting id="kodi_addon_instance_enabled" default="true">true</setting>
<setting id="m3uPathType" default="true">1</setting>
<setting id="m3uPath" default="true" />
<setting id="m3uUrl">https://iptv-org.github.io/iptv/languages/deu.m3u</setting>
<setting id="m3uCache" default="true">true</setting>
<setting id="startNum" default="true">1</setting>
<setting id="numberByOrder" default="true">false</setting>
<setting id="m3uRefreshMode" default="true">0</setting>
<setting id="m3uRefreshIntervalMins" default="true">60</setting>
<setting id="m3uRefreshHour" default="true">4</setting>
<setting id="defaultProviderName" default="true" />
<setting id="enableProviderMappings" default="true">false</setting>
<setting id="providerMappingFile" default="true">special://userdata/addon_data/pvr.iptvsimple/providers/providerMappings.xml</setting>
<setting id="tvGroupMode" default="true">0</setting>
<setting id="numTvGroups" default="true">1</setting>
<setting id="oneTvGroup" default="true" />
<setting id="twoTvGroup" default="true" />
<setting id="threeTvGroup" default="true" />
<setting id="fourTvGroup" default="true" />
<setting id="fiveTvGroup" default="true" />
<setting id="customTvGroupsFile" default="true">special://userdata/addon_data/pvr.iptvsimple/channelGroups/customTVGroups-example.xml</setting>
<setting id="tvChannelGroupsOnly" default="true">false</setting>
<setting id="radioGroupMode" default="true">0</setting>
<setting id="numRadioGroups" default="true">1</setting>
<setting id="oneRadioGroup" default="true" />
<setting id="twoRadioGroup" default="true" />
<setting id="threeRadioGroup" default="true" />
<setting id="fourRadioGroup" default="true" />
<setting id="fiveRadioGroup" default="true" />
<setting id="customRadioGroupsFile" default="true">special://userdata/addon_data/pvr.iptvsimple/channelGroups/customRadioGroups-example.xml</setting>
<setting id="radioChannelGroupsOnly" default="true">false</setting>
<setting id="epgPathType" default="true">1</setting>
<setting id="epgPath" default="true" />
<setting id="epgUrl">http://10.0.20.10:3000/guide.xml</setting>
<setting id="epgCache" default="true">true</setting>
<setting id="epgTimeShift" default="true">0</setting>
<setting id="epgTSOverride" default="true">false</setting>
<setting id="epgIgnoreCaseForChannelIds" default="true">true</setting>
<setting id="useEpgGenreText" default="true">false</setting>
<setting id="genresPathType" default="true">0</setting>
<setting id="genresPath" default="true">special://userdata/addon_data/pvr.iptvsimple/genres/genreTextMappings/genres.xml</setting>
<setting id="genresUrl" default="true" />
<setting id="logoPathType" default="true">1</setting>
<setting id="logoPath" default="true" />
<setting id="logoBaseUrl" default="true" />
<setting id="useLogosLocalPathOnly" default="true">false</setting>
<setting id="logoFromEpg" default="true">1</setting>
<setting id="mediaEnabled" default="true">true</setting>
<setting id="mediaGroupByTitle" default="true">true</setting>
<setting id="mediaGroupBySeason" default="true">true</setting>
<setting id="mediaTitleSeasonEpisode" default="true">false</setting>
<setting id="mediaM3UGroupPath" default="true">0</setting>
<setting id="mediaForcePlaylist" default="true">false</setting>
<setting id="mediaVODAsRecordings" default="true">true</setting>
<setting id="timeshiftEnabled" default="true">false</setting>
<setting id="timeshiftEnabledAll" default="true">true</setting>
<setting id="timeshiftEnabledHttp" default="true">true</setting>
<setting id="timeshiftEnabledUdp" default="true">true</setting>
<setting id="timeshiftEnabledCustom" default="true">false</setting>
<setting id="catchupEnabled" default="true">false</setting>
<setting id="catchupQueryFormat" default="true" />
<setting id="catchupDays" default="true">5</setting>
<setting id="allChannelsCatchupMode" default="true">0</setting>
<setting id="catchupOverrideMode" default="true">0</setting>
<setting id="catchupCorrection" default="true">0</setting>
<setting id="catchupPlayEpgAsLive" default="true">false</setting>
<setting id="catchupWatchEpgBeginBufferMins" default="true">5</setting>
<setting id="catchupWatchEpgEndBufferMins" default="true">15</setting>
<setting id="catchupOnlyOnFinishedProgrammes" default="true">false</setting>
<setting id="transformMulticastStreamUrls" default="true">false</setting>
<setting id="udpxyHost" default="true">127.0.0.1</setting>
<setting id="udpxyPort" default="true">4022</setting>
<setting id="useFFmpegReconnect" default="true">true</setting>
<setting id="useInputstreamAdaptiveforHls" default="true">false</setting>
<setting id="defaultUserAgent" default="true" />
<setting id="defaultInputstream" default="true" />
<setting id="defaultMimeType" default="true" />
</settings>
'';
target = ".kodi/userdata/addon_data/pvr.iptvsimple/instance-settings-2.xml";
stylesheetCommonFooter = "</xsl:stylesheet>";
stylesheetNestedTags = ''
<xsl:template match="attr[attrs]">
<xsl:variable name="elementName" select="@name"/>
<xsl:element name="{$elementName}">
<xsl:apply-templates select="attrs" />
</xsl:element>
</xsl:template>
<xsl:template match="attr[list[attrs]]">
<xsl:variable name="elementName" select="@name"/>
<xsl:for-each select="list/attrs">
<xsl:element name="{$elementName}">
<xsl:apply-templates select="." />
</xsl:element>
</xsl:for-each>
</xsl:template>
<xsl:template match="attr[not(attrs|list)]">
<xsl:variable name="elementName" select="@name"/>
<xsl:element name="{$elementName}">
<xsl:if test="$elementName='path'">
<!-- needed in sources.xml but will be used for all "path" tags -->
<xsl:attribute name="pathversion">1</xsl:attribute>
</xsl:if>
<xsl:value-of select="*/@value" />
</xsl:element>
</xsl:template>
'';
stylesheetTagsAsSettingWithId = ''
<xsl:template match='attr'>
<setting>
<xsl:attribute name="id">
<xsl:value-of select="@name" />
</xsl:attribute>
<xsl:value-of select="*/@value" />
</setting>
</xsl:template>
'';
stylesheetAdvancedSettingsRootTag = ''
<xsl:template match='/'>
<xsl:comment> Generated by Home Manager. </xsl:comment>
<advancedsettings version="1.0">
<xsl:apply-templates/>
</advancedsettings>
</xsl:template>
'';
stylesheetSourcesRootTag = ''
<xsl:template match='/'>
<xsl:comment> Generated by Home Manager. </xsl:comment>
<sources>
<xsl:apply-templates/>
</sources>
</xsl:template>
'';
stylesheetAddonSettingsRootTag = ''
<xsl:template match='/'>
<xsl:comment> Generated by Home Manager. </xsl:comment>
<settings version="2">
<xsl:apply-templates/>
</settings>
</xsl:template>
'';
attrsetToXml = attrs: name: stylesheet:
pkgs.runCommand name {
# Package splicing for libxslt does not work correctly leading to errors
# when cross-compiling. Use the version from buildPackages explicitly to
# fix this.
nativeBuildInputs = [pkgs.buildPackages.libxslt.bin];
xml = builtins.toXML attrs;
passAsFile = ["xml"];
} ''
xsltproc ${stylesheet} - < "$xmlPath" > "$out"
'';
attrsetToAdvancedSettingsXml = attrs: name: let
stylesheet = builtins.toFile "stylesheet.xsl" ''
${stylesheetCommonHeader}
${stylesheetAdvancedSettingsRootTag}
${stylesheetNestedTags}
${stylesheetCommonFooter}
'';
in
attrsetToXml attrs name stylesheet;
attrsetToSourcesXml = attrs: name: let
stylesheet = builtins.toFile "stylesheet.xsl" ''
${stylesheetCommonHeader}
${stylesheetSourcesRootTag}
${stylesheetNestedTags}
${stylesheetCommonFooter}
'';
in
attrsetToXml attrs name stylesheet;
attrsetToAddonSettingsXml = attrs: name: let
stylesheet = builtins.toFile "stylesheet.xsl" ''
${stylesheetCommonHeader}
${stylesheetAddonSettingsRootTag}
${stylesheetTagsAsSettingWithId}
${stylesheetCommonFooter}
'';
in
attrsetToXml attrs name stylesheet;
in {
meta.maintainers = [hm.maintainers.dwagenk];
options.mediacenter.kodi = {
enable = mkEnableOption "Kodi";
package = mkOption {
type = types.package;
default = pkgs.kodi;
defaultText = literalExpression "pkgs.kodi";
example =
literalExpression
"pkgs.kodi.withPackages (exts: [ exts.pvr-iptvsimple ])";
description = ''
The `kodi` package to use.
Can be used to specify extensions.
'';
};
datadir = mkOption {
type = types.path;
default = "${config.home.homeDirectory}/.kodi";
defaultText =
literalExpression ''"''${config.home.homeDirectory}/.kodi"'';
example = literalExpression ''"''${config.xdg.dataHome}/kodi"'';
description = "Directory to store configuration and metadata.";
};
settings = mkOption {
type = with types; let
valueType =
oneOf [str (attrsOf valueType) (listOf valueType)]
// {
description = "attribute sets or lists of strings";
};
in
nullOr valueType;
default = null;
example = literalExpression ''
{ videolibrary.showemptytvshows = "true"; }
'';
description = ''
Configuration to write to the `advancedsettings.xml`
file in kodis userdata directory. Settings specified here will be
immutable from inside kodi and be hidden from the GUI settings dialog.
See <https://kodi.wiki/view/Advancedsettings.xml> as
reference for how settings need to be specified.
The innermost attributes must be of type str.
'';
};
sources = mkOption {
type = with types; let
valueType =
oneOf [str (attrsOf valueType) (listOf valueType)]
// {
description = "attribute sets or lists of strings";
};
in
nullOr valueType;
default = null;
example = literalExpression ''
{
video = {
default = "movies";
source = [
{ name = "videos"; path = "/path/to/videos"; allowsharing = "true"; }
{ name = "movies"; path = "/path/to/movies"; allowsharing = "true"; }
];
};
}
'';
description = ''
Contents to populate the file `sources.xml` in kodis
userdata directory.
See <https://kodi.wiki/view/Sources.xml> as
reference for how sources need to be specified.
Kodi will still show the dialogs to modify sources in the GUI and they
appear to be mutable. This however is not the case and the sources will
stay as specified via Home Manager.
The innermost attributes must be of type str.
'';
};
addonSettings = mkOption {
type = with types; nullOr (attrsOf (attrsOf str));
default = null;
example = literalExpression ''
{ "service.xbmc.versioncheck".versioncheck_enable = "false"; }
'';
description = ''
Attribute set with the plugin namespace as toplevel key and the plugins
settings as lower level key/value pairs.
Kodi will still show the settings of plugins configured via this
mechanism in the GUI and they appear to be mutable. This however is
not the case and the settings will stay as specified via Home Manager.
'';
};
};
config = let
cfg = config.mediacenter.kodi;
in
mkIf cfg.enable (mkMerge [
{
assertions = [
(lib.hm.assertions.assertPlatform "programs.kodi" pkgs
lib.platforms.linux)
];
home.packages = [cfg.package];
home.sessionVariables = {KODI_DATA = cfg.datadir;};
}
(mkIf (cfg.settings != null) {
home.file."${cfg.datadir}/userdata/advancedsettings.xml".source =
attrsetToAdvancedSettingsXml cfg.settings "kodi-advancedsettings.xml";
})
(mkIf (cfg.sources != null) {
home.file."${cfg.datadir}/userdata/sources.xml".source =
attrsetToSourcesXml cfg.sources "kodi-sources.xml";
})
(mkIf (cfg.addonSettings != null) {
home.file = mapAttrs' (k: v:
attrsets.nameValuePair
"${cfg.datadir}/userdata/addon_data/${k}/settings.xml" {
source = attrsetToAddonSettingsXml v "kodi-addon-${k}-settings.xml";
})
cfg.addonSettings;
})
]);
}

View File

@ -0,0 +1,8 @@
{media,...}: ''
<passwords>
<path>
<from>smb://${media.host}</from>
<to>smb://${media.user}:${media.pass}@${media.host}</to>
</path>
</passwords>
''

View File

@ -1,5 +1,5 @@
{lib,config,...}: lib.mkIf config.services.mpd.enable {
services.mpd = {
musicDirectory = "/mnt/net/svartalbenheim/media_data/media/Audio/Musik";
musicDirectory = "/mnt/media/Audio/Musik";
};
}

View File

@ -1,7 +1,7 @@
{ config, lib, ... }: lib.mkIf config.programs.btop.enable {
programs.btop = {
settings = {
#color_theme = "Default";
color_theme = "Default";
theme_background = false;
};
};

View File

@ -14,19 +14,12 @@
./bat
./tldr
./borgmatic
./yazi
./httpie
];
home.packages = with pkgs; [
ripgrep
fd
gdu
jq
python3Packages.argcomplete
zip
unzip
p7zip
];
programs = {
@ -36,16 +29,12 @@
fzf.enable = mkDefault true;
git.enable = mkDefault true;
lf.enable = mkDefault true;
#lsd.enable = mkDefault true;
eza.enable = mkDefault true;
lsd.enable = mkDefault true;
ssh.enable = mkDefault true;
starship.enable = mkDefault true;
tmux.enable = mkDefault true;
zoxide.enable = mkDefault true;
zsh.enable = mkDefault true;
tldr.enable = mkDefault true;
dircolors.enable = mkDefault true;
dircolors.enableZshIntegration = mkDefault true;
};
}

View File

@ -1,11 +1,10 @@
{ lib, config, ... }: lib.mkIf config.programs.direnv.enable {
{ pkgs, lib, config, ... }: lib.mkIf config.programs.direnv.enable {
programs.direnv = {
enableZshIntegration = true;
config = {
global = {
disable_stdin = true;
strict_env = true;
hide_env_diff = true;
};
};
nix-direnv.enable = true;

View File

@ -1,7 +0,0 @@
{lib, config, ...}: lib.mkIf config.programs.eza.enable {
programs = {
eza = {
enableZshIntegration = true;
};
};
}

View File

@ -6,7 +6,6 @@
defaultOptions = [
"--height 40%"
"--border"
"--tmux"
];
tmux = {
enableShellIntegration = true;

View File

@ -1,3 +0,0 @@
{pkgs, ...}: {
home.packages = with pkgs; [httpie];
}

View File

@ -1,7 +1,7 @@
{ pkgs, config, lib, ... }: lib.mkIf config.programs.lf.enable {
home = {
packages = with pkgs; [
#chafa
chafa
ctpv
];
file = {

View File

@ -1,7 +1,8 @@
{ pkgs
, config
, lib
, ...
{
pkgs,
config,
lib,
...
}:
lib.mkIf config.programs.ssh.enable {
home.packages = with pkgs; [tea];
@ -10,20 +11,11 @@ lib.mkIf config.programs.ssh.enable {
addKeysToAgent = "yes";
forwardAgent = true;
matchBlocks = {
"svartalbenheim.odie.home.arpa" = {
hostname = "svartalbenheim.odie.home.arpa";
"svartalbenheim.odie.intranet" = {
hostname = "svartalbenheim.odie.intranet";
identityFile = "~/.ssh/id_ed25519_local";
compression =false;
};
"git.gaja-group.com" = {
hostname = "git.gaja-group.com";
user = "git";
extraOptions = {
ProxyCommand = "openssl s_client -quiet -connect rz-de3.gaja-group.com:2222 -servername 10.100.100.170";
};
#identityFile = "~/.ssh/id_ed25519_local";
#compression =false;
};
};
};
};

View File

@ -23,7 +23,7 @@ lib.mkIf config.programs.starship.enable {
"$git_commit"
"$git_state"
"$git_metrics"
"$git_status"
"$git_statu"
"$hg_branch"
"$package"
"$c"

View File

@ -1,6 +1,11 @@
{ pkgs, lib, config, ... }:
let
catppuccin = pkgs.callPackage ../../../../pkgs/tmuxPlugins/catppuccin.nix {};
in
{
options = { };
options = {
};
config = {
programs.tmux = lib.mkIf config.programs.tmux.enable {
newSession = false;
@ -14,39 +19,16 @@
sensibleOnTop = true;
escapeTime = 0;
tmuxp.enable = true;
#terminal = "xterm-kitty";
plugins = with pkgs.tmuxPlugins; [
sensible
yank
{
plugin = catppuccin;
extraConfig = ''
set -g @catppuccin_flavour "mocha"
set -g @catppuccin_window_status_style "rounded"
set -g @catppuccin_window_default_text "#W" # use "#W" for application instead of directory
set -g @catppuccin_window_current_text "#W" # use "#W" for application instead of directory
set -g @catppuccin_window_status "icon"
set -g @catppuccin_window_separator ""
set -g @catppuccin_window_middle_separator ""
set -g @catppuccin_window_left_separator ""
set -g @catppuccin_window_right_separator ""
set -g @catppuccin_window_status_enable "yes"
set -g @catppuccin_icon_window_last "󰖰 "
set -g @catppuccin_icon_window_current "󰖯 "
set -g @catppuccin_icon_window_zoom "󰁌 "
set -g @catppuccin_icon_window_mark "󰃀 "
set -g @catppuccin_icon_window_silent "󰂛 "
set -g @catppuccin_icon_window_activity "󱅫 "
set -g @catppuccin_icon_window_bell "󰂞 "
#set -g @catppuccin_window_status_enable "yes"
set -g @catppuccin_status_modules_right "directory user host date_time session"
set -g status-right-length 100
#set -g status-right "#{E:@catppuccin_status_directory}"
#set -ag status-right "#{E:@catppuccin_status_user}"
#set -ag status-right "#{E:@catppuccin_status_host}"
#set -ag status-right "#{E:@catppuccin_status_date_time}"
#set -agF status-right "#{E:@catppuccin_status_session}"
set -g status-left ""
'';
}
better-mouse-mode

View File

@ -1,81 +0,0 @@
{ inputs, ... }:
let
inherit (inputs) yazi-plugins mediainfo-yazi starship-yazi open-with-cmd-yazi;
in
{
programs = {
yazi = {
enable = true;
enableZshIntegration = true;
shellWrapperName = "y";
plugins = {
chmod = "${yazi-plugins}/chmod.yazi";
#full-border = "${yazi-plugins}/full-border.yazi";
git = "${yazi-plugins}/git.yazi";
smart-enter = "${yazi-plugins}/smart-enter.yazi";
starship = starship-yazi;
mediainfo = mediainfo-yazi;
open-with-cmd = open-with-cmd-yazi;
};
initLua = ''
--require("full-border"):setup()
require("starship"):setup()
require("git"):setup()
require("smart-enter"):setup({
open_multi = true,
})
'';
settings = {
sort_by = "name";
sort_dir_first = true;
sort_reverse = false;
plugin = {
prepend_fetchers = [
{ id = "git"; name = "*"; run = "git"; }
{ id = "git"; name = "*/"; run = "git"; }
];
prepend_previewers = [
{ mime = "{image,audio,video}/*"; run = "mediainfo"; }
{ mime = "application/subrip"; run = "mediainfo"; }
];
};
};
keymap = {
manager.prepend_keymap = [
{ on = "K"; run = "seek -20"; desc = "Seek up 20 units in the preview"; }
{ on = "J"; run = "seek 20"; desc = "Seek down 20 units in the preview"; }
{
run = "cd /media/net/svartalbenheim/media_data/";
on = [ "g" "m" ];
desc = "Cd to media_data";
}
{
run = "cd /media/net/svartalbenheim/media_data/media/Video";
on = [ "g" "v" ];
desc = "Cd to media_data";
}
{
run = "cd /media/net/svartalbenheim/media_data/media/Audio";
on = [ "g" "a" ];
desc = "Cd to media_data";
}
{
run = "plugin smart-enter";
on = [ "l" ];
desc = "Enter the child directory, or open the file";
}
{
on = "o";
run = "plugin open-with-cmd --args=block";
desc = "Open with command in the terminal";
}
{
on = "O";
run = "plugin open-with-cmd";
desc = "Open with command";
}
];
};
};
};
}

View File

@ -3,17 +3,19 @@
zsh = {
defaultKeymap = "emacs";
dotDir = ".config/zsh";
shellAliases = {
j = "z";
ji = "zi";
};
initExtra = builtins.readFile ../../../../configs/home-manager/zsh/zshrc.zsh;
initExtraBeforeCompInit = builtins.readFile ../../../../configs/home-manager/zsh/zshrc_before_compinit.zsh;
autosuggestion.enable = true;
completionInit = ''
autoload -U compinit bashcompinit
compinit
bashcompinit'';
history = {
path = "${config.xdg.cacheHome}/zsh_history";
save = 10000;
size = 10000;
save = 100000;
size = 100000;
share = true;
extended = true;
};
@ -26,18 +28,18 @@
"^[[A"
];
};
antidote = {
zplug = {
enable = true;
plugins = [
"Aloxaf/fzf-tab"
"zdharma-continuum/fast-syntax-highlighting"
"nix-community/nix-zsh-completions"
"zsh-users/zsh-completions"
{ name = "zsh-users/zsh-completions"; }
{ name = "zdharma-continuum/fast-syntax-highlighting"; }
{ name = "zsh-users/zsh-autosuggestions"; }
{ name = "nix-community/nix-zsh-completions"; }
];
};
shellAliases = {
eza = "eza --color=always --git --icons=always";
};
envExtra = ''
export DIRENV_LOG_FORMAT=$'\033[2mdirenv: %s\033[0m'
'';
};
};
}

View File

@ -1,20 +0,0 @@
{ inputs, vars, ... }: {
imports = [
inputs.sops-nix.homeManagerModules.sops
];
sops = {
#age.keyFile = "/home/${vars.username}/.sops-key.txt"; # must have no password!
# It's also possible to use a ssh key, but only when it has no password:
age.sshKeyPaths = [ "/etc/ssh/ssh_host_ed25519_key" ];
defaultSopsFile = ../../../secrets/general.yaml;
secrets.hello = {
# sopsFile = ./secrets.yml.enc; # optionally define per-secret files
# %r gets replaced with a runtime directory, use %% to specify a '%'
# sign. Runtime dir is $XDG_RUNTIME_DIR on linux and $(getconf
# DARWIN_USER_TEMP_DIR) on darwin.
path = "%r/hello";
};
};
}

View File

@ -5,8 +5,6 @@
stateVersion = "23.11";
sessionVariables = {
EDITOR = "vim";
DIRENV_LOG_FORMAT = "`tput dim`%s`tput sgr0`";
DOOMWADDIR = "$HOME/Games/doom/IWADs";
};
};
}

View File

@ -3,9 +3,11 @@
nix = {
settings = {
substituters = [
"http://nixcache.odie.home.arpa"
"https://nix-community.cachix.org"
];
trusted-public-keys = [
"nixcache.odie.home.arpa:2j5qAVmtBUSZMPWlIRS8Gn0Il9tbotJ9c2y43N0RLKU="
"nix-community.cachix.org-1:mB9FSh9qf2dCimDSUo8Zy7bkq5CX+/rkCWyvRCYg3Fs="
];
};

View File

@ -1,53 +1,20 @@
{ inputs, overlays, lib, config, ... }: {
{overlays, ...}: {
nixpkgs = {
config.allowUnfree = true;
inherit overlays;
};
nix =
let
flakeInputs = lib.filterAttrs (_: lib.isType "flake") inputs;
in
{
nix = {
optimise = {
automatic = true;
};
channel.enable = false;
registry = lib.mapAttrs (_: flake: { inherit flake; }) flakeInputs;
nixPath = lib.mapAttrsToList (n: _: "${n}=flake:${n}") flakeInputs;
settings = {
trusted-users = [ "@wheel" ];
experimental-features = ["nix-command" "flakes"];
auto-optimise-store = true;
substituters = [
"https://nix-community.cachix.org"
"http://nix-cache.gaja-group.intranet:5000"
];
trusted-public-keys = [
"nix-cache.gaja-group.intranet:EcUsafvI9NUrnab3DA71s2PGjAYMgct0FOvCwdYuStw="
"nix-community.cachix.org-1:mB9FSh9qf2dCimDSUo8Zy7bkq5CX+/rkCWyvRCYg3Fs="
];
nix-path = config.nix.nixPath;
flake-registry = "";
};
gc = {
automatic = true;
dates = "weekly";
options = "--delete-older-than 30d";
};
buildMachines = [
{
hostName = "nix-cache.gaja-group.intranet";
protocol = "ssh-ng";
systems = [ "x86_64-linux" "aarch64-linux" ];
maxJobs = 4;
speedFactor = 2;
supportedFeatures = [ "nixos-test" "benchmark" "big-parallel" "kvm" ];
mandatoryFeatures = [ ];
}
];
distributedBuilds = true;
extraOptions = ''
builders-use-substitutes = true
'';
};
}

View File

@ -1,4 +1,4 @@
{ pkgs, ... }:
{ config, lib, pkgs, vars, ... }:
{
environment = {
systemPackages = with pkgs; [
@ -11,8 +11,6 @@
iftop
iotop
ncdu
wget
openssl
];
etc = {
"ncdu.conf".text = ''

View File

@ -11,14 +11,5 @@
environment.systemPackages = with pkgs; [
libcec
];
nixpkgs = {
overlays = [
(final: prev: {
makeModulesClosure = x: prev.makeModulesClosure (x // { allowMissing = true; });
libcec = prev.libcec.override { withLibraspberrypi = true; };
})
];
};
};
}

View File

@ -1,13 +1,13 @@
{ config
, lib
, pkgs
, vars
, ...
}:
let
inherit (vars) username name sshKeys;
{
config,
lib,
pkgs,
vars,
...
}: let
inherit (vars) username name locale hostname sshKeys;
extraGroups = vars.extraGroups ++ [
baseGroups = [
"users"
"wheel"
"audio"
@ -16,14 +16,19 @@ let
"power"
"adm"
"plugdev"
] ++ lib.optionals config.hardware.raspberry-pi.enable [
];
rpiGroups =
if config.hardware.raspberry-pi.enable
then [
"i2c"
"spi"
];
]
else [];
extraGroups = baseGroups ++ rpiGroups;
basePackages = with pkgs; [home-manager];
wslPackages =
if ((builtins.hasAttr "wsl" config) && config.wsl.enable)
if config.wsl.enable
then
with pkgs; [
wslu
@ -31,8 +36,7 @@ let
]
else [];
packages = basePackages ++ wslPackages;
in
{
in {
options = {
hardware.raspberry-pi.enable = lib.mkEnableOption "raspberry pi features";
};
@ -40,9 +44,6 @@ in
users = {
groups.${username} = {};
users = {
root = {
openssh.authorizedKeys.keys = sshKeys;
};
${username} = {
inherit packages extraGroups;
name = username;

View File

@ -2,6 +2,5 @@ _: {
imports = [
./base
./wsl
./sops
];
}

View File

@ -12,20 +12,12 @@
config = {
programs.dconf.enable = lib.mkDefault true;
#hardware.opengl.enable = lib.mkDefault true;
hardware.graphics.enable = lib.mkDefault true;
hardware.opengl.enable = lib.mkDefault true;
desktop.enable = lib.mkDefault true;
security.polkit.enable = lib.mkDefault true;
services = {
upower.enable = lib.mkDefault true;
gvfs.enable = lib.mkDefault true;
};
services.gnome.gnome-keyring.enable = true;
qt = {
enable = true;
platformTheme = "qt5ct";
style = "kvantum";
};
};
}

View File

@ -7,8 +7,7 @@
noto-fonts
noto-fonts-emoji
sarasa-gothic
nerd-fonts.symbols-only
#(nerdfonts.override { fonts = [ "NerdFontsSymbolsOnly" ]; })
(nerdfonts.override { fonts = [ "NerdFontsSymbolsOnly" ]; })
];
fontconfig = {
antialias = true;

View File

@ -13,4 +13,6 @@ lib.mkIf config.desktop.enable {
pulse.enable = true;
wireplumber.enable = true;
};
sound.enable = true;
}

View File

@ -1,8 +1,9 @@
{ lib
, config
, vars
, pkgs
, ...
{
lib,
config,
vars,
pkgs,
...
}: {
imports = [
./i18n.nix
@ -28,7 +29,6 @@
vicious
];
};
};
libinput = {
enable = true;
@ -44,4 +44,5 @@
};
};
};
};
}

View File

@ -1,6 +0,0 @@
{
imports = [
./minecraft
./wow
];
}

View File

@ -1,101 +0,0 @@
{ inputs, lib, ... }:
with lib;
let
operators = {
masterodie = {
uuid = "c0e67091-d6d0-4cf2-89d5-d0c6f2bd4f30";
level = 4;
bypassesPlayerLimit = true;
};
Rooomi = {
uuid = "5c5b4a28-e292-46fa-bf92-3b21f577c30e";
level = 4;
bypassesPlayerLimit = true;
};
};
whitelist = { } // attrsets.mapAttrs (n: v: v.uuid) operators;
jvmArgs = "-XX:+UnlockExperimentalVMOptions -XX:+UnlockDiagnosticVMOptions -XX:+AlwaysActAsServerClassMachine -XX:+AlwaysPreTouch -XX:+DisableExplicitGC -XX:+UseNUMA -XX:NmethodSweepActivity=1 -XX:ReservedCodeCacheSize=400M -XX:NonNMethodCodeHeapSize=12M -XX:ProfiledCodeHeapSize=194M -XX:NonProfiledCodeHeapSize=194M -XX:-DontCompileHugeMethods -XX:MaxNodeLimit=240000 -XX:NodeLimitFudgeFactor=8000 -XX:+UseVectorCmov -XX:+PerfDisableSharedMem -XX:+UseFastUnorderedTimeStamps -XX:+UseCriticalJavaThreadPriority -XX:ThreadPriorityPolicy=1 -XX:AllocatePrefetchStyle=3 -XX:+UseG1GC -XX:MaxGCPauseMillis=130 -XX:+UnlockExperimentalVMOptions -XX:+DisableExplicitGC -XX:+AlwaysPreTouch -XX:G1NewSizePercent=28 -XX:G1HeapRegionSize=16M -XX:G1ReservePercent=20 -XX:G1MixedGCCountTarget=3 -XX:InitiatingHeapOccupancyPercent=10 -XX:G1MixedGCLiveThresholdPercent=90 -XX:G1RSetUpdatingPauseTimePercent=0 -XX:SurvivorRatio=32 -XX:MaxTenuringThreshold=1 -XX:G1SATBBufferEnqueueingThresholdPercent=30 -XX:G1ConcMarkStepDurationMillis=5 -XX:G1ConcRSHotCardLimit=16 -XX:G1ConcRefinementServiceIntervalMillis=150";
in
{
imports = [
inputs.minecraft-server-flake.nixosModules.minecraft-servers
];
services.minecraft-servers = {
velocitySecret = "01KqxtMy3kEH";
openFirewall = true;
domain = "odie.home.arpa";
inherit jvmArgs;
servers = {
vanilla-plus = {
inherit whitelist operators;
stopCommand = null;
enable = true;
autoStart = false;
openFirewall = true;
serverProperties = {
online-mode = false;
enforce-secure-profile = true;
server-name = "GajaCraft Survival";
server-port = 25566;
server-ip = "127.0.0.1";
difficulty = "easy";
gamemode = "survival";
max-players = 10;
white-list = true;
enforce-whitelist = true;
pause-when-empty-seconds = 1;
force-gamemode = true;
view-distance = 12;
};
};
flat = {
inherit whitelist operators;
enable = true;
stopCommand = null;
autoStart = false;
serverProperties = {
online-mode = false;
enforce-secure-profile = true;
server-name = "GajaCraft Creative Flat";
server-port = 25567;
server-ip = "127.0.0.1";
difficulty = "hard";
gamemode = "creative";
max-players = 10;
white-list = true;
enforce-whitelist = true;
pause-when-empty-seconds = 1;
force-gamemode = true;
view-distance = 12;
generate-structures = false;
level-type = "minecraft:flat";
generator-settings = ''{"biome": "minecraft:desert", "layers": [ { "block": "minecraft:bedrock", "height": 1 }, { "block": "minecraft:sandstone", "height": 62 } ] }'';
};
};
velocity.enable = true;
};
extraOptions = {
flat = {
memory = "2G";
port = 25567;
mapPort = 8101;
voicePort = 24455;
blacklist = [ "Discord" "bluemap" "bmm-fabric" ];
whitelist = [ "worldedit" ];
};
vanilla-plus = {
memory = "4G";
port = 25566;
mapPort = 8100;
voicePort = 24454;
blacklist = [ "Discord" "bluemap" "bmm-fabric" ];
whitelist = [ "worldedit" ];
};
velocity = {
port = 25565;
mapPort = 8100;
voicePort = 24454;
};
};
};
}

View File

@ -1,459 +0,0 @@
{ config, lib, pkgs, ... }:
with lib;
let
cfg = config.services.azerothcore;
in
{
options.services.azerothcore = {
enable = mkEnableOption "AzerothCore service";
openFirewall = mkOption {
type = types.bool;
default = false;
description = mdDoc "Whether to open the firewall for the auth & world server ports.";
};
serverPackage = mkPackageOption pkgs "azerothcore" { };
clientDataPackage = mkPackageOption pkgs "azerothcore-data" { };
srcDir = mkOption {
type = types.path;
default = "${pkgs.azerothcore}/share";
description = mdDoc "The data directory";
};
dataDir = mkOption {
type = types.path;
default = "${pkgs.azerothcore-data}";
description = mdDoc "The data directory";
};
logDir = mkOption {
type = types.path;
default = "/var/log/azerothcore";
description = mdDoc "The log directory";
};
tmpDir = mkOption {
type = types.path;
default = "/tmp/azerothcore";
description = mdDoc "The tmp directory to use";
};
hostname = mkOption {
type = types.str;
default = "127.0.0.1";
description = lib.mdDoc "The hostname to reach the server.";
};
database = mkOption {
type = types.submodule {
options = {
user = mkOption {
type = types.str;
description = mdDoc "The MySQL database user to use for auth & world servers.";
};
password = mkOption {
type = types.str;
description = mdDoc "The MySQL database password to use for auth & world servers.";
};
host = mkOption {
type = types.str;
description = mdDoc "The MySQL host to use for auth & world servers.";
};
port = mkOption {
type = types.port;
description = mdDoc "The port host to use for auth & world servers.";
};
};
};
default = {
user = "acore";
password = "";
host = "127.0.0.1";
port = 3306;
};
description = mdDoc "Database configuration.";
};
auth = mkOption {
type = types.submodule {
options = {
port = mkOption {
type = types.port;
description = lib.mdDoc "Port to listen on for the auth server.";
};
address = mkOption {
type = types.str;
description = mdDoc "Address to listen on for the auth server.";
};
database = mkOption {
type = types.str;
description = "Database name for the auth server.";
};
};
};
default = {
port = 3724;
address = "0.0.0.0";
database = "acore_auth";
};
description = mdDoc "Auth server configuration.";
};
world = mkOption {
type = types.submodule {
options = {
realmId = mkOption {
type = types.int;
description = lib.mdDoc "Port to listen on for the worl server.";
};
port = mkOption {
type = types.port;
description = lib.mdDoc "Port to listen on for the worl server.";
};
address = mkOption {
type = types.str;
description = mdDoc "Address to listen on for the world server.";
};
database = mkOption {
type = types.str;
description = "Database name for the world server.";
};
charactersDatabase = mkOption {
type = types.str;
description = "Characters database name for the world server.";
};
};
};
default = {
realmId = 1;
port = 8085;
address = "0.0.0.0";
database = "acore_world";
charactersDatabase = "acore_characters";
};
description = mdDoc "World server configuration.";
};
npcbots = mkOption {
type = types.submodule {
options = {
botgiver = {
filterRaces = mkOption {
type = types.int;
};
};
classes = {
warrior = mkOption {
type = types.bool;
};
paladin = mkOption {
type = types.bool;
};
hunter = mkOption {
type = types.bool;
};
rogue = mkOption {
type = types.bool;
};
priest = mkOption {
type = types.bool;
};
deathKnight = mkOption {
type = types.bool;
};
shaman = mkOption {
type = types.bool;
};
mage = mkOption {
type = types.bool;
};
warlock = mkOption {
type = types.bool;
};
druid = mkOption {
type = types.bool;
};
blademaster = mkOption {
type = types.bool;
};
obsidianDestroyer = mkOption {
type = types.bool;
};
archmage = mkOption {
type = types.bool;
};
dreadlord = mkOption {
type = types.bool;
};
spellBreaker = mkOption {
type = types.bool;
};
darkRanger = mkOption {
type = types.bool;
};
necromancer = mkOption {
type = types.bool;
};
seaWitch = mkOption {
type = types.bool;
};
cryptLord = mkOption {
type = types.bool;
};
};
};
};
default = {
botgiver = {
filterRaces = 0;
};
classes = {
warrior = true;
paladin = true;
hunter = true;
rogue = true;
priest = true;
deathKnight = true;
shaman = true;
mage = true;
warlock = true;
druid = true;
blademaster = false;
obsidianDestroyer = true;
archmage = true;
dreadlord = true;
spellBreaker = true;
darkRanger = true;
necromancer = true;
seaWitch = true;
cryptLord = true;
};
};
};
ahbot = mkOption {
type = types.submodule {
options = {
EnableSeller = mkOption {
type = types.int;
};
EnableBuyer = mkOption {
type = types.int;
};
Account = mkOption {
type = types.int;
};
GUID = mkOption {
type = types.int;
};
ItemsPerCycle = mkOption {
type = types.int;
};
ElapsingTimeClass = mkOption {
type = types.int;
};
VendorItems = mkOption {
type = types.int;
};
VendorTradeGoods = mkOption {
type = types.int;
};
LootItems = mkOption {
type = types.int;
};
LootTradeGoods = mkOption {
type = types.int;
};
OtherItems = mkOption {
type = types.int;
};
OtherTradeGoods = mkOption {
type = types.int;
};
ProfessionItems = mkOption {
type = types.int;
};
};
};
default = {
EnableSeller = 0;
EnableBuyer = 0;
Account = 0;
GUID = 0;
ItemsPerCycle = 200;
ElapsingTimeClass = 1;
VendorItems = 0;
VendorTradeGoods = 0;
LootItems = 1;
LootTradeGoods = 1;
OtherItems = 0;
OtherTradeGoods = 0;
ProfessionItems = 0;
};
};
};
config = mkIf cfg.enable {
users.users.azerothcore = {
home = cfg.dataDir;
createHome = true;
isSystemUser = true;
group = "azerothcore";
};
users.groups.azerothcore.name = "azerothcore";
networking.firewall.allowedTCPPorts = mkIf cfg.openFirewall [
cfg.auth.port
cfg.world.port
];
environment.etc =
{
"azerothcore/authserver.conf".source = pkgs.runCommand "authserver.conf"
{ } ''
cp ${cfg.serverPackage}/etc/authserver.conf.dist $out
'';
"azerothcore/worldserver.conf".source = pkgs.runCommand "worldserver.conf"
{ } ''
cp ${cfg.serverPackage}/etc/worldserver.conf.dist $out
'';
"azerothcore/dbimport.conf".source = pkgs.runCommand "dbimport.conf"
{ } ''
cp ${cfg.serverPackage}/etc/dbimport.conf.dist $out
'';
"azerothcore/modules/mod_ahbot.conf".source = pkgs.runCommand "mod_ahbot.conf"
{ } ''
cp ${cfg.serverPackage}/etc/modules/mod_ahbot.conf.dist $out
'';
};
systemd.services =
let
env_key = prefix: key: "${prefix}_${key}";
ac_env_key = env_key "AC";
npcbot_env_key = env_key "AC_NPC_BOT";
ahbot_env_key = env_key "AC_AUCTION_HOUSE_BOT";
mysqlHost = "${cfg.database.host}";
mysqlPort = toString cfg.database.port;
mysqlSocket = "/run/mysqld/mysqld.sock";
databaseInfo = (user: password: database: (if mysqlHost == "127.0.0.1" then ".;${mysqlSocket};${user};${password};${database}" else "${mysqlHost};${mysqlPort};${user};${password};${database}")) cfg.database.user cfg.database.password;
authDatabaseInfo = databaseInfo cfg.auth.database;
worldDatabaseInfo = databaseInfo cfg.world.database;
characterDatabaseInfo = databaseInfo cfg.world.charactersDatabase;
in
{
azerothcore-authserver = {
description = "AzerothCore Auth Server";
after = [ "network-online.target" "mysql.service" ];
wants = [ "network-online.target" "mysql.service" ];
environment = {
"${ac_env_key "CONSOLE_ENABLE"}" = "0";
"${ac_env_key "DATA_DIR"}" = cfg.clientDataPackage;
"${ac_env_key "LOGS_DIR"}" = cfg.logDir;
"${ac_env_key "TMP_DIR"}" = cfg.tmpDir;
"${ac_env_key "SOURCE_DIRECTORY"}" = toString cfg.serverPackage.srcDir;
"${ac_env_key "REALM_SERVER_PORT"}" = toString cfg.auth.port;
"${ac_env_key "BIND_IP"}" = cfg.auth.address;
"${ac_env_key "LOGIN_DATABASE_INFO"}" = authDatabaseInfo;
};
serviceConfig = {
Type = "simple";
User = "azerothcore";
Group = "azerothcore";
Restart = "on-failure";
ExecStart = "${cfg.serverPackage}/bin/authserver -c /etc/azerothcore/authserver.conf";
};
};
azerothcore-worldserver = {
description = "AzerothCore World Server";
after = [ "network-online.target" "mysql.service" ];
wants = [ "network-online.target" "mysql.service" ];
environment = {
"${ac_env_key "REALM_ID"}" = "${toString cfg.world.realmId}";
"${ac_env_key "CONSOLE_ENABLE"}" = "0";
"${ac_env_key "DATA_DIR"}" = "${cfg.clientDataPackage}";
"${ac_env_key "LOGS_DIR"}" = "${cfg.logDir}";
"${ac_env_key "TMP_DIR"}" = cfg.tmpDir;
"${ac_env_key "SOURCE_DIRECTORY"}" = cfg.serverPackage.srcDir;
"${ac_env_key "WORLD_SERVER_PORT"}" = toString cfg.world.port;
"${ac_env_key "BIND_IP"}" = cfg.world.address;
"${ac_env_key "LOGIN_DATABASE_INFO"}" = authDatabaseInfo;
"${ac_env_key "WORLD_DATABASE_INFO"}" = worldDatabaseInfo;
"${ac_env_key "CHARACTER_DATABASE_INFO"}" = characterDatabaseInfo;
"${npcbot_env_key "BOTGIVER_FILTER_RACES"}" = toString cfg.npcbots.botgiver.filterRaces;
"${npcbot_env_key "CLASSES_WARRIOR_ENABLE"}" = if cfg.npcbots.classes.warrior then "1" else "0";
"${npcbot_env_key "CLASSES_PALADIN_ENABLE"}" = if cfg.npcbots.classes.paladin then "1" else "0";
"${npcbot_env_key "CLASSES_HUNTER_ENABLE"}" = if cfg.npcbots.classes.hunter then "1" else "0";
"${npcbot_env_key "CLASSES_ROGUE_ENABLE"}" = if cfg.npcbots.classes.rogue then "1" else "0";
"${npcbot_env_key "CLASSES_PRIEST_ENABLE"}" = if cfg.npcbots.classes.priest then "1" else "0";
"${npcbot_env_key "CLASSES_DEATH_KNIGHT_ENABLE"}" = if cfg.npcbots.classes.deathKnight then "1" else "0";
"${npcbot_env_key "CLASSES_SHAMAN_ENABLE"}" = if cfg.npcbots.classes.shaman then "1" else "0";
"${npcbot_env_key "CLASSES_MAGE_ENABLE"}" = if cfg.npcbots.classes.mage then "1" else "0";
"${npcbot_env_key "CLASSES_WARLOCK_ENABLE"}" = if cfg.npcbots.classes.warlock then "1" else "0";
"${npcbot_env_key "CLASSES_DRUID_ENABLE"}" = if cfg.npcbots.classes.druid then "1" else "0";
"${npcbot_env_key "CLASSES_BLADEMASTER_ENABLE"}" = if cfg.npcbots.classes.blademaster then "1" else "0";
"${npcbot_env_key "CLASSES_OBSIDIAN_DESTROYER_ENABLE"}" = if cfg.npcbots.classes.obsidianDestroyer then "1" else "0";
"${npcbot_env_key "CLASSES_ARCHMAGE_ENABLE"}" = if cfg.npcbots.classes.archmage then "1" else "0";
"${npcbot_env_key "CLASSES_DREADLORD_ENABLE"}" = if cfg.npcbots.classes.dreadlord then "1" else "0";
"${npcbot_env_key "CLASSES_SPELL_BREAKER_ENABLE"}" = if cfg.npcbots.classes.spellBreaker then "1" else "0";
"${npcbot_env_key "CLASSES_DARK_RANGER_ENABLE"}" = if cfg.npcbots.classes.darkRanger then "1" else "0";
"${npcbot_env_key "CLASSES_NECROMANCER_ENABLE"}" = if cfg.npcbots.classes.necromancer then "1" else "0";
"${npcbot_env_key "CLASSES_SEA_WITCH_ENABLE"}" = if cfg.npcbots.classes.seaWitch then "1" else "0";
"${npcbot_env_key "CLASSES_CRYPT_LORD_ENABLE"}" = if cfg.npcbots.classes.cryptLord then "1" else "0";
"${ahbot_env_key "ENABLE_SELLER"}" = toString cfg.ahbot.EnableSeller;
"${ahbot_env_key "ENABLE_BUYER"}" = toString cfg.ahbot.EnableBuyer;
"${ahbot_env_key "ACCOUNT"}" = toString cfg.ahbot.Account;
"${ahbot_env_key "GUID"}" = toString cfg.ahbot.GUID;
"${ahbot_env_key "ITEMS_PER_CYCLE"}" = toString cfg.ahbot.ItemsPerCycle;
"${ahbot_env_key "ELAPSING_TIME_CLASS"}" = toString cfg.ahbot.ElapsingTimeClass;
"${ahbot_env_key "VENDOR_ITEMS"}" = toString cfg.ahbot.VendorItems;
"${ahbot_env_key "VENDOR_TRADE_GOODS"}" = toString cfg.ahbot.VendorTradeGoods;
"${ahbot_env_key "LOOT_ITEMS"}" = toString cfg.ahbot.LootItems;
"${ahbot_env_key "LOOT_TRADE_GOODS"}" = toString cfg.ahbot.LootTradeGoods;
"${ahbot_env_key "OTHER_ITEMS"}" = toString cfg.ahbot.OtherItems;
"${ahbot_env_key "OTHER_TRADE_GOODS"}" = toString cfg.ahbot.OtherTradeGoods;
"${ahbot_env_key "PROFESSION_ITEMS"}" = toString cfg.ahbot.ProfessionItems;
};
serviceConfig = {
Type = "simple";
User = "azerothcore";
Group = "azerothcore";
WorkingDirectory = "/etc/azerothcore";
Restart = "on-failure";
ExecStart = "${cfg.serverPackage}/bin/worldserver -c /etc/azerothcore/worldserver.conf";
};
};
azerothcore = rec {
description = "AzerothCore";
wantedBy = [ "multi-user.target" ];
wants = [ "azerothcore-auth.service" "azerothcore-world.service" ];
after = wants;
};
};
systemd.tmpfiles.rules = [
"d ${cfg.logDir} 1755 azerothcore azerothcore - -"
"d ${cfg.tmpDir} 1755 azerothcore azerothcore - -"
];
services.mysql = {
enable = true;
package = lib.mkDefault pkgs.mysql80;
ensureDatabases = [
cfg.auth.database
cfg.world.database
cfg.world.charactersDatabase
];
ensureUsers = [{
name = cfg.database.user;
ensurePermissions = {
"${cfg.auth.database}.*" = "ALL PRIVILEGES";
"${cfg.world.database}.*" = "ALL PRIVILEGES";
"${cfg.world.charactersDatabase}.*" = "ALL PRIVILEGES";
};
}];
};
};
}

View File

@ -1,5 +0,0 @@
{
imports = [
./azerothcore
];
}

View File

@ -1,30 +1,10 @@
{ flakeLib
, inputs
, outputs
, vars
, ...
}:
let
inherit (vars) username hostName;
profile = "${username}@${hostName}";
in
{
moduleInputs @ {flakeLib, inputs, ...}: let
config = flakeLib.mkHomeManagerDefaults moduleInputs;
in {
imports = [
inputs.home-manager.nixosModules.home-manager
];
home-manager = {
extraSpecialArgs = {
inherit inputs outputs vars flakeLib;
inherit (inputs) nix-colors;
};
useGlobalPkgs = true;
useUserPackages = true;
users.${username} = {
imports = [
../../../profiles/home-manager/${profile}/home.nix
];
};
backupFileExtension = "backup";
inherit (config) extraSpecialArgs useGlobalPkgs useUserPackages;
};
}

View File

@ -1,25 +0,0 @@
{ config, ... }: {
config = {
services = {
sonarr = {
enable = true;
};
radarr = {
enable = true;
};
prowlarr = {
enable = true;
};
jellyseerr = {
enable = false;
};
};
networking.firewall.allowedTCPPorts = [
];
nixpkgs.config.permittedInsecurePackages = [
"dotnet-sdk-6.0.428"
"aspnetcore-runtime-6.0.36"
];
};
}

View File

@ -1,10 +1,8 @@
_:
{
{lib, ...}:
with lib; {
imports = [
./arr
./kodi
./jellyfin
./gokosync
./torrent
];
mediacenter.kodi.enable = mkDefault true;
}

View File

@ -1,4 +0,0 @@
{ inputs, ... }: {
nixpkgs.overlays = [ inputs.gokosync.overlays.default ];
imports = [ inputs.gokosync.nixosModules.default ];
}

View File

@ -1,84 +0,0 @@
{ pkgs, lib, config, ... }:
with lib;
let
cfg = config.services.jellyfin;
extraGroups = [
"users"
"audio"
"video"
"disk"
"power"
"plugdev"
] ++ lib.optionals config.hardware.raspberry-pi.enable [
"i2c"
"spi"
];
in
{
imports = [
(import ../../../../lib/genSslCert.nix {
name = "jellyfin";
inherit (cfg) dataDir user;
domain = "pi0.odie.home.arpa";
wantedBy = [ "jellyfin.service" ];
Before = [ "jellyfin.service" ];
})
];
options = {
services.jellyfin.domain = mkOption {
type = types.str;
default = "localhost";
};
};
config = {
services.jellyfin = {
enable = true;
openFirewall = true;
dataDir = "/media/net/svartalbenheim/media_config/data/jellyfin";
cacheDir = "/media/net/svartalbenheim/media_config/cache/jellyfin";
};
users.users.jellyfin = mkIf config.services.jellyfin.enable {
inherit extraGroups;
};
networking.firewall = {
allowedUDPPorts = [ 1900 ];
allowedTCPPorts = [ 8920 ];
};
security.pki.certificates = [
''
-----BEGIN CERTIFICATE-----
MIIFGzCCAwOgAwIBAgIUNHajISouQmW1yBoODpk3Yd6tXs4wDQYJKoZIhvcNAQEL
BQAwHTEbMBkGA1UEAwwScGkwLm9kaWUuaG9tZS5hcnBhMB4XDTI1MDExMDA3Mjg1
NFoXDTI1MDIwOTA3Mjg1NFowHTEbMBkGA1UEAwwScGkwLm9kaWUuaG9tZS5hcnBh
MIICIjANBgkqhkiG9w0BAQEFAAOCAg8AMIICCgKCAgEAzn4txPhKVq/mrHpyICkl
yFw0gTPZ/wUdnvUu8r9IZu5UjNgygyHN1H5x5T+XSDxbGNjtNZLxLMlCIKPbVFhx
JJLdDuAbeVZ/Et69az3RtLgJ93uyL6B8xD4N0GuPNwz0UhqCNcp+NlljmntFaONa
rH0J4A9TnJfbVAcMlXs13v9WNP0qTrcAdLjmYp3Bhfp5Vugtf7J3z4xaLXX4MQzQ
CNXixB1jDmiy3nespCQAIwHIiMqLXI8MP7UiMcKglH4UB2rf1wv67Bgl7DLo+KzZ
fU/eD9EdssZ+4pYbRxf6WMKi8wSw+4QfxF9Flv9jDn+cqt1drgcr2GdvzsAPg0Ab
HTCmgRJv7VyZr0p6o6pYLugXzEiOXEk2ClD+wJmCZQv6yHI47CnGgAxIG5FFVwvc
94lk06nKLfURdeEXaG/36BDKpdZNI58StYwUFl65BXi07MimObCaJ18T8m6JpaSl
u/GhKDH00ryoPxUwDjLNTqt2Fb/wYX+rKhLmjqkkba+FtBjlwr7WtlspFtsPTLvb
mCiQWGN2VWeXk0mBEXMIgN6ECiFlBtc0wZGlALFao++GDME45o+swNr9HJMxKQpr
QlOWRDxHean6Fl8SRCtGM5XmclNeCBuu/lAC9nBI0d10dipG2R+lltwQqu5aXuNP
9M43J6ANP5C6vR/PopyTqC8CAwEAAaNTMFEwHQYDVR0OBBYEFND5BOssGEusttif
GncLz2BlEqUMMB8GA1UdIwQYMBaAFND5BOssGEusttifGncLz2BlEqUMMA8GA1Ud
EwEB/wQFMAMBAf8wDQYJKoZIhvcNAQELBQADggIBAIRIDQ07MySPXOPyAYNxF1Mz
2+MyM3N8YKIZy6I6bQ9xK8u6FIyBtfxVqd3c9sDa1aam2etmbpe32GT0oQilr3EQ
eBh9MPCSLHtfIT2MCmUFx9y+ygCRsO1hMSnlQpVOKt4HbU+3Bg/iV8eBQlAsYuzK
BWzvmMM95uhiB0l/7QRjse71tG1kOCc8b6/LpQms2kSmJ0x3JEF9FRscACdE11ek
mdqTbY0SEw+LEGg7yECg9O8iG4nRTsAbyb78GuXOGeoeEPAgyAF7Iwn488lSyb4f
zXvU66aSyP0kTWh7JgKK1iU7ecvUkhCFNtswb5CTuADlhA6ravkvaQk6fZAGRAx0
uV8mhKwM3+xktIKEsNvSPCjNSSsj+dN3Vv74Sbu8oeOZ+jT1/jP5yorRIsahpqIM
fGMYgdJ62A20MpDKdObdZsoPIN1KaKk6tuW2TjNO4HmcEDBpyIX7vi3Pkq4/+9VR
4lfJt2xqsL7XAAJCIuY122SZGLn9m9K6E+4irzOjmdow3CPSYuvUBvTMh2DyxBWU
zkVpmGkad4e+xpBelm1RV2jzWg0x7FAkr4DGCws3Pq6G0AhsOv4OpVmmvAxAlQOe
4keAD5gL9bCYywH33Y2ccCB42BNwd6HmiDBsmli++szUoOlFUjQIKQ/6S2H+pw/S
UHQ+hpji7ZS9AH4oeHIG
-----END CERTIFICATE-----
''
];
};
}

View File

@ -1,66 +1,69 @@
{ pkgs, lib, config, ... }:
let
user = "kodi";
extraGroups = [
"users"
"audio"
"video"
"disk"
"power"
"plugdev"
] ++ lib.optionals config.hardware.raspberry-pi.enable [
"i2c"
"spi"
];
in
{
pkgs,
config,
lib,
...
}: let
cfg = config.mediacenter.kodi;
in
with lib; {
options = {
mediacenter.kodi = {
enable = mkEnableOption "kodi";
};
};
config = let
user = "kodi";
starter = pkgs.callPackage (
{pkgs, kodi-standalone, ...}:
pkgs.writeShellApplication {
name = "kodi-launcher";
runtimeInputs = [kodi-standalone];
text = ''
#!/usr/bin/env bash
while true
do
ping -c1 svartalbenheim.odie.intranet && break
sleep 5
done
while true
do
sleep 1
kodi-standalone
done
'';
}
) {};
in
lib.mkIf cfg.enable {
services.cage = {
inherit user;
enable = true;
program = "${pkgs.kodi-standalone}/bin/kodi-standalone";
program = "${starter}/bin/kodi-launcher";
};
users.users.kodi = {
inherit extraGroups;
name = user;
isNormalUser = true;
};
sops.secrets = {
"kodi-advancedsettings" = {
owner = user;
format = "binary";
sopsFile = ./secrets/advancedsettings.xml;
path = "/home/${user}/.kodi/userdata/advancedsettings.xml";
};
"kodi-passwords" = {
owner = user;
format = "binary";
sopsFile = ./secrets/passwords.xml;
path = "/home/${user}/.kodi/userdata/passwords.xml";
};
"kodi-youtube" = {
owner = user;
format = "binary";
sopsFile = ./secrets/youtube.json;
path = "/home/${user}/.kodi/userdata/addon_data/plugin.video.youtube/api_keys.json";
};
extraGroups = [
"audio"
"video"
"disk"
"plugdev"
"i2c"
"spi"
"power"
];
};
networking.firewall.allowedTCPPorts = [8080 9090];
environment.sessionVariables = {
WLR_LIBINPUT_NO_DEVICES = builtins.toString 1;
};
systemd.tmpfiles.rules = [
"d /home/kodi/.kodi/temp 0750 kodi users -"
];
environment.systemPackages = with pkgs; [
#kodi-standalone
kodi-standalone
alsa-utils
/*
(retroarch.override {
cores = with libretro; [
snes9x
@ -68,6 +71,6 @@ in
nestopia
];
})
*/
];
};
}

View File

@ -1,24 +0,0 @@
{
"data": "ENC[AES256_GCM,data:qyQMBXvTmNZ105SBtOUvmefsBwiTsyf4v/yhSqO82aFhnKOAy3vrU9ePpJW70HX0aSpflvOfF7rHKOd9Qwy+HDaztNU2LB+3rXI06WPawrXgDVMjGTJrfK/eA1nE1imf1KWwZpgtD3vzmOHEaAzJpNXmqwAg4+941AwUdT3uV3+lnEChOgO+XQFQrU9nhRCixpnh/us/r/Il9csnq45jyIP6rXWJsYk/ORumrsI9SZVKqw6ObxVgdOCypJRGcOS3DXHJyv8ptqsXQJCp/HLh9jgXdg8ZvlhLCnklknsGHjrmIJTwnNKbBE8AKUdOu91hGDDDyPTy636TzSa8mJ8YMDgEQcy/vMd6d9HeujWajwJ/j7SmSx5yKV0B1JO2ZJYSbb83anczysWqMdeuCRMBPQlL5MpDQYKVq0Oe9mKxjJFAaLt9t1iODIJTcwvIvV2nKIrXE4k+rCSteBOj1tAe0stk1q7X+zM1lsW4nu5CbbKtExVI9yTfANn5Bpiu6p/thotZOCp54T3PLJyqn2LAszGTVV+PafrZBIlvYO1VRMP+7YbPxq9PlnSinBYmExDvgmmPImLTgBI+v2/I+fFkcEWdgTu6XbnOqY5dkNIbX1vzGzemSbXEwoNWGOrJ93oRrcIg9BRJEMTx//u3xsl1r2bgInYOJpcv9xwbkYILoYmcWXpKteu/FGmvL7vmyyIQbDqXuS15UVjmCdvdbrSWnI86eKK6Mc6gzKQ97MpYhtGRix/k+1vlVaKID+MUkK67Xdbu4yKvKnTwjqfXgGC3iCfIF74aUP35V3kXFp52P3pjjxLxMg7GG5vagJ/6gP11E7XdKF3W35r62yTLZWYFP7O6qhHdFjsQrRd+52JjbHrFVsjAJ5ES4E/tRsmBrnJtBbFTYHuYGtp5g64YTSlhyltnoxAAd4ZJ4jpqqtyqYNwuJjVFSMPE2BpnB5cD9EDeiIiDWftWn71QyZBQc3EGxdVoeQvM9ZPd88lmlJJcr5KFIXbbC1OSp5FGXtcNwanIzc8pGh/Zlwq+NS7SpPIvYuCpptwTMx1nb/JnFoWFSNqFjdi6XxYJjnD08gb+N1B1X4KLC0A8AFojVEFT4BhOFfCp10/rUxBJepL06IKGztErtmpnXkNwfkbzyhmbtpajAUJrSm4M64WiU4Qs2G07LM01rtWDB9pwt7E7bTAcjxdXeufIn4Qu10t4hQCxA8MJeurv9FpWtb8qTA7NzgwH86dBV5u7bJ8QY8tB0TNClqdzdkBFt76S6FBgC/8wKbJ+dTAmSiS4K8mNJc6bsAZ1hI+iVQSHZEtVv4tCvDGkmUZDepZn6tjFTDeQQejvcW6ysw/OotTUntTigyRKG5NaL79Gu619aepOR4X6FhRmSMiGaDeMM/30rP0SrdNcBL8CbQ9fTPqmaK8EQdGHqCnH0W+OwswuCvKpbIF1kJsLjsBqLBKAej9lPgBJJ25R/yer5tAKyH8lL12U93UqB42mDdznbTKcFw0aXbXjY7hla5joHgdPE2oVZ/WVVsV51PRq2iv9bHpDViVnTywfBq9cN0JJ0BTWQyWd8ZfKiCrMYAGar4RR+Rhrw914wkVpwqrE/lVVU8PmGGLhrPo8lNXaZil1gRi8aemWfU6QFm6nb0hBh3W0RLZx4tAkJg7ro3jeoipLKsLqtJEV0R1/ZwPBSAlDd+sY2zpYcyUigrufwjI+J7D0IjifwmicoxB9wdtAZcBdVZ6a6rWiEBtQvOYY1TlBgsB1nHGM/bxQaxELTVL8ZKV9dHHapcV/37a2tkRwWDUj5CNjueZY9gQ4WwJ4a4N7SDlCEs+/EMTghnG0wcyUQz17EsIGGskTZpKNUse0Uw0+HCUAETMRACIy6uxLyNzWeR+PMV3Rr3inqFeL6RUhKs2XOC1PO2bPdzme9vkYPtLopxTO7rlBl2goW9btR9D5LgS4/U8RTLjh4SHPpLPgtBBCY/Q2OzmsIdGjNSxIM+Pkw+Ir/nI0kqXPp/Uny9nHJYGK8qIp2B4yZuAv/Qq1D2vH1Py6tl32O1orxoiplOP0Y1y4sGO5hMgytPXUyqTiVAn5Q3gYo/BqEF1Sj+yyyN2TQQDVExqPX0E/Q2qBDPzoSDKMNGjbNY40s/foRJJRHUxA+2mkun/n/rIIHXvNNTjZgsw8GhfjlqG2JbGjPsLO1fFfStELatijNwXxwMZSi3rCEFpPVZynNNetB0+NwWhZIOGf4Ypb9MkoK/zmi/0+NWfXFD3mda66Y+lkBqe/3PernjCKuGy4InO+MfbKG0hTvIocW+384beWAe+6khSjKatmlc1zFod1FPL6bw0H1DzQVn03H9pSrS9W9XEr9nOMxl9VMw4VboBGSq/32bd+gg03z21zDLirbew3LYx16Y/urWcoy/CloohTm9fT81kNk2IMx3ozJoiWE9DzAlQIi/IqljwvPZvqvTivse5Y+xK52i8J1RixtviECJ9qFaApKI6iZjNDvIpzfmMVfl5WnRhVCyTaBTGO2R18pzGR/qjcP3htWVnoii3OJAn1bgISNZcQmiTuHLQ0niyR8phakw9rOeH6gZSMp921i/Qh9cEL36QQ+m+/Zuzf3eMmQcdij9EDQJ6xG2TGMjaB+zRnKZBzA0tHQehgQzwpTRZj/Xbu3J+MJ8eYoPBQVYCX02405ba6S71AxpIrAANnCfGm3ESwzFlRZQ76KhvAeYgsVhcS1FQAJFTSwJqtNRcrIInkbwkQNULbEHduNJdZZva+wC2BnTy23zy432RSYalKr0KYlm2Ex9aj8+dBfWe0kiEoXPe+5KfsrcP0muz5HspedZuvzoj5ZkVJUcVNrk/6m/AVWzH1rWhj1IMTlQuNT76ywbA0qUl+4WvT8r/Fir0NUA0f/YGUU32Y13Oenha4hxxSPtRTK5UB/ZO+itHm4zE/aPqSq/1dYMeGF4qGaRFgz8BGOfeSnedWd+m4CnditkfgXPkeWpEy0NW+aIUb/ZD1dlw/law5aG8cpJ3iv8K6ZlLYvUZTDmFxikERcGnbFZe5R1aPdAcMqSx95SLgLNUT/22OAFFDVt+vRNpmge1ev+q2sZYmqI8TL/XnUIBTJkhu84eJN4qxBFmmhYdQ7sLTpmeuj3fENJ2pef5KTdu2oru/JRT5KgRFKIYp82bbCMG+cpm/OjfRq+t13NNnA3UwF7cO1bYXXqFBOmCzP1tknKL1X5xYLnHziSNj763ff9WttiwdhvAHVuRzl0e/HKuEb8ltpzBYeEtBT6n3p5KdUYTrD/K6IYME/uCav8jg0oY2jLFFSyf3oYz9AHxnj9I4IrlGdvSWIDcjmEOYBITaRgl+cJE+hA==,iv:USf8krJr661dSsUoa6lkY1jpaAx1NyNhsqE4CPOEG84=,tag:S3RN8GCzzNFghUCjSC7iRQ==,type:str]",
"sops": {
"kms": null,
"gcp_kms": null,
"azure_kv": null,
"hc_vault": null,
"age": [
{
"recipient": "age1ac27ksfvxydn20g29s09j66mag45vee3cgk5namsnup5e4l9v3sq7kypg7",
"enc": "-----BEGIN AGE ENCRYPTED FILE-----\nYWdlLWVuY3J5cHRpb24ub3JnL3YxCi0+IFgyNTUxOSBobUdZR084dUhqN3BSSFJH\nWnh2MEZSRHpaZVlpdVlHcnhBeUVxMnpOTUJNCmVMOHpoVmVwUFk4QVg4MXRyZlBo\nTzl1TlpWQ0RaY3o3UFplWmp4TTZEOFEKLS0tIDVVUFkzbUtDVnFlQlZ4SmVHNm5W\nMHJaNUxMUzFtV0VNWjhqdmlJMmZQc3cKaUCJoL1eYr3NFCWpZJrvlkB/4Sap/PWD\nvGj2KA4uq8yQH6IjbVKqivzJO4kv4e3hE1O1sIpv7TZbKRaiQLyi5w==\n-----END AGE ENCRYPTED FILE-----\n"
},
{
"recipient": "age19wm2y96tr02uz20yuqskvhwltygf47feenf7zuxqhegtqfu4le8q9adqdd",
"enc": "-----BEGIN AGE ENCRYPTED FILE-----\nYWdlLWVuY3J5cHRpb24ub3JnL3YxCi0+IFgyNTUxOSBBMFhranA3MVdVL0VvWi9B\nVDZUS3BjSnp6UWg2a2lWZndTSFRyTjhncnhVClV2aUNlZTdWVFFHa1VqTmdKL1Bu\nanM1SXAvRUdDMnlhMDgwMG42N2JCQUkKLS0tIHJoOUIyVlBKV3JPK1h1UUpSQUNp\nZVNETm5oUWtFZ1pTcld4TVY3cEhtV0kK3PiUq7FUOYnB+m/Hd5pmNZx2V8pxEhHE\nlslxOYOW+McZlAMlviZslYl0syDlU5ghcMiQ/vuYbMeHijlFJhxN+g==\n-----END AGE ENCRYPTED FILE-----\n"
}
],
"lastmodified": "2025-01-10T00:22:26Z",
"mac": "ENC[AES256_GCM,data:1RWXwQJAonV3/OzZVIshUIDjER3lbv7uolTg+2jASpbpNGfSfVC/V40DkLu6AFXK2yDSZbsd1x4PmXL1R6uOPvfYDqoYposCKgbOtVFoY+X4jWttoA62rbwLo6WSiMC3h2tbsc3UjDBIU4S9Kt/WntPKc7P5dh2fYDo3m3lYU70=,iv:9dCC9TGffKrR7BlfWP8idb8AaEb/OMeL4xrsOTvkWQA=,tag:XPoGwVi33x8PLaYqyYdYdA==,type:str]",
"pgp": null,
"unencrypted_suffix": "_unencrypted",
"version": "3.9.1"
}
}

View File

@ -1,24 +0,0 @@
{
"data": "ENC[AES256_GCM,data:M9gOTRJvjxukwifouVoXTIcZhl2jm9xgATC/Zyo3TATDQkdtcJlzOLA8BzvVmfwYooJBdbp7WQMaxHhRuTH7zEDPv0QPvyTPc1PKqdyMsfDd20Bi0ghPIRTlXRxFOZKKUrOtWNfVx4fAYey54GvZbg18JpdmAtKFtfQtmUko7Uy/S6Ko/bQSsOofhBuCCej6XYEVst7Ukr2V4yO8GyM5U7LAolEGGhGhPZi63B1yLcNXCMeI,iv:htvA4uWnmvwA6dJt2mFf3jDuazjK8NiXakhD23dWaZE=,tag:nAI314LRj0rOEXCvEJoJuw==,type:str]",
"sops": {
"kms": null,
"gcp_kms": null,
"azure_kv": null,
"hc_vault": null,
"age": [
{
"recipient": "age1ac27ksfvxydn20g29s09j66mag45vee3cgk5namsnup5e4l9v3sq7kypg7",
"enc": "-----BEGIN AGE ENCRYPTED FILE-----\nYWdlLWVuY3J5cHRpb24ub3JnL3YxCi0+IFgyNTUxOSArOGMraTZNb1h5QkJpQnFT\nRDArOXZYSmduUjZJQi9sSVdabmlmTUtaOWlZCi9EY3BheWtRbnk5b0dCMGZ3U0ly\neWhuWUNOL3Z4dkoyQ3E5WVNucitZaDQKLS0tIEJOY1ZWdDExWTBsQ2pDaWhaZFRw\nVEVhNm9ocVBPOXJQY3hxMGpJbFJ6L3cKP1Z+nMtXZgvpfG7u2dht/7yc+oquUNdl\nzSFsxhLNFuvt1EvZ4ybccSoniR1ziu5dPVpgmPO4sA84U8rc1L4Qmw==\n-----END AGE ENCRYPTED FILE-----\n"
},
{
"recipient": "age19wm2y96tr02uz20yuqskvhwltygf47feenf7zuxqhegtqfu4le8q9adqdd",
"enc": "-----BEGIN AGE ENCRYPTED FILE-----\nYWdlLWVuY3J5cHRpb24ub3JnL3YxCi0+IFgyNTUxOSBXY2Z3V2FuNmxRUGkreXRx\nVFY3eDRWOHlVb2h3eEIwNDlQV2hYLy9QREVJClhRTHJNUFNMTnhFUUxtME8xamZW\nVFdQSVpWZ1VFVlAxNmt6WFVTL1Jsd00KLS0tIFlOeEpmenc0dXQwTVJMZzFvZXVm\nbzVOWi9XMStJalR6b2o1d21tWERLTmsK4/XLQpk8wr3DX/D5g6IQfQdDtORBJBBx\nFdXkY7SjyebcUtZUY+qfAI3PAdbIlp9dCad05gTadQ0SDqQ4J+Xbwg==\n-----END AGE ENCRYPTED FILE-----\n"
}
],
"lastmodified": "2025-01-05T05:39:59Z",
"mac": "ENC[AES256_GCM,data:hXVntaa7Tq2A4y5wp9PicERTFjeDGDduxBd321FgRgvKO+9KG6jCzLGUX+dPRQtwM2A/DqRc74yxrorDyjpg5w4JVvfgFWBA+m2Jw6ZG5K/64/VLJgaV/c5dhmaBnyXfCly3441tZuwaocGNbYt2RSHI/izcN4f91iCeTzVFSA0=,iv:qFZ4wGPzQBmL/pZLqy/TDdKobbeqHf+vm6BPSLDsD9w=,tag:7K930Ym3/TbotLioWv4K5g==,type:str]",
"pgp": null,
"unencrypted_suffix": "_unencrypted",
"version": "3.9.0"
}
}

View File

@ -1,40 +0,0 @@
{
"data": "ENC[AES256_GCM,data:2wfDxlxAfwClaj05cKIUUW6hDhFhzcaJiPhxfGEYv/O2gAaqe2vkKhUiFU6ZivbMVx9xYFlgGvVPoBggZ9zjqzM5jcC9ggDtX2U11NAk6YEcEgrkviUTK0ddaIDsLIaSu+ih1TzYFpMvprH9jyLsR5aGxwykq21wKw61DamSfw9uJ6fzpEldNmTzzHPPUEfKmV/7NE9Tg4s0CzeQhh4GUdvF36JQfKHeDlqaW+L+u5C/HZld/EQ+71m/egwjb3+bh/iCUAO4iGXmmBnu/IM5tR0WSiR8CbwzZsoW9hE9d5Fwfbeu+kyH7Rdgd/VPXTeKyb2c47GeuEt8h7YK6PRvySorcDCCSHP5CbordQHZfsX+hWl47rb9I1dfpYgKHAU=,iv:wYyVXmb80A70Wch4dy/tu4faAjp/DTnwPGXQJxvi3/w=,tag:Gjdr7HkP3CA6em2KEpIKlA==,type:str]",
"sops": {
"kms": null,
"gcp_kms": null,
"azure_kv": null,
"hc_vault": null,
"age": [
{
"recipient": "age1ac27ksfvxydn20g29s09j66mag45vee3cgk5namsnup5e4l9v3sq7kypg7",
"enc": "-----BEGIN AGE ENCRYPTED FILE-----\nYWdlLWVuY3J5cHRpb24ub3JnL3YxCi0+IFgyNTUxOSBPbkFCVzhxTUFEUVRjelFy\nU01XV1JIS2s5Nnp2dFdEQVV5SUppelZiQVJ3ClNvNjNsQ1ZOV2w3K05kbEZnZU9l\nYjluWGFVay9qc2JSOWxMb21keCtjTHcKLS0tIGowMGk3b2hrZEdrQW1Mdmg4OU1R\nS25sRC9IS2diZDlQcXU3b2VzTzV2dW8KvPL8PE2oUJu+bU8BdbHt50H+Vijva1AG\nB84+9RgcgqLBpiv0QelQP6/zZjOvoZXMr8lmyrgD6ZZ36zGAjCAWzA==\n-----END AGE ENCRYPTED FILE-----\n"
},
{
"recipient": "age1nnx85asl5nmxmurr3g8mazcsggvtazt0hpauw42l7v4k3de74s6s649w0k",
"enc": "-----BEGIN AGE ENCRYPTED FILE-----\nYWdlLWVuY3J5cHRpb24ub3JnL3YxCi0+IFgyNTUxOSBJdTROeUd6Ym9JTlVRQlFY\nV3U5bXNxMlJhb2l5bFpNNnRzVVZMUFpkMDNBClAwNXIyTjF6eXlJc3ltT3FTMjEz\nRzNhYjFtZGJNR283eEJJQ2tuMVBMNWMKLS0tIFV4dzh3cW1vYU0rYk1BTDFuWWll\nVm5sRVFZVjJzaU5yOG02U1NBWjNGSVkKTTGhAFS+gDX9pULHLUvW2RKycfVoK0Pj\nku72ftVZsfMrd6mQkCQKXKQlAtopL/lF1VPYF+F6wgquK8W5RyU/zQ==\n-----END AGE ENCRYPTED FILE-----\n"
},
{
"recipient": "age19wm2y96tr02uz20yuqskvhwltygf47feenf7zuxqhegtqfu4le8q9adqdd",
"enc": "-----BEGIN AGE ENCRYPTED FILE-----\nYWdlLWVuY3J5cHRpb24ub3JnL3YxCi0+IFgyNTUxOSBIVnRCajZmZzBLaHpxRldO\nai9MdFRxaFIzRnZOVmVkYXR1ZmZib1RkNzJjCmp2RFhpcDFxcEdLWVNUM3pqL0tQ\ndVd5RnJmU1ZhUlh1Y2dvMWV2cXoybHMKLS0tIDBWajM5VWVsZzYzMThqZEZYMnlF\nQklXZldEbWxuNGl2a21CSnVvSTNFbm8KMR+7lah1KaBnt4nitDel5Tiyj9qy1pRp\nm3rkYXzFsy9frZyjG36flH7BLUwMaFvwE2bdBpmJgqKCSZlEMoxIiw==\n-----END AGE ENCRYPTED FILE-----\n"
},
{
"recipient": "age16vz5m0stsh39ajn3zhkzj7x7zfgexlx3zzk2k9vrrrsn78tyzd2qmjkt2a",
"enc": "-----BEGIN AGE ENCRYPTED FILE-----\nYWdlLWVuY3J5cHRpb24ub3JnL3YxCi0+IFgyNTUxOSBmUkN5cnhyT2lkNS94V1h6\ndGRkbTd6L1Y3VEc0VU50cVhYWUVUWjNNSkZ3CndsUXR5SnJ3VnpucWNEQTEwekZC\nZTVHZ04wZ01VNTJmMWM5MVRoWXIwa3MKLS0tIGp5TEhnTjMyV2haclUrdW43MktM\nNzFlekg3eFc3SkkwaHBmWHVKUERtaWMK5FwD0OE4Zo3qrgMGDkWZYO7ZIGCdRGcx\nOj5kkW/wHS/+UJtmnJVYJZYpodOCSsRXhXNvLOA3YkvqSgFc9mCa4A==\n-----END AGE ENCRYPTED FILE-----\n"
},
{
"recipient": "age1j8wprrs23m46h7xl26su3k6uztnvza5k89c9uk9rwwzefv8a4yvqpscxun",
"enc": "-----BEGIN AGE ENCRYPTED FILE-----\nYWdlLWVuY3J5cHRpb24ub3JnL3YxCi0+IFgyNTUxOSBvcjNldG5QWUhlU08zOGVo\nT2kvQnNMam1iSmtPVUtDamVzUFJmb25neEJZCmhWWEwydUhFbk9LRXEwQjI0LzRM\nWkNiaVR0WldyS0NVSVh2ckI2RW1nM0UKLS0tIG5aYVZaN1ZVbzczT3Y1dDR0UWFN\nQlNYdE1hZGczTk5IamhpMzhlb2FVTEEKtS4EyNv4nhzIobMf1mqZUuUDWulk8vK1\n4kEHwS5tfV3ZbDF15fRoSnnk9nO8SANntB5ftfG+d3XgP2QWBTS5tg==\n-----END AGE ENCRYPTED FILE-----\n"
},
{
"recipient": "age1jerjsfhnenzzqtnuxez8g79kc0xxulxyhu2evp9p6gjyswu2syqskgt62v",
"enc": "-----BEGIN AGE ENCRYPTED FILE-----\nYWdlLWVuY3J5cHRpb24ub3JnL3YxCi0+IFgyNTUxOSBBWGhoUHJaWWtPZTZlY2pw\nZHg2S1ZlaU4wdVRKajVJL3VOblFXMFlCdHh3ClRJeWVYNUhVYWl6QXdpNlRBb2sz\nc2VrSkZSSGxtZTJ2bDNrZTdCOFUzcDQKLS0tIFdmUk9Ia3ptVkZlc0IzZ1Mrc2lN\nSUZMZXdkVXVobWhFaU1XWHNha0w5UmMK/86m63U4w4+/EM6u5eWhI71iFEEosdUS\nwGVSi1WXgx6YWF22TK9TuhaH5YfyUjOHH2ZtfT57cDk739sMdYnqhw==\n-----END AGE ENCRYPTED FILE-----\n"
}
],
"lastmodified": "2023-11-20T12:29:43Z",
"mac": "ENC[AES256_GCM,data:HgDwUqtV3qljKSq4Jds+57NX6unOmE7wuyDJoNkSzecNNSygXzM8qyRJwwFVfZUUpNLovNaorlHfCiDAK5y3DsbsIDabCSbI0Ch8nR8JxAFhJdKz7EzIY7mOORLPsPPb9wQ3gAC6TW1qYxEzUUrs4gUPGknQAZTlglriDC3ljtU=,iv:BpBV7/OE4v0pwYUAlrKIYDtB8jz2krnMSvd3TE299FI=,tag:NQaHzZUi6uh0l0bcqhyowg==,type:str]",
"pgp": null,
"unencrypted_suffix": "_unencrypted",
"version": "3.8.1"
}
}

View File

@ -1,6 +0,0 @@
{
services.deluge = {
enable = true;
web.enable = true;
};
}

View File

@ -1,8 +0,0 @@
{inputs, ...}: {
imports = [
inputs.raspberry-pi-nix.nixosModules.raspberry-pi
];
nixpkgs.overlays = [
inputs.raspberry-pi-nix.overlays.core
];
}

View File

@ -1,57 +0,0 @@
{lib, config, ...}: with lib; {
services.dashy = mkIf config.services.dashy.enable {
virtualHost = {
enableNginx = true;
domain = "dashy.odie.home.arpa";
};
settings = {
pageInfo = {
title = "Dashy";
};
appConfig = {
theme = "Material-Dark";
faviconApi = ["local"];
preventWriteToDisk = true;
};
sections = [
{
name = "System Info";
icon = "fas fas-rocket";
widgets = [
{ type ="system-info"; }
];
}
{
name = "Media";
icon = "fa fa-headphones";
items = [
{
title = "Mediaplayer";
description = "Jellyfin";
icon = "favicon";
url = "https://jellyfin.odie.home.arpa";
}
{
title = "Filme";
description = "Radarr";
icon = "favicon";
url = "https://radarr.odie.home.arpa";
}
{
title = "Serien";
description = "Sonarr";
icon = "favicon";
url = "https://sonarr.odie.home.arpa";
}
{
title = "Indexer";
description = "Prowlarr";
icon = "favicon";
url = "https://prowlarr.odie.home.arpa";
}
];
}
];
};
};
}

View File

@ -1,10 +1,6 @@
{
imports = [
./nginx
./searx
./open-webui
./postgresql
./dashy
#./binary-cache
];
}

View File

@ -1,17 +0,0 @@
{ config
, lib
, ...
}:
with lib;
mkIf config.services.open-webui.enable {
services.open-webui = {
host = "0.0.0.0";
port = 8080;
environment = {
USER_AGENT = "Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:131.0) Gecko/20100101 Firefox/131.0";
};
};
networking.firewall.allowedTCPPorts = [ config.services.open-webui.port ];
}

View File

@ -1,10 +0,0 @@
{ config
, lib
, ...
}:
with lib;
mkIf config.services.postgresql.enable {
services.postgresql = {
};
#networking.firewall.allowedTCPPorts = [ config.services.searx.settings.server.port ];
}

View File

@ -1,39 +0,0 @@
{ config
, lib
, ...
}:
with lib;
mkIf config.services.searx.enable {
services.searx = {
settings = {
server = {
port = 8000;
bind_address = "0.0.0.0";
secret_key = "sow4ruu4phaij7aich3wohshaec0iShieyieM3Shooch0Quaileeyu5edienaifa";
limiter = false;
};
ui = {
use_static_hash = true;
};
enabled_plugins = [
"Hash plugin"
"Self Informations"
"Tracker URL remover"
"Ahmia blacklist"
];
search = {
safe_search = 0;
default_lang = "";
formats = [ "html" "json" ];
autocomplete = "duckduckgo";
};
};
limiterSettings = {
botdetection.ip_limit.link_token = false;
};
};
networking.firewall.allowedTCPPorts = [ config.services.searx.settings.server.port ];
}

View File

@ -1,21 +0,0 @@
{ inputs, ... }: {
imports = [ inputs.sops-nix.nixosModules.sops ];
# This will add secrets.yml to the nix store
# You can avoid this by adding a string to the full path instead, i.e.
# sops.defaultSopsFile = "/root/.sops/secrets/example.yaml";
sops = {
defaultSopsFile = ../../../secrets/general.yaml;
# This will automatically import SSH keys as age keys
age = {
sshKeyPaths = [ "/etc/ssh/ssh_host_ed25519_key" ];
# This is using an age key that is expected to already be in the filesystem
keyFile = "/var/lib/sops-nix/key.txt";
# This will generate a new key if the key specified above does not exist
generateKey = true;
};
# This is the actual specification of the secrets.
secrets = {
hello = { };
};
};
}

View File

@ -12,9 +12,7 @@ in
defaultUser = username;
nativeSystemd = true;
useWindowsDriver = true;
wslConf = {
network.hostname = hostName;
};
wslConf = { network.hostname = hostName; };
};
};
}

View File

@ -1,6 +1,7 @@
{
imports = [
./yank_highlight.nix
#./remember_cursor_position.nix
./set_conceal_level.nix
./filetype_options.nix
];

View File

@ -4,12 +4,7 @@ let
pattern,
indentSize ? 4,
expandTab ? true,
spell ? false,
}: let
spell =
if expandTab
then "true"
else "false";
expandtab =
if expandTab
then "true"
@ -24,7 +19,6 @@ let
setlocal.expandtab = ${expandtab}
setlocal.shiftwidth = ${builtins.toString indentSize}
setlocal.tabstop = ${builtins.toString indentSize}
setlocal.spell = ${spell}
end
'';
};
@ -45,9 +39,5 @@ in {
expandTab = false;
indentSize = 4;
})
(mkFileTypeOptions {
pattern = ["*.norg"];
spell = true;
})
];
}

View File

@ -0,0 +1,35 @@
let
group = "RememberCursorPosition";
in {
autoGroups = {
${group} = {
clear = true;
};
};
autoCmd = [
{
inherit group;
event = "BufRead";
callback = {
__raw = ''
function(opts)
buffer = opts.buf,
vim.api.nvim_create_autocmd("BufWinEnter", {
callback = function()
local ft = vim.bo[opts.buf].filetype
local last_known_line = vim.api.nvim_buf_get_mark(opts.buf, '"')[1]
if
not (ft:match("commit") and ft:match("rebase"))
and last_known_line > 1
and last_known_line <= vim.api.nvim_buf_line_count(opts.buf)
then
vim.api.nvim_feedkeys([[g`"]], "nx", false)
end
end,
})
end
'';
};
}
];
}

View File

@ -1,14 +1,14 @@
let
yankHighlightGroup = "YankHightlight";
group = "YankHightlight";
in {
autoGroups = {
${yankHighlightGroup} = {
${group} = {
clear = true;
};
};
autoCmd = [
{
group = yankHighlightGroup;
inherit group;
event = "TextYankPost";
pattern = "*";
callback = {

View File

@ -1,4 +1,4 @@
{ inputs, pkgs, ... }: {
_: {
imports = [
./colorscheme.nix
./options.nix
@ -7,77 +7,8 @@
./plugins
];
config = {
viAlias = true;
vimAlias = true;
performance = {
byteCompileLua = {
enable = true;
configs = true;
initLua = true;
nvimRuntime = true;
plugins = true;
};
combinePlugins = {
enable = false;
standalonePlugins = [
"nvim-treesitter"
];
};
};
#package = inputs.neovim-nightly-overlay.packages.${pkgs.system}.neovim;
extraPackages = with pkgs; [
fd
ripgrep
iferr
fswatch
reftools
libxcrypt
xz
icu74
nixpkgs-fmt
python3Packages.six
asm-lsp
];
extraPlugins = with pkgs.vimPlugins; [
{
plugin = go-nvim;
config = ''lua require("go").setup()'';
}
{
plugin = nvim-dap-go;
config = ''lua require("dap-go").setup()'';
}
{
plugin = telescope-dap-nvim;
config = ''lua require("telescope").load_extension("dap")'';
}
{
plugin = neorg-telescope;
}
/*
{
plugin = pkgs.vimUtils.buildVimPlugin {
name = "guihua";
src = inputs.guihua;
};
}
*/
{
plugin = pkgs.vimUtils.buildVimPlugin {
name = "luavit-meta";
src = inputs.luavit-meta;
};
}
{
plugin = pkgs.vimUtils.buildVimPlugin {
name = "lazydev.nvim";
src = inputs.lazydev;
};
config = ''lua require('lazydev').setup({library = {"luvit-meta/library"}})'';
}
];
};
}

View File

@ -1,5 +1,19 @@
_: {
keymaps = [
{
key = "<leader>e";
action = "<cmd>Neotree toggle<CR>";
options = {
silent = true;
};
}
{
key = "<leader>ff";
action = "<cmd>Telescope find_files<CR>";
options = {
silent = true;
};
}
{
key = "<Space>";
action = "<Nop>";
@ -39,22 +53,6 @@ _: {
expr = true;
};
}
{
key = "<M-h>";
action = ":vertical resize -1<CR>";
}
{
key = "<M-l>";
action = ":vertical resize +1<CR>";
}
{
key = "<M-j>";
action = ":resize +1<CR>";
}
{
key = "<M-k>";
action = ":resize -1<CR>";
}
{
key = "<M-K>";
action = ":m -2<CR>";

View File

@ -1,10 +1,10 @@
{ lib
, ...
}:
let
indentSize = 4;
in
{
pkgs,
lib,
...
}: let
indentSize = 4;
in {
options = {
programs.nixvim.ai = {
enable = lib.mkEnableOption "AI functions";
@ -50,6 +50,7 @@ in
mousemoveevent = true;
timeoutlen = 300;
list = true;
spell = true;
spelllang = ["de" "en_us"];
helplang = "de";
laststatus = 3;
@ -58,7 +59,39 @@ in
signcolumn = "yes";
foldlevel = 999;
};
extraPackages = with pkgs; [
fd
ripgrep
iferr
fswatch
reftools
golines
richgo
gofumpt
govulncheck
mockgen
ginkgo
gotestsum
libxcrypt
xz
icu74
alejandra
vscode-extensions.ms-vscode.cpptools
];
extraPlugins = with pkgs.vimPlugins; [
{
plugin = go-nvim;
config = ''lua require("go").setup()'';
}
{
plugin = nvim-dap-go;
config = ''lua require("dap-go").setup()'';
}
{
plugin = telescope-dap-nvim;
config = ''lua require("telescope").load_extension("dap")'';
}
];
extraConfigLua = ''
vim.opt.undodir = vim.fn.stdpath("state") .. "/undo"
vim.opt.backupdir = vim.fn.stdpath("state") .. "/backup"
@ -92,9 +125,6 @@ in
'';
extraConfigLuaPre = ''
vim.opt.runtimepath:prepend(',~/.config/nvim')
vim.opt.runtimepath:append(',~/.config/nvim/after')
local colors = require("catppuccin.palettes").get_palette("mocha")
local pickers = require("telescope.pickers")
local finders = require("telescope.finders")
@ -102,6 +132,12 @@ in
local actions = require("telescope.actions")
local action_state = require("telescope.actions.state")
local pickers = require("telescope.pickers")
local finders = require("telescope.finders")
local conf = require("telescope.config").values
local actions = require("telescope.actions")
local action_state = require("telescope.actions.state")
function get_program()
return coroutine.create(function(coro)
local opts = {}
@ -157,10 +193,6 @@ in
dap.listeners.before.event_exited.dapui_config = function()
dapui.close()
end
require('dap.ext.vscode').load_launchjs()
require('lspconfig').asm_lsp.setup({})
'';
};
}

View File

@ -1,39 +0,0 @@
{ lib, ... }: {
plugins.avante = {
enable = true;
settings = {
provider = "ollama";
vendors = {
ollama = {
endpoint = "http://10.0.20.10:11434/v1";
model = "gemma2:2b";
temperature = 0;
max_tokens = 4096;
api_key_name = "";
parse_curl_args = lib.nixvim.mkRaw ''
function(opts, code_opts)
return {
url = opts.endpoint .. "/chat/completions",
headers = {
["Accept"] = "application/json",
["Content-Type"] = "application/json",
},
body = {
model = opts.model,
messages = require("avante.providers").copilot.parse_message(code_opts), -- you can make your own message, but this is very advanced
max_tokens = 2048,
stream = true,
},
}
end
'';
parse_response_data = lib.nixvim.mkRaw ''
function(data_stream, event_state, opts)
require("avante.providers").openai.parse_response(data_stream, event_state, opts)
end
'';
};
};
};
};
}

View File

@ -6,5 +6,7 @@
cfg = config.programs.nixvim.ai;
in
lib.mkIf cfg.enable {
plugins.codeium-nvim.enable = false;
plugins.codeium-nvim = {
enable = true;
};
}

View File

@ -1,8 +1,4 @@
{ pkgs, ... }:
let
debuggers = { c = "lldb"; };
in
{
{pkgs, ...}: {
plugins.dap = {
enable = true;
extensions = {
@ -13,18 +9,15 @@ in
};
adapters = {
executables = {
gdb = {
id = "gdb";
command = "${pkgs.gdb}/bin/gdb";
args = [ "--interpreter=dap" "--quiet" "--eval-command" "set pretty print on" ];
};
cppdbg = {
id = "cppdbg";
command = "${pkgs.vscode-extensions.ms-vscode.cpptools}/share/vscode/extensions/ms-vscode.cpptools/debugAdapters/bin/OpenDebugAD7";
};
lldb = {
id = "lldb";
command = "${pkgs.llvmPackages.lldb}/bin/lldb-dap";
command = "${pkgs.llvmPackages.lldb}/bin/lldb-vscode";
};
};
servers.codelldb = rec {
port = 13000;
executable = {
command = "${pkgs.vscode-extensions.vadimcn.vscode-lldb}/share/vscode/extensions/vadimcn.vscode-lldb/adapter/codelldb";
args = ["--port" (builtins.toString port)];
};
};
};
@ -35,10 +28,10 @@ in
{
name = "Launch";
request = "launch";
type = debuggers.c;
type = "codelldb";
cwd = "\${workspaceFolder}";
stopOnEntry = true;
runInTerminal = true;
stopOnEntry = false;
runInTerminal = false;
program = {
__raw = ''
get_program
@ -48,10 +41,10 @@ in
{
name = "Launch with Arguments";
request = "launch";
type = debuggers.c;
type = "codelldb";
cwd = "\${workspaceFolder}";
stopOnEntry = true;
runInTerminal = true;
stopOnEntry = false;
runInTerminal = false;
program = {
__raw = ''
get_program
@ -75,7 +68,6 @@ in
key = "<leader>db";
options = {
silent = true;
desc = "[dap] Toggle Breakpoint";
};
}
{
@ -83,7 +75,6 @@ in
key = "<leader>du";
options = {
silent = true;
desc = "[dap] Toggle UI";
};
}
{
@ -91,7 +82,6 @@ in
key = "<leader>dc";
options = {
silent = true;
desc = "[dap] Continue / Run Debug";
};
}
{
@ -99,7 +89,6 @@ in
key = "<leader>dC";
options = {
silent = true;
desc = "[dap] Rerun Last";
};
}
{
@ -107,7 +96,6 @@ in
key = "<leader>do";
options = {
silent = true;
desc = "[dap] Step over";
};
}
{
@ -115,7 +103,6 @@ in
key = "<leader>di";
options = {
silent = true;
desc = "[dap] Step in";
};
}
{
@ -123,7 +110,6 @@ in
key = "<leader>dO";
options = {
silent = true;
desc = "[dap] Step out";
};
}
{
@ -131,7 +117,6 @@ in
key = "<leader>dT";
options = {
silent = true;
desc = "[dap] Terminate Process";
};
}
{
@ -139,7 +124,6 @@ in
key = "<leader>dr";
options = {
silent = true;
desc = "[dap] Toggle REPL";
};
}
];

View File

@ -1,52 +1,26 @@
{ inputs, pkgs, ... }: {
{
imports = [
./cmp.nix
./codeium.nix
./dap.nix
./gitsigns.nix
./harpoon.nix
./indent-blankline.nix
./lsp
./lualine.nix
./mini.nix
./neo-tree.nix
./neorg.nix
./noice.nix
./none-ls.nix
./rainbow-delimiters.nix
./telescope.nix
./treesitter.nix
./trouble.nix
./vim-tmux-navigator.nix
./which-key.nix
./mini.nix
./todo-comments.nix
./neorg.nix
./fugitive.nix
./dap.nix
./lastplace.nix
./codeium.nix
./undotree.nix
./notify.nix
./avante.nix
./render-markdown.nix
];
plugins = {
fugitive.enable = true;
gitsigns.enable = true;
lastplace.enable = true;
tmux-navigator.enable = true;
todo-comments.enable = true;
transparent.enable = true;
which-key.enable = true;
zen-mode.enable = true;
web-devicons.enable = true;
lazygit.enable = true;
colorizer.enable = true;
headlines.enable = true;
cmake-tools = {
enable = true;
settings = {
cmake_build_directory = "build/\${variant:buildtype}";
};
};
};
extraPlugins = with pkgs.vimPlugins;
[
vim-nftables
(pkgs.vimUtils.buildVimPlugin {name= "mcfunction"; src = inputs.vim-mcfunction; })
./lsp
];
}

View File

@ -0,0 +1,3 @@
{
plugins.fugitive.enable = true;
}

View File

@ -0,0 +1,3 @@
{
plugins.gitsigns.enable = true;
}

Some files were not shown because too many files have changed in this diff Show More