mirror of
https://github.com/genebean/dots.git
synced 2026-03-27 01:17:42 -04:00
Move Audiobookshelf into containers subdirectory
This commit is contained in:
parent
579157fbf6
commit
b839db1186
3 changed files with 34 additions and 27 deletions
|
|
@ -1,26 +0,0 @@
|
|||
{ ... }: let
|
||||
volume_base = "/orico/audiobookshelf";
|
||||
in {
|
||||
# Audiobookshelf
|
||||
virtualisation.oci-containers.containers = {
|
||||
"audiobookshelf" = {
|
||||
autoStart = true;
|
||||
image = "ghcr.io/advplyr/audiobookshelf:latest";
|
||||
environment = {
|
||||
AUDIOBOOKSHELF_UID = "99";
|
||||
AUDIOBOOKSHELF_GID = "100";
|
||||
};
|
||||
ports = [ "13378:80" ];
|
||||
volumes = [
|
||||
"${volume_base}/audiobooks:/audiobooks"
|
||||
"${volume_base}/podcasts:/podcasts"
|
||||
"${volume_base}/printbooks:/printbooks"
|
||||
"${volume_base}/config:/config"
|
||||
"${volume_base}/metadata:/metadata"
|
||||
];
|
||||
};
|
||||
};
|
||||
services.restic.backups.daily.paths = [
|
||||
"/orico/audiobookshelf"
|
||||
];
|
||||
}
|
||||
33
modules/hosts/nixos/nixnuc/containers/audiobookshelf.nix
Normal file
33
modules/hosts/nixos/nixnuc/containers/audiobookshelf.nix
Normal file
|
|
@ -0,0 +1,33 @@
|
|||
{ ... }: let
|
||||
volume_base = "/orico/audiobookshelf";
|
||||
http_port = "13378";
|
||||
in {
|
||||
# Audiobookshelf
|
||||
|
||||
#############################################################################
|
||||
# I am using v2.8.1 because that is both the current Docker image and #
|
||||
# the current version in nixpkgs unstable. My plan is to switch from Podman #
|
||||
# to a systemd-nspawn container. #
|
||||
#############################################################################
|
||||
|
||||
virtualisation.oci-containers.containers = {
|
||||
"audiobookshelf" = {
|
||||
autoStart = true;
|
||||
image = "ghcr.io/advplyr/audiobookshelf:2.8.1";
|
||||
environment = {
|
||||
AUDIOBOOKSHELF_UID = "99";
|
||||
AUDIOBOOKSHELF_GID = "100";
|
||||
};
|
||||
ports = [ "${http_port}:80" ];
|
||||
volumes = [
|
||||
"${volume_base}/audiobooks:/audiobooks"
|
||||
"${volume_base}/podcasts:/podcasts"
|
||||
"${volume_base}/printbooks:/printbooks"
|
||||
"${volume_base}/config:/config"
|
||||
"${volume_base}/metadata:/metadata"
|
||||
];
|
||||
};
|
||||
};
|
||||
|
||||
services.restic.backups.daily.paths = [ volume_base ];
|
||||
}
|
||||
|
|
@ -1,7 +1,7 @@
|
|||
{ config, pkgs, username, ... }: {
|
||||
imports = [
|
||||
./hardware-configuration.nix
|
||||
./audiobookshelf.nix
|
||||
./containers/audiobookshelf.nix
|
||||
./containers/nginx-proxy.nix
|
||||
../../../system/common/linux/restic.nix
|
||||
];
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue