From 6d7026d08b552e24a96abbf7a05a32638bcb803a Mon Sep 17 00:00:00 2001 From: Andre Date: Fri, 25 Oct 2024 19:53:50 -0400 Subject: [PATCH] chore: cleanup old and/or unused stuff --- hosts/Hevana/default.nix | 5 -- modules/common.nix | 6 -- modules/secrets/default.nix | Bin 4970 -> 4905 bytes modules/services/airsonic.nix | 71 ------------------------ modules/services/home-assistant.nix | 83 ---------------------------- modules/users/aires/default.nix | 6 +- modules/users/root/default.nix | 18 ++---- packages/airsonic-advanced.nix | 33 ----------- 8 files changed, 9 insertions(+), 213 deletions(-) delete mode 100644 modules/services/airsonic.nix delete mode 100644 modules/services/home-assistant.nix delete mode 100644 packages/airsonic-advanced.nix diff --git a/hosts/Hevana/default.nix b/hosts/Hevana/default.nix index 2a0a7f0..2f828d1 100644 --- a/hosts/Hevana/default.nix +++ b/hosts/Hevana/default.nix @@ -112,11 +112,6 @@ in home = "${services-root}/forgejo"; url = config.secrets.services.forgejo.url; }; - home-assistant = { - enable = false; - home = "${services-root}/home-assistant"; - url = config.secrets.services.home-assistant.url; - }; jellyfin = { enable = true; home = "${services-root}/jellyfin"; diff --git a/modules/common.nix b/modules/common.nix index 854a2d7..b8e498b 100644 --- a/modules/common.nix +++ b/modules/common.nix @@ -48,12 +48,6 @@ # Install ZSH for all users zsh.enable = true; - # Enable NH, an alternative nixos-rebuild frontend. - # https://github.com/viperML/nh - nh = { - enable = true; - flake = "${config.secrets.nixConfigFolder}"; - }; # Configure nano nano.nanorc = '' set tabsize 4 diff --git a/modules/secrets/default.nix b/modules/secrets/default.nix index 6eb92bfa03e9a256dd49f39a32a37ec2bdc549a9..1246e2aef1d4981611b2c781a397cf4fbf7c9cff 100644 GIT binary patch literal 4905 zcmV+^6V~hiM@dveQdv+`02v&?;#1UN{;Y!dHs5Ht1(}69jlj^n#~Dj@X_MryViQ}q zqChvB5+(j$gY`c1wEuf`reLoAS%>tO5xGwga){$QGdfBeC|gVLz+uM)!nc!MUQS-B z#WcjA3mBpX{V+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qeh^#U}rz zn^%*bmH8UU64F{nfHN5NrN!l~6!ve=e0TkAWR!T| z+>%})FD!USkg~6llF7~QtUJax<8_{IHCs2V%jrWrGm94#p1lqM{!X>5+K6cn232pH z)5@3B^0Kr|dJGikj7}=E7_@LSBY_J1bY(5HeD`Glc{P)i!ls6yFW&>AX-%}@R7vY! z{9B654#(l89su-3B;znJ)X-)nvXPjc{EL660lBaVWh1T>)&YaQhkxrGvAM%VHGvyc`!y_1*YstR$qJWdjo=pb-AY0 zms%TNCFmzoG!zKmMcWoo|1>jsZ|ol3CJjaE_f0w(tQSS9o@JBG6#&Y2Y}8l z;bjI5jEijm&w5fFywSVr17y6dHhsRr`_9mOvzhXR*d01j(0P2!=gqOPzd0{Mbv|Av ovTVQQeO6Ds`V9CN_tlh4t0GpgOXNr_>7YaK%vSZ}jJGo>v&ibA2LJ#7 diff --git a/modules/services/airsonic.nix b/modules/services/airsonic.nix deleted file mode 100644 index 31af51f..0000000 --- a/modules/services/airsonic.nix +++ /dev/null @@ -1,71 +0,0 @@ -{ - pkgs, - config, - lib, - ... -}: -let - cfg = config.aux.system.services.airsonic; -in -{ - options = { - aux.system.services.airsonic = { - enable = lib.mkEnableOption "Enables Airsonic Advanced media streaming service."; - home = lib.mkOption { - default = "/var/lib/airsonic"; - type = lib.types.str; - description = "Where to store Airsonic's files"; - }; - url = lib.mkOption { - default = ""; - type = lib.types.str; - description = "The complete URL where Airsonic is hosted."; - example = "https://forgejo.example.com"; - }; - }; - }; - - config = lib.mkIf cfg.enable { - aux.system.users.media.enable = true; - users.users.airsonic.extraGroups = [ "media" ]; - - services = { - nginx.virtualHosts."${cfg.url}" = { - useACMEHost = pkgs.util.getDomainFromURL cfg.url; - forceSSL = true; - locations."/" = { - proxyPass = "http://127.0.0.1:4040"; - proxyWebsockets = true; - extraConfig = '' - # Taken from https://airsonic.github.io/docs/proxy/nginx/ - proxy_set_header X-Real-IP $remote_addr; - proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; - proxy_set_header X-Forwarded-Proto https; - proxy_set_header X-Forwarded-Host $host; - proxy_set_header Host $host; - proxy_max_temp_file_size 0; - proxy_ssl_server_name on; - ''; - }; - }; - - airsonic = { - enable = true; - war = "${ - (pkgs.callPackage ../../packages/airsonic-advanced.nix { inherit lib; }) - }/webapps/airsonic.war"; - port = 4040; - jre = pkgs.jdk17; - jvmOptions = [ - "-Dserver.use-forward-headers=true" - "-Xmx4G" # Increase Java heap size to 4GB - ]; - } // lib.optionalAttrs (cfg.home != "") { home = cfg.home; }; - }; - - systemd.services = { - airsonic.unitConfig.RequiresMountsFor = cfg.home; - nginx.wants = [ config.systemd.services.airsonic.name ]; - }; - }; -} diff --git a/modules/services/home-assistant.nix b/modules/services/home-assistant.nix deleted file mode 100644 index 03cd5e8..0000000 --- a/modules/services/home-assistant.nix +++ /dev/null @@ -1,83 +0,0 @@ -{ - config, - lib, - pkgs, - ... -}: - -let - cfg = config.aux.system.services.home-assistant; -in -{ - options = { - aux.system.services.home-assistant = { - enable = lib.mkEnableOption "Enables Home Assistant."; - home = lib.mkOption { - default = "/etc/home-assistant"; - type = lib.types.str; - description = "Where to store Home Assistant's files"; - example = "/home/home-assistant"; - }; - url = lib.mkOption { - default = ""; - type = lib.types.str; - description = "The complete URL where Home Assistant is hosted."; - example = "https://home-assistant.example.com"; - }; - }; - - }; - - config = lib.mkIf cfg.enable { - services = { - home-assistant = { - enable = true; - # opt-out from declarative configuration management - lovelaceConfig = null; - # configure the path to your config directory - configDir = cfg.home; - # specify list of components required by your configuration - extraComponents = [ - "default_config" - "esphome" - "eufy" - "govee_light_local" - "met" - "radio_browser" - "tplink" - ]; - extraPackages = python3Packages: with python3Packages; [ numpy ]; - config.http = { - server_host = "::1"; - trusted_proxies = [ "::1" ]; - use_x_forwarded_for = true; - }; - }; - nginx.virtualHosts."${cfg.url}" = { - useACMEHost = pkgs.util.getDomainFromURL cfg.url; - forceSSL = true; - locations."/" = { - proxyPass = "http://[::1]:8123"; - proxyWebsockets = true; - extraConfig = '' - # Security / XSS Mitigation Headers - add_header X-Frame-Options "SAMEORIGIN"; - add_header X-Content-Type-Options "nosniff"; - - proxy_ssl_server_name on; - proxy_set_header Host $host; - proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; - proxy_set_header X-Real-IP $remote_addr; - - proxy_buffering off; - ''; - }; - }; - }; - - systemd.services = { - home-assistant.unitConfig.RequiresMountsFor = cfg.home; - nginx.wants = [ config.systemd.services.home-assistant.name ]; - }; - }; -} diff --git a/modules/users/aires/default.nix b/modules/users/aires/default.nix index 8cecc94..10013d6 100644 --- a/modules/users/aires/default.nix +++ b/modules/users/aires/default.nix @@ -76,8 +76,12 @@ in userName = config.secrets.users.aires.firstName; userEmail = config.secrets.users.aires.email; extraConfig = { - safe.directory = "${config.secrets.nixConfigFolder}/.git"; + core.editor = config.aux.system.editor; + merge.conflictStyle = "zdiff3"; + pull.ff = "only"; push.autoSetupRemote = "true"; + safe.directory = "${config.secrets.nixConfigFolder}/.git"; + submodule.recurse = true; }; }; diff --git a/modules/users/root/default.nix b/modules/users/root/default.nix index a8c6062..cfc3fc6 100644 --- a/modules/users/root/default.nix +++ b/modules/users/root/default.nix @@ -1,20 +1,10 @@ -{ config, lib, ... }: +{ ... }: { - # Give root user access to run remote builds home-manager.users.root = { home.stateVersion = "24.05"; - programs = { - git.extraConfig = { - safe.directory = "${config.secrets.nixConfigFolder}/.git"; - }; - ssh = { - enable = true; - matchBlocks = config.secrets.users.root.sshConfig; - }; - zsh = { - oh-my-zsh.theme = "kardan"; - shellAliases.nos = "nixos-operations-script"; - }; + programs.zsh = { + oh-my-zsh.theme = "kardan"; + shellAliases.nos = "nixos-operations-script"; }; }; } diff --git a/packages/airsonic-advanced.nix b/packages/airsonic-advanced.nix deleted file mode 100644 index 3208420..0000000 --- a/packages/airsonic-advanced.nix +++ /dev/null @@ -1,33 +0,0 @@ -{ - lib, - stdenv, - fetchurl, - nixosTests, -}: - -stdenv.mkDerivation rec { - pname = "airsonic-advanced"; - version = "11.1.4-SNAPSHOT.20240628143437"; - - src = fetchurl { - url = "https://github.com/kagemomiji/airsonic-advanced/releases/download/${version}/airsonic.war"; - sha256 = "fde2c921e26cf536405118c5114a2f42fe87ff0a019852f21c80f4c68a2431ee"; - }; - - buildCommand = '' - mkdir -p "$out/webapps" - cp "$src" "$out/webapps/airsonic.war" - ''; - - passthru.tests = { - airsonic-starts = nixosTests.airsonic; - }; - - meta = { - description = "Free, web-based media streamer providing ubiquitous access to your music."; - homepage = "https://github.com/kagemomiji/airsonic-advanced/"; - sourceProvenance = [ lib.sourceTypes.binaryBytecode ]; - license = lib.licenses.gpl3; - platforms = lib.platforms.all; - }; -}