shelfmark
Unified web interface for searching and aggregating books and audiobook downloads
Example
{config, ...}: {
nps.stacks.shelfmark = {
enable = true;
downloadDirectory = "${config.nps.storageBaseDir}/grimmory/bookdrop";
useProwlarr = true;
useQbittorrent = true;
extraEnv = {
PROWLARR_API_KEY.fromFile = config.sops.secrets."prowlarr/api_key".path;
QBITTORRENT_USERNAME = "admin";
QBITTORRENT_PASSWORD.fromFile = config.sops.secrets."qbittorrent/password".path;
};
};
}For a full list of environment variables, see the Shelfmark documentation.
Stack Options
nps.stacks.shelfmark.downloadDirectory
Final host directory where downloads will be placed. To automatically ingest books in other applications such as CWA or Booklore, set this to the respective app's import directory.
string
"${config.nps.storageBaseDir}/shelfmark/books"
"${config.nps.storageBaseDir}/grimmory/bookdrop"
nps.stacks.shelfmark.enable
Whether to enable shelfmark.
nps.stacks.shelfmark.extraEnv
Extra environment variables to set for the container. Variables can be either set directly or sourced from a file (e.g. for secrets).
See https://github.com/calibrain/shelfmark/blob/main/docs/environment-variables.md
attribute set of (null or boolean or signed integer or string or absolute path or (submodule))
{ }
{
SOME_SECRET = {
fromFile = "/run/secrets/secret_name";
};
SOME_VALUE = "some_value";
}
nps.stacks.shelfmark.oidc.adminGroup
Users of this group will be assigned admin rights
nps.stacks.shelfmark.oidc.clientSecretFile
The file containing the client secret for the OIDC client that will be registered in Authelia.
For examples on how to generate a client secret, see
https://www.authelia.com/integration/openid-connect/frequently-asked-questions/#client-secret
absolute path
config.sops.secrets."immich/authelia/client_secret".path"
nps.stacks.shelfmark.oidc.clientSecretHash
The client secret hash. For examples on how to generate a client secret, see https://www.authelia.com/integration/openid-connect/frequently-asked-questions/#client-secret
The value can be passed in multiple ways:
- As a literal string
- As an absolute path to a file containing the hash (
toFile) - As an absolute oath to a file containing the client_secret, in which case the hash will be automatically computed (
toHash) - As
null
If left unset (null), the client secret will be read from the file specified in the clientSecretFile option and hashed automatically before being passed to the Authelia container.
null or string or (submodule)
null
# Literal String:
"$pbkdf2-sha512$310000$cbOAIWbfz3vCVXIPIp6d2A$J0klwULa6TvPRCU1HAfuKua/dMKTl8gbTYJz2N73ejGUu0LUGz/y3kwmJLuKuAYGg3WQOT0q9ZzVHHUvpKpgvQ"
# Client secret hash stored in a file
{ fromFile = config.sops.secrets."immich/client_secret_hash".path; }
# Client secret stored in a file: Hash will be computed dynamically
{ toHash = config.sops.secrets."immich/client_secret".path; }
# Null (default): Hash will be computed automatically based on the clientSecretFile option
# Equivalent to { toHash = cfg.oidc.clientSecretFile; }
null
nps.stacks.shelfmark.oidc.enable
Whether to enable OIDC login with Authelia. This will register an OIDC client in Authelia and setup the necessary configuration.
For details, see:
nps.stacks.shelfmark.oidc.userGroup
Users must be a part of this group to be able to log in.
nps.stacks.shelfmark.useFlaresolverr
Whether to enable the Flaresolverr stack and connect it to the Shelfmark network. Shelfmark uses Flaresolverr to bypass Cloudflare protection.
nps.stacks.shelfmark.useProwlarr
Whether to enable the Prowlarr stack and connect it to the Shelfmark network.
Sets PROWLARR_ENABLED and PROWLARR_URL.
You will likely also need to set PROWLARR_API_KEY via extraEnv
(Settings > General > API Key).
nps.stacks.shelfmark.useQbittorrent
Whether to enable the qBittorrent stack and connect it to the Shelfmark network.
Sets PROWLARR_TORRENT_CLIENT, QBITTORRENT_URL, QBITTORRENT_CATEGORY and QBITTORRENT_CATEGORY_AUDIOBOOK.
If authentication isn't bypassed in qBittorrent, you may need to set credentials via extraEnv (QBITTORRENT_USERNAME/QBITTORRENT_PASSWORD or QBITTORRENT_API_KEY).
Container Aliases
nps.stacks.shelfmark.containers.shelfmark
Alias of {option}services.podman.containers.shelfmark.
