modify jellyfin & nix-bitcoin containers
This commit is contained in:
parent
51320794e6
commit
62a3630a5c
|
@ -18,11 +18,21 @@ in {
|
||||||
networking.nat.internalInterfaces = ["ve-+"];
|
networking.nat.internalInterfaces = ["ve-+"];
|
||||||
networking.nat.externalInterface = "br0";
|
networking.nat.externalInterface = "br0";
|
||||||
|
|
||||||
containers.postgres = {
|
containers.${container_name} = {
|
||||||
autoStart = true;
|
autoStart = true;
|
||||||
privateNetwork = true;
|
privateNetwork = true;
|
||||||
hostBridge = "br0";
|
hostBridge = "br0";
|
||||||
nixpkgs = pkgs.path;
|
nixpkgs = pkgs.path;
|
||||||
|
bindMounts = {
|
||||||
|
"/var/lib/jellyfin" = {
|
||||||
|
hostPath = "/media/main-ssd/jellyfin";
|
||||||
|
isReadOnly = false;
|
||||||
|
};
|
||||||
|
"/var/lib/jellyfin/data/media" = {
|
||||||
|
hostPath = "/media/media";
|
||||||
|
isReadOnly = true;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
config = {
|
config = {
|
||||||
pkgs,
|
pkgs,
|
||||||
|
@ -51,13 +61,13 @@ in {
|
||||||
services.jellyfin = {
|
services.jellyfin = {
|
||||||
enable = true;
|
enable = true;
|
||||||
openFirewall = true;
|
openFirewall = true;
|
||||||
|
user="jellyfin";
|
||||||
};
|
};
|
||||||
|
|
||||||
environment.systemPackages = [
|
environment.systemPackages = [
|
||||||
pkgs.jellyfin
|
pkgs.jellyfin
|
||||||
pkgs.jellyfin-web
|
pkgs.jellyfin-web
|
||||||
pkgs.jellyfin-ffmpeg
|
pkgs.jellyfin-ffmpeg
|
||||||
pkgs.lsof
|
|
||||||
];
|
];
|
||||||
|
|
||||||
services.openssh = {
|
services.openssh = {
|
||||||
|
|
|
@ -10,7 +10,7 @@
|
||||||
bitcoin-HMAC-privileged = lib.optionalString (lib.hasAttr "sops-nix" inputs) config.sops.secrets."software/bitcoind/bitcoin-HMAC-privileged".path;
|
bitcoin-HMAC-privileged = lib.optionalString (lib.hasAttr "sops-nix" inputs) config.sops.secrets."software/bitcoind/bitcoin-HMAC-privileged".path;
|
||||||
bitcoin-HMAC-public = lib.optionalString (lib.hasAttr "sops-nix" inputs) config.sops.secrets."software/bitcoind/bitcoin-HMAC-public".path;
|
bitcoin-HMAC-public = lib.optionalString (lib.hasAttr "sops-nix" inputs) config.sops.secrets."software/bitcoind/bitcoin-HMAC-public".path;
|
||||||
container_name = "bitcoin-node";
|
container_name = "bitcoin-node";
|
||||||
container_ip = "10.0.10.5";
|
container_ip = "10.0.10.4";
|
||||||
pubKeys = lib.filesystem.listFilesRecursive ../../users/keys;
|
pubKeys = lib.filesystem.listFilesRecursive ../../users/keys;
|
||||||
in {
|
in {
|
||||||
sops.secrets = {
|
sops.secrets = {
|
||||||
|
|
|
@ -26,7 +26,7 @@ in {
|
||||||
networking.nat.internalInterfaces = ["ve-+"];
|
networking.nat.internalInterfaces = ["ve-+"];
|
||||||
networking.nat.externalInterface = "br0";
|
networking.nat.externalInterface = "br0";
|
||||||
|
|
||||||
containers.postgres = {
|
containers.${container_name} = {
|
||||||
autoStart = true;
|
autoStart = true;
|
||||||
privateNetwork = true;
|
privateNetwork = true;
|
||||||
hostBridge = "br0";
|
hostBridge = "br0";
|
||||||
|
|
|
@ -49,6 +49,7 @@ in {
|
||||||
../common/optional/docker
|
../common/optional/docker
|
||||||
../common/optional/nixos-containers/nix-bitcoin.nix
|
../common/optional/nixos-containers/nix-bitcoin.nix
|
||||||
../common/optional/nixos-containers/postgres.nix
|
../common/optional/nixos-containers/postgres.nix
|
||||||
|
../common/optional/nixos-containers/jellyfin.nix
|
||||||
];
|
];
|
||||||
|
|
||||||
fileSystems."/media/main-ssd" = {
|
fileSystems."/media/main-ssd" = {
|
||||||
|
@ -85,6 +86,7 @@ in {
|
||||||
pkgs.sof-firmware
|
pkgs.sof-firmware
|
||||||
];
|
];
|
||||||
|
|
||||||
|
# Add hardware support for intel gpus as specified here: https://nixos.wiki/wiki/Jellyfin
|
||||||
nixpkgs.config.packageOverrides = pkgs: {
|
nixpkgs.config.packageOverrides = pkgs: {
|
||||||
vaapiIntel = pkgs.vaapiIntel.override {enableHybridCodec = true;};
|
vaapiIntel = pkgs.vaapiIntel.override {enableHybridCodec = true;};
|
||||||
};
|
};
|
||||||
|
@ -97,7 +99,8 @@ in {
|
||||||
vaapiVdpau
|
vaapiVdpau
|
||||||
libvdpau-va-gl
|
libvdpau-va-gl
|
||||||
intel-compute-runtime
|
intel-compute-runtime
|
||||||
vpl-gpu-rt
|
# only available on unstable
|
||||||
|
unstable.vpl-gpu-rt
|
||||||
intel-media-sdk
|
intel-media-sdk
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
|
|
Loading…
Reference in New Issue