Replace docker cross-seed with native one
This commit is contained in:
parent
5309864a82
commit
a40431a30e
4 changed files with 46 additions and 21 deletions
|
@ -24,6 +24,7 @@
|
|||
inputs.common-modules.nixosModules.nixos-upgrade
|
||||
inputs.common-modules.nixosModules.qbittorrent-nox
|
||||
inputs.common-modules.nixosModules.unpackerr
|
||||
inputs.common-modules.nixosModules.cross-seed
|
||||
];
|
||||
|
||||
nixpkgs.config.allowUnfree = true;
|
||||
|
|
11
flake.lock
generated
11
flake.lock
generated
|
@ -60,15 +60,16 @@
|
|||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1731283839,
|
||||
"narHash": "sha256-8QaXesIQv6qzPIqyryxAD1x4gBLulmhXPlsJf6ymnpI=",
|
||||
"ref": "refs/heads/main",
|
||||
"rev": "8396704342026b42cecf0ae86c84ad1d537b1d4a",
|
||||
"revCount": 96,
|
||||
"lastModified": 1731627558,
|
||||
"narHash": "sha256-wqCwATQqlAPEAN5EDj9GKkPpJ582muMPEgo8zo9jSeE=",
|
||||
"ref": "cross-seed",
|
||||
"rev": "95827f9822617f67ed328d28b5d249ad7f842f18",
|
||||
"revCount": 105,
|
||||
"type": "git",
|
||||
"url": "https://forge.catnip.ee/batteredbunny/common.nix"
|
||||
},
|
||||
"original": {
|
||||
"ref": "cross-seed",
|
||||
"type": "git",
|
||||
"url": "https://forge.catnip.ee/batteredbunny/common.nix"
|
||||
}
|
||||
|
|
|
@ -15,7 +15,7 @@
|
|||
};
|
||||
|
||||
common-modules = {
|
||||
url = "git+https://forge.catnip.ee/batteredbunny/common.nix";
|
||||
url = "git+https://forge.catnip.ee/batteredbunny/common.nix?ref=cross-seed";
|
||||
inputs.nixpkgs.follows = "nixpkgs";
|
||||
};
|
||||
confess.url = "git+ssh://forgejo@forge.catnip.ee:2222/batteredbunny/confess";
|
||||
|
|
|
@ -1,17 +1,40 @@
|
|||
{ settings, ... }: {
|
||||
virtualisation.oci-containers.containers.cross-seed = {
|
||||
autoStart = true;
|
||||
image = "ghcr.io/cross-seed/cross-seed:master";
|
||||
volumes = [
|
||||
"${settings.server_configs_home}/cross-seed/config:/config"
|
||||
"${settings.server_configs_home}/cross-seed/cross-seed:/cross-seeds"
|
||||
"/home/owo/.local/share/qBittorrent/BT_backup:/torrents"
|
||||
];
|
||||
cmd = [
|
||||
"daemon"
|
||||
];
|
||||
extraOptions = [
|
||||
"--network=host"
|
||||
];
|
||||
{ pkgs, lib, ... }:
|
||||
let
|
||||
cross-seed = pkgs.buildNpmPackage rec {
|
||||
pname = "cross-seed";
|
||||
version = "6.0.0-43";
|
||||
|
||||
src = pkgs.fetchFromGitHub {
|
||||
owner = "cross-seed";
|
||||
repo = "cross-seed";
|
||||
rev = "v${version}";
|
||||
hash = "sha256-oglNCTZ9o4saqnQ0imsjNeobsTFn9ZT6yVjOzBO+BTo=";
|
||||
};
|
||||
|
||||
npmDepsHash = "sha256-Ta5QKHn3tX4ZGZEiMg8RYlJykM7TuQWVML/v9ujWYVU=";
|
||||
|
||||
meta = {
|
||||
description = "Fully-automatic torrent cross-seeding with Torznab";
|
||||
homepage = "https://cross-seed.org";
|
||||
license = lib.licenses.asl20;
|
||||
mainProgram = "cross-seed";
|
||||
maintainers = with lib.maintainers; [ mkez ];
|
||||
};
|
||||
}; # TODO: delete this when merged https://github.com/NixOS/nixpkgs/pull/329243
|
||||
in
|
||||
{
|
||||
services.cross-seed = {
|
||||
enable = true;
|
||||
package = cross-seed;
|
||||
|
||||
environmentFile = "/etc/secrets/cross-seed.env";
|
||||
|
||||
settings = {
|
||||
torrentDir = "/home/owo/.local/share/qBittorrent/BT_backup";
|
||||
action = "inject";
|
||||
duplicateCategories = true;
|
||||
searchTimeout = "2 minutes";
|
||||
searchLimit = 100;
|
||||
};
|
||||
};
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue