90 lines
No EOL
2.9 KiB
Nix
90 lines
No EOL
2.9 KiB
Nix
{ lib, inputs, fetchFromGitHub, pkgs, stdenv, ... }:
|
||
let
|
||
erl = pkgs.beam.interpreters.erlang_28;
|
||
erlangPackages = pkgs.beam.packagesWith erl;
|
||
|
||
elixir = erlangPackages.elixir;
|
||
mix = "${elixir}/bin/mix";
|
||
rebar = erlangPackages.rebar;
|
||
hex = erlangPackages.hex;
|
||
|
||
bun = pkgs.bun;
|
||
bun2nix = inputs.bun2nix.packages.${stdenv.hostPlatform.system}.default;
|
||
|
||
translatedPlatform =
|
||
{
|
||
aarch64-darwin = "macos-arm64";
|
||
aarch64-linux = "linux-arm64";
|
||
armv7l-linux = "linux-armv7";
|
||
x86_64-darwin = "macos-x64";
|
||
x86_64-linux = "linux-x64";
|
||
}
|
||
.${stdenv.hostPlatform.system};
|
||
|
||
version = "v0.6.0";
|
||
pname = "mydia";
|
||
src = fetchFromGitHub {
|
||
owner = "getmydia";
|
||
repo = "mydia";
|
||
rev = version;
|
||
hash = "sha256-JGT52ulnqcx8o+3e0l50TLAwLIWXEI8nwFGUsA95vH0=";
|
||
};
|
||
mixFodDeps = erlangPackages.fetchMixDeps {
|
||
inherit version src;
|
||
pname = "mix-deps-${pname}";
|
||
hash = "sha256-19q56IZe8YjuUBXirFGgmBsewJ0cmdOoO1yfiMaWGWk=";
|
||
};
|
||
npmFodDeps= pkgs.fetchNpmDeps {
|
||
src = "${src}/assets";
|
||
hash = "sha256-0cz75pxhxvzo1RogsV8gTP6GrgLIboWQXcKpq42JZ6o=";
|
||
};
|
||
in
|
||
erlangPackages.mixRelease {
|
||
inherit pname version src mixFodDeps;
|
||
|
||
nativeBuildInputs = with pkgs; [
|
||
# ffmpeg_7
|
||
# pkg-config
|
||
# tailwindcss
|
||
];
|
||
buildInputs = with pkgs; [
|
||
ffmpeg_7
|
||
pkg-config
|
||
];
|
||
|
||
preInstall = ''
|
||
ln -s ${pkgs.tailwindcss}/bin/tailwind _build/tailwind-${translatedPlatform}
|
||
ln -s ${pkgs.esbuild}/bin/esbuild _build/esbuild-${translatedPlatform}
|
||
ln -s ${npmFodDeps} assets/node_modules
|
||
|
||
${mix} assets.deploy
|
||
'';
|
||
|
||
meta = {
|
||
description = "Your personal media companion, built with Phoenix LiveView";
|
||
longDescription = ''
|
||
A modern, self-hosted media management platform for tracking, organizing, and monitoring your media library.
|
||
|
||
# ✨ Features
|
||
|
||
- 📺 Unified Media Management – Track both movies and TV shows with rich metadata from TMDB/TVDB
|
||
- 🤖 Automated Downloads – Background search and download with quality profiles and smart release ranking
|
||
- ⬇️ Download Clients – qBittorrent, Transmission, SABnzbd, and NZBGet support
|
||
- 🔎 Indexer Integration – Search via Prowlarr and Jackett for finding releases
|
||
- 📚 Built-in Indexer Library – Native Cardigann support (experimental, limited testing)
|
||
- 👥 Multi-User System – Built-in admin/guest roles with request approval workflow
|
||
- 🔐 SSO Support – Local authentication plus OIDC/OpenID Connect integration
|
||
- 🔔 Release Calendar – Track upcoming releases and monitor episodes
|
||
- 🎨 Modern Real-Time UI – Phoenix LiveView with instant updates and responsive design
|
||
'';
|
||
|
||
homepage = "https://github.com/getmydia/mydia";
|
||
changelog = "https://github.com/getmydia/mydia/releases";
|
||
license = lib.licenses.agpl3Only;
|
||
|
||
maintainers = [];
|
||
|
||
platforms = lib.platforms.all;
|
||
mainProgram = pname;
|
||
};
|
||
} |