move base data dir
This commit is contained in:
parent
9b13797b9b
commit
999740e7bd
|
@ -15,7 +15,9 @@
|
||||||
./services/minecraft
|
./services/minecraft
|
||||||
./services/mpd
|
./services/mpd
|
||||||
./services/paperless-ngx
|
./services/paperless-ngx
|
||||||
|
./services/postgresql
|
||||||
./services/traefik
|
./services/traefik
|
||||||
|
./services/wiki-js
|
||||||
|
|
||||||
# Multimedia
|
# Multimedia
|
||||||
./multimedia/jellyfin
|
./multimedia/jellyfin
|
||||||
|
|
|
@ -57,18 +57,12 @@
|
||||||
fsType = "ext4";
|
fsType = "ext4";
|
||||||
};
|
};
|
||||||
|
|
||||||
fileSystems."/srv/containers" = {
|
fileSystems."/srv/multimedia/containers" = {
|
||||||
device = "/dev/disk/by-label/data";
|
device = "/dev/disk/by-label/data";
|
||||||
fsType = "btrfs";
|
fsType = "btrfs";
|
||||||
options = ["subvol=containers" "compress=zstd"];
|
options = ["subvol=containers" "compress=zstd"];
|
||||||
};
|
};
|
||||||
|
|
||||||
fileSystems."/srv/services" = {
|
|
||||||
device = "/dev/disk/by-label/data";
|
|
||||||
fsType = "btrfs";
|
|
||||||
options = ["subvol=services" "compress=zstd"];
|
|
||||||
};
|
|
||||||
|
|
||||||
fileSystems."/srv/shares" = {
|
fileSystems."/srv/shares" = {
|
||||||
device = "/dev/disk/by-label/data";
|
device = "/dev/disk/by-label/data";
|
||||||
fsType = "btrfs";
|
fsType = "btrfs";
|
||||||
|
|
|
@ -16,8 +16,8 @@ in {
|
||||||
# Media library
|
# Media library
|
||||||
"/srv/multimedia/library:/media:ro"
|
"/srv/multimedia/library:/media:ro"
|
||||||
# Container data
|
# Container data
|
||||||
"/srv/containers/jellyfin/config:/config:rw"
|
"/srv/multimedia/containers/jellyfin/config:/config:rw"
|
||||||
"/srv/containers/jellyfin/cache:/cache:rw"
|
"/srv/multimedia/containers/jellyfin/cache:/cache:rw"
|
||||||
];
|
];
|
||||||
environment = {
|
environment = {
|
||||||
PUID = "1000";
|
PUID = "1000";
|
||||||
|
|
|
@ -13,7 +13,7 @@ in {
|
||||||
# Media library
|
# Media library
|
||||||
"/srv/multimedia:/data:rw"
|
"/srv/multimedia:/data:rw"
|
||||||
# Container data
|
# Container data
|
||||||
"/srv/containers/lidarr:/config:rw"
|
"/srv/multimedia/containers/lidarr:/config:rw"
|
||||||
];
|
];
|
||||||
environment = {
|
environment = {
|
||||||
PUID = "1000";
|
PUID = "1000";
|
||||||
|
|
|
@ -11,7 +11,7 @@ in {
|
||||||
];
|
];
|
||||||
volumes = [
|
volumes = [
|
||||||
# Container data
|
# Container data
|
||||||
"/srv/containers/prowlarr:/config:rw"
|
"/srv/multimedia/containers/prowlarr:/config:rw"
|
||||||
];
|
];
|
||||||
environment = {
|
environment = {
|
||||||
PUID = "1000";
|
PUID = "1000";
|
||||||
|
|
|
@ -13,7 +13,7 @@ in {
|
||||||
volumes = [
|
volumes = [
|
||||||
# Seedbox
|
# Seedbox
|
||||||
"/srv/multimedia/torrents:/data/torrents:rw"
|
"/srv/multimedia/torrents:/data/torrents:rw"
|
||||||
"/srv/containers/qbittorrent:/config:rw"
|
"/srv/multimedia/containers/qbittorrent:/config:rw"
|
||||||
];
|
];
|
||||||
environment = {
|
environment = {
|
||||||
PUID = "1000";
|
PUID = "1000";
|
||||||
|
|
|
@ -13,7 +13,7 @@ in {
|
||||||
# Media library
|
# Media library
|
||||||
"/srv/multimedia:/data:rw"
|
"/srv/multimedia:/data:rw"
|
||||||
# Container data
|
# Container data
|
||||||
"/srv/containers/radarr:/config:rw"
|
"/srv/multimedia/containers/radarr:/config:rw"
|
||||||
];
|
];
|
||||||
environment = {
|
environment = {
|
||||||
PUID = "1000";
|
PUID = "1000";
|
||||||
|
|
|
@ -13,7 +13,7 @@ in {
|
||||||
# Media library
|
# Media library
|
||||||
"/srv/multimedia:/data:rw"
|
"/srv/multimedia:/data:rw"
|
||||||
# Container data
|
# Container data
|
||||||
"/srv/containers/sonarr:/config:rw"
|
"/srv/multimedia/containers/sonarr:/config:rw"
|
||||||
];
|
];
|
||||||
environment = {
|
environment = {
|
||||||
PUID = "1000";
|
PUID = "1000";
|
||||||
|
|
|
@ -5,20 +5,27 @@
|
||||||
|
|
||||||
services.borgbackup.jobs."borgbase" = {
|
services.borgbackup.jobs."borgbase" = {
|
||||||
paths = [
|
paths = [
|
||||||
# Shares
|
|
||||||
"/srv/shares/sajenim"
|
|
||||||
# Services
|
# Services
|
||||||
"/srv/services/forgejo"
|
"/srv/minecraft"
|
||||||
"/srv/services/immich"
|
"/srv/shares/sajenim"
|
||||||
"/srv/services/minecraft"
|
"/srv/www/sajenim.dev"
|
||||||
"/srv/services/paperless-ngx"
|
"/var/lib/crowdsec"
|
||||||
# Containers
|
"/var/lib/forgejo"
|
||||||
"/srv/containers/jellyfin"
|
"/var/lib/immich"
|
||||||
"/srv/containers/lidarr"
|
"/var/lib/paperless-ngx"
|
||||||
"/srv/containers/prowlarr"
|
"/var/lib/postgresql"
|
||||||
"/srv/containers/qbittorrent"
|
"/var/lib/private/wiki-js"
|
||||||
"/srv/containers/radarr"
|
"/var/lib/redis-immich"
|
||||||
"/srv/containers/sonarr"
|
"/var/lib/redis-paperless"
|
||||||
|
"/var/lib/traefik"
|
||||||
|
"/var/lib/wiki-js"
|
||||||
|
# Multimedia
|
||||||
|
"/srv/multimedia/containers/jellyfin"
|
||||||
|
"/srv/multimedia/containers/lidarr"
|
||||||
|
"/srv/multimedia/containers/prowlarr"
|
||||||
|
"/srv/multimedia/containers/qbittorrent"
|
||||||
|
"/srv/multimedia/containers/radarr"
|
||||||
|
"/srv/multimedia/containers/sonarr"
|
||||||
];
|
];
|
||||||
|
|
||||||
repo = "o93k24r6@o93k24r6.repo.borgbase.com:repo";
|
repo = "o93k24r6@o93k24r6.repo.borgbase.com:repo";
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
{config, ...}: {
|
{config, ...}: {
|
||||||
services.forgejo = {
|
services.forgejo = {
|
||||||
enable = true;
|
enable = true;
|
||||||
stateDir = "/srv/services/forgejo";
|
stateDir = "/var/lib/forgejo";
|
||||||
settings = {
|
settings = {
|
||||||
server = {
|
server = {
|
||||||
DOMAIN = "git.sajenim.dev";
|
DOMAIN = "git.sajenim.dev";
|
||||||
|
@ -35,4 +35,14 @@
|
||||||
{url = "http://127.0.0.1:${toString config.services.forgejo.settings.server.HTTP_PORT}";}
|
{url = "http://127.0.0.1:${toString config.services.forgejo.settings.server.HTTP_PORT}";}
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
|
|
||||||
|
environment.persistence."/persist" = {
|
||||||
|
directories = [
|
||||||
|
{
|
||||||
|
directory = "/var/lib/forgejo";
|
||||||
|
user = "forgejo";
|
||||||
|
group = "forgejo";
|
||||||
|
}
|
||||||
|
];
|
||||||
|
};
|
||||||
}
|
}
|
||||||
|
|
|
@ -20,7 +20,7 @@
|
||||||
port = 5489;
|
port = 5489;
|
||||||
host = "0.0.0.0";
|
host = "0.0.0.0";
|
||||||
openFirewall = true;
|
openFirewall = true;
|
||||||
mediaLocation = "/srv/services/immich/library";
|
mediaLocation = "/var/lib/immich";
|
||||||
secretsFile = config.age.secrets.immich.path;
|
secretsFile = config.age.secrets.immich.path;
|
||||||
database = {
|
database = {
|
||||||
enable = true;
|
enable = true;
|
||||||
|
@ -52,4 +52,19 @@
|
||||||
{url = "http://127.0.0.1:${toString config.services.immich.port}";}
|
{url = "http://127.0.0.1:${toString config.services.immich.port}";}
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
|
|
||||||
|
environment.persistence."/persist" = {
|
||||||
|
directories = [
|
||||||
|
{
|
||||||
|
directory = "/var/lib/immich";
|
||||||
|
user = "immich";
|
||||||
|
group = "immich";
|
||||||
|
}
|
||||||
|
{
|
||||||
|
directory = "/var/lib/redis-immich";
|
||||||
|
user = "immich";
|
||||||
|
group = "immich";
|
||||||
|
}
|
||||||
|
];
|
||||||
|
};
|
||||||
}
|
}
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
services.lighttpd = {
|
services.lighttpd = {
|
||||||
enable = true;
|
enable = true;
|
||||||
port = 5624;
|
port = 5624;
|
||||||
document-root = "/srv/services/websites/sajenim.dev";
|
document-root = "/srv/www/sajenim.dev";
|
||||||
};
|
};
|
||||||
|
|
||||||
services.traefik.dynamicConfigOptions.http.routers = {
|
services.traefik.dynamicConfigOptions.http.routers = {
|
||||||
|
@ -24,4 +24,14 @@
|
||||||
{url = "http://127.0.0.1:${toString config.services.lighttpd.port}";}
|
{url = "http://127.0.0.1:${toString config.services.lighttpd.port}";}
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
|
|
||||||
|
environment.persistence."/persist" = {
|
||||||
|
directories = [
|
||||||
|
{
|
||||||
|
directory = "/srv/www";
|
||||||
|
user = "lighttpd";
|
||||||
|
group = "lighttpd";
|
||||||
|
}
|
||||||
|
];
|
||||||
|
};
|
||||||
}
|
}
|
||||||
|
|
|
@ -70,7 +70,7 @@ in {
|
||||||
};
|
};
|
||||||
|
|
||||||
# Each server will be under a subdirectory named after the server name.
|
# Each server will be under a subdirectory named after the server name.
|
||||||
dataDir = "/srv/services/minecraft";
|
dataDir = "/srv/minecraft";
|
||||||
|
|
||||||
# Open firewall for all servers.
|
# Open firewall for all servers.
|
||||||
openFirewall = true;
|
openFirewall = true;
|
||||||
|
@ -97,4 +97,14 @@ in {
|
||||||
{url = "http://127.0.0.1:${toString config.services.minecraft-servers.servers.kanto.serverProperties.server-port}";}
|
{url = "http://127.0.0.1:${toString config.services.minecraft-servers.servers.kanto.serverProperties.server-port}";}
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
|
|
||||||
|
environment.persistence."/persist" = {
|
||||||
|
directories = [
|
||||||
|
{
|
||||||
|
directory = "/srv/minecraft";
|
||||||
|
user = "minecraft";
|
||||||
|
group = "minecraft";
|
||||||
|
}
|
||||||
|
];
|
||||||
|
};
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
{config, ...}: let
|
{config, ...}: let
|
||||||
dir = "/srv/services/paperless-ngx";
|
dir = "/var/lib/paperless-ngx";
|
||||||
in {
|
in {
|
||||||
age.secrets.paperless-ngx = {
|
age.secrets.paperless-ngx = {
|
||||||
rekeyFile = ./password.age;
|
rekeyFile = ./password.age;
|
||||||
|
@ -34,4 +34,19 @@ in {
|
||||||
{url = "http://127.0.0.1:${toString config.services.paperless.port}";}
|
{url = "http://127.0.0.1:${toString config.services.paperless.port}";}
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
|
|
||||||
|
environment.persistence."/persist" = {
|
||||||
|
directories = [
|
||||||
|
{
|
||||||
|
directory = "/var/lib/paperless-ngx";
|
||||||
|
user = "paperless";
|
||||||
|
group = "paperless";
|
||||||
|
}
|
||||||
|
{
|
||||||
|
directory = "/var/lib/redis-paperless";
|
||||||
|
user = "redis-paperless";
|
||||||
|
group = "redis-paperless";
|
||||||
|
}
|
||||||
|
];
|
||||||
|
};
|
||||||
}
|
}
|
||||||
|
|
|
@ -98,6 +98,11 @@
|
||||||
main = "sajenim.dev";
|
main = "sajenim.dev";
|
||||||
sans = ["*.sajenim.dev"];
|
sans = ["*.sajenim.dev"];
|
||||||
}
|
}
|
||||||
|
# Keyboards
|
||||||
|
{
|
||||||
|
main = "sajkbd.io";
|
||||||
|
sans = ["*.sajkbd.io"];
|
||||||
|
}
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
Loading…
Reference in a new issue