diff --git a/flake.lock b/flake.lock index 4dcd453..c3127f8 100644 --- a/flake.lock +++ b/flake.lock @@ -340,11 +340,11 @@ "utils": "utils_2" }, "locked": { - "lastModified": 1667234164, - "narHash": "sha256-oPMAvHZBDgamjmIQly5+sw2LtfKwY7qcWZZwKiwKQy8=", + "lastModified": 1667468181, + "narHash": "sha256-806/nrDW6e7bl4/oJEdAykYz/NaBuTUi7EUYArw2oic=", "owner": "nix-community", "repo": "home-manager", - "rev": "722e8d65d3aba6f527100cc2d1539e4ca04d066f", + "rev": "93335810751f0404fe424e61ad58bc8e94bf8e9d", "type": "github" }, "original": { @@ -359,11 +359,11 @@ "wlroots": "wlroots" }, "locked": { - "lastModified": 1667219167, - "narHash": "sha256-8vZFiueGvZWAgrhwNuGmi/GigH/6p75yFPB96AIAcVk=", + "lastModified": 1667516144, + "narHash": "sha256-vqHM8wATrBEk0L/57SSFU379sFbRwqwjMQBx+ef21bw=", "owner": "hyprwm", "repo": "Hyprland", - "rev": "a69fd21a1ac90c24cee659595d62329f8638d632", + "rev": "349afa0e7a5a8f60404772ae76ab0dc6fe4117ff", "type": "github" }, "original": { @@ -379,11 +379,11 @@ ] }, "locked": { - "lastModified": 1666860539, - "narHash": "sha256-JXP8hoDNusWhPldEQx8dmDy9VATYA1c9E5OgFHdFz+c=", + "lastModified": 1667425292, + "narHash": "sha256-Cu4VWp0DLj7AS+CQYtBugxPA4r7NoX0u+BEo3GW6Sl4=", "owner": "hyprwm", "repo": "hyprpaper", - "rev": "6fa4ea8a68bf8e3efeac3d204f314ab9b5c83777", + "rev": "1f55dda5e2af30648d7d58dbb49dd5dfbef7bcf3", "type": "github" }, "original": { @@ -454,11 +454,11 @@ "utils": "utils_4" }, "locked": { - "lastModified": 1666748742, - "narHash": "sha256-iXbopYzGsVJBufHT5SSoxpoY4AjvpqQKVrLvR72kmwc=", + "lastModified": 1667467369, + "narHash": "sha256-XIiVnu/tkHiVebwTTboq033oTUZnh1tuaf/vE56YFck=", "owner": "jyooru", "repo": "nix-minecraft-servers", - "rev": "3a42ffbe4d9a8a82e754a15c14c8fd52f59258bf", + "rev": "66b523b571ced590d33cac81af2731db1ab114c7", "type": "github" }, "original": { @@ -623,11 +623,11 @@ }, "nixpkgs_2": { "locked": { - "lastModified": 1667235697, - "narHash": "sha256-1sEHtwyGAHLi/Tt1OTDHxR76TmUd8bRLO+rF5k52Xlo=", + "lastModified": 1667550944, + "narHash": "sha256-ggII6sCaxlD06V9PBE+9fit6zLFsYzQtEsU7wugNYP0=", "owner": "NULLx76", "repo": "nixpkgs", - "rev": "346eb80aa5f4d9c33c09d9acbb7895de338c81a8", + "rev": "a5cafcd286c4fddd81aebbb9edb6befaf0e1afbe", "type": "github" }, "original": { diff --git a/flake.nix b/flake.nix index e155dd8..0ec2655 100644 --- a/flake.nix +++ b/flake.nix @@ -110,7 +110,7 @@ proxmox-lxc = nixos-generators.nixosGenerate { inherit system pkgs; format = "proxmox-lxc"; - modules = [ (import ./nixos/lxc-template.nix) ]; + modules = [ (import ./nixos/proxmox-lxc.nix) ]; }; }; diff --git a/nixos/hosts/hades/default.nix b/nixos/hosts/hades/default.nix index 94aca70..a235c00 100644 --- a/nixos/hosts/hades/default.nix +++ b/nixos/hosts/hades/default.nix @@ -34,6 +34,11 @@ mac = "7A:14:15:ED:D1:E6"; tags = [ "vault" ]; } + { + hostname = "pmm"; + ip = "192.168.0.104"; + mac = "7A:A3:59:1D:69:07"; + } { hostname = "MariaDB"; ip = "192.168.0.109"; diff --git a/nixos/hosts/hades/pmm/config/Anime.yml b/nixos/hosts/hades/pmm/config/Anime.yml new file mode 100644 index 0000000..e69de29 diff --git a/nixos/hosts/hades/pmm/config/Movies.yml b/nixos/hosts/hades/pmm/config/Movies.yml new file mode 100644 index 0000000..4133de0 --- /dev/null +++ b/nixos/hosts/hades/pmm/config/Movies.yml @@ -0,0 +1,32 @@ +templates: + Actor: + actor: tmdb + tmdb_person: <> + tmdb_actor_details: <> + sort_title: +_<> + sync_mode: sync + collection_order: release + collection_mode: hide + Set: + optional: + - collection + - movie + - list + tmdb_collection_details: <> + tmdb_movie: <> + tmdb_list: <> + sync_mode: sync + collection_order: release + url_poster: <> + sort_title: <> +collections: + Marvel Cinematic Universe: + template: + name: Set + list: 8194961 + poster: https://theposterdb.com/api/assets/162417 + Star Wars: + template: + name: Set + collection: 10 + poster: https://theposterdb.com/api/assets/164120 diff --git a/nixos/hosts/hades/pmm/config/TVShows.yml b/nixos/hosts/hades/pmm/config/TVShows.yml new file mode 100644 index 0000000..8ee5706 --- /dev/null +++ b/nixos/hosts/hades/pmm/config/TVShows.yml @@ -0,0 +1,36 @@ +templates: + set: + optional: + - network + - list + tmdb_network: <> + tmdb_list: <> + sort_title: <> + sync_mode: sync + url_poster: <> + url_background: <> + +collections: + Marvel Television: + template: + name: set, + list: "8205726" + poster: https://theposterdb.com/api/assets/239453 + background: https://i.imgur.com/ckx6reE.jpg + summary: Marvel Television + + Star Wars: + template: + name: set + list: "8205730" + poster: https://theposterdb.com/api/assets/164120 + background: https://i.imgur.com/OvxROTE.jpg + summary: Star Wars + + Star Trek: + template: + name: set + list: "8215091" + poster: https://theposterdb.com/api/assets/222279 + background: https://i.imgur.com/Yp0NCZa.jpg + summary: Star Trek diff --git a/nixos/hosts/hades/pmm/configuration.nix b/nixos/hosts/hades/pmm/configuration.nix new file mode 100644 index 0000000..44b112c --- /dev/null +++ b/nixos/hosts/hades/pmm/configuration.nix @@ -0,0 +1,49 @@ +# Edit this configuration file to define what should be installed on +# your system. Help is available in the configuration.nix(5) man page +# and in the NixOS manual (accessible by running ‘nixos-help’). + +{ config, pkgs, ... }: +let + datadir = "/var/lib/pmm/config"; + container = "meisnate12/plex-meta-manager:latest"; + run_pmm = pkgs.writeScriptBin "pmm-run" '' + sudo ${pkgs.podman}/bin/podman run --rm -it \ + -v "/var/lib/pmm/config:/config:rw" \ + -v "/etc/pmm/Anime.yml:/config/Anime.yml:ro" \ + -v "/etc/pmm/Movies.yml:/config/Movies.yml:ro" \ + -v "/etc/pmm/TVShows.yml:/config/TVShows.yml:ro" \ + ${container} --run + ''; +in { + imports = [ ]; + + # This value determines the NixOS release from which the default + # settings for stateful data, like file locations and database versions + # on your system were taken. It‘s perfectly fine and recommended to leave + # this value at the release version of the first install of this system. + # Before changing this value read the documentation for this option + # (e.g. man configuration.nix or on https://nixos.org/nixos/options.html). + system.stateVersion = "22.11"; # Did you read the comment? + + networking.firewall.allowedTCPPorts = [ ]; + + environment.etc.pmm.source = ./config; + + environment.systemPackages = [ run_pmm ]; + + virtualisation.podman.enable = true; + virtualisation.oci-containers = { + backend = "podman"; + containers = { + plex-meta-manager = { + image = container; + volumes = [ + "${datadir}:/config:rw" + "/etc/pmm/Anime.yml:/config/Anime.yml:ro" + "/etc/pmm/Movies.yml:/config/Movies.yml:ro" + "/etc/pmm/TVShows.yml:/config/TVShows.yml:ro" + ]; + }; + }; + }; +} diff --git a/nixos/hosts/thalassa/null/configuration.nix b/nixos/hosts/thalassa/null/configuration.nix index f56e060..5aa6820 100644 --- a/nixos/hosts/thalassa/null/configuration.nix +++ b/nixos/hosts/thalassa/null/configuration.nix @@ -85,6 +85,10 @@ in # loader.systemd-boot.configurationLimit = 6; loader.efi.canTouchEfiVariables = true; loader.efi.efiSysMountPoint = "/boot/efi"; + + kernel.sysctl = { + "fs.inotify.max_user_watches" = 524288; + }; }; services.gnome.gnome-keyring.enable = true; diff --git a/nixos/hosts/thalassa/null/home/default.nix b/nixos/hosts/thalassa/null/home/default.nix index e364cfa..57bb74d 100644 --- a/nixos/hosts/thalassa/null/home/default.nix +++ b/nixos/hosts/thalassa/null/home/default.nix @@ -39,9 +39,10 @@ in { k9s kubectl libnotify + mullvad-vpn neofetch nixpkgs-review - mullvad-vpn + ouch plex-media-player plexamp python3 @@ -102,6 +103,10 @@ in { userName = "Victor"; userEmail = "victor@xirion.net"; lfs.enable = true; + delta.enable = true; + extraConfig = { + push.autoSetupRemote = true; + }; }; programs.mako = { diff --git a/nixos/hosts/thalassa/null/home/eww/default.nix b/nixos/hosts/thalassa/null/home/eww/default.nix index 7937e5e..dadcc75 100644 --- a/nixos/hosts/thalassa/null/home/eww/default.nix +++ b/nixos/hosts/thalassa/null/home/eww/default.nix @@ -9,7 +9,7 @@ home.file.".config/eww/eww.yuck".source = ./eww.yuck; home.file.".config/eww/eww.scss".text = builtins.readFile ./eww.scss; - # scripts + # scripts # TODO: just link all scripts in ./scripts to .config/eww/scripts home.file.".config/eww/scripts/volume.sh" = { source = ./scripts/volume.sh; diff --git a/nixos/lxc-template.nix b/nixos/proxmox-lxc.nix similarity index 100% rename from nixos/lxc-template.nix rename to nixos/proxmox-lxc.nix