initial postgres arr migration
This commit is contained in:
@@ -6,6 +6,17 @@
|
||||
}:
|
||||
let
|
||||
vars = import ../vars.nix;
|
||||
arr_postgres_config =
|
||||
container_type:
|
||||
let
|
||||
ctype = lib.strings.toUpper container_type;
|
||||
in
|
||||
{
|
||||
"${ctype}__POSTGRES__HOST" = "host.docker.internal";
|
||||
"${ctype}__POSTGRES__USER" = "SOPS_ONLY";
|
||||
"${ctype}__POSTGRES__PASSWORD" = "SOPS_ONLY";
|
||||
"${ctype}__POSTGRES__PORT" = toString config.services.postgresql.settings.port;
|
||||
};
|
||||
in
|
||||
{
|
||||
virtualisation.oci-containers.containers = {
|
||||
@@ -16,12 +27,19 @@ in
|
||||
PUID = "600";
|
||||
PGID = "100";
|
||||
TZ = "America/New_York";
|
||||
POSTGRES_HOST = "host.docker.internal";
|
||||
POSTGRES_USER = "SOPS_ONLY";
|
||||
POSTGRES_PASSWORD = "SOPS_ONLY";
|
||||
POSTGRES_PORT = toString config.services.postgresql.settings.port;
|
||||
};
|
||||
volumes = [
|
||||
"${vars.primary_docker}/bazarr:/config"
|
||||
"${vars.primary_plex_storage}/data:/data"
|
||||
];
|
||||
extraOptions = [ "--network=arrnet" ];
|
||||
extraOptions = [
|
||||
"--network=arrnet"
|
||||
"--add-host=host.docker.internal:host-gateway"
|
||||
];
|
||||
autoStart = true;
|
||||
};
|
||||
prowlarr = {
|
||||
@@ -31,7 +49,8 @@ in
|
||||
PUID = "600";
|
||||
PGID = "100";
|
||||
TZ = "America/New_York";
|
||||
};
|
||||
}
|
||||
// arr_postgres_config "prowlarr";
|
||||
extraOptions = [ "--network=arrnet" ];
|
||||
volumes = [ "${vars.primary_docker}/prowlarr:/config" ];
|
||||
autoStart = true;
|
||||
@@ -43,7 +62,8 @@ in
|
||||
PUID = "600";
|
||||
PGID = "100";
|
||||
TZ = "America/New_York";
|
||||
};
|
||||
}
|
||||
// arr_postgres_config "radarr";
|
||||
volumes = [
|
||||
"${vars.primary_docker}/radarr:/config"
|
||||
"${vars.primary_plex_storage}/data:/data"
|
||||
@@ -58,7 +78,8 @@ in
|
||||
PUID = "600";
|
||||
PGID = "100";
|
||||
TZ = "America/New_York";
|
||||
};
|
||||
}
|
||||
// arr_postgres_config "sonarr";
|
||||
volumes = [
|
||||
"${vars.primary_docker}/sonarr:/config"
|
||||
"${vars.primary_plex_storage}/data:/data"
|
||||
@@ -73,7 +94,8 @@ in
|
||||
PUID = "600";
|
||||
PGID = "100";
|
||||
TZ = "America/New_York";
|
||||
};
|
||||
}
|
||||
// arr_postgres_config "lidarr";
|
||||
volumes = [
|
||||
"${vars.primary_docker}/lidarr:/config"
|
||||
"${vars.primary_plex_storage}/data:/data"
|
||||
@@ -100,7 +122,8 @@ in
|
||||
user = "600:100";
|
||||
environment = {
|
||||
TZ = "America/New_York";
|
||||
};
|
||||
}
|
||||
// arr_postgres_config "notifiarr";
|
||||
environmentFiles = [ config.sops.secrets."docker/notifiarr".path ];
|
||||
volumes = [
|
||||
"${vars.primary_docker}/notifiarr:/config"
|
||||
@@ -115,6 +138,11 @@ in
|
||||
PUID = "600";
|
||||
PGID = "100";
|
||||
TZ = "America/New_York";
|
||||
DB_TYPE = "postgres";
|
||||
DB_HOST = "host.docker.internal";
|
||||
DB_PORT = toString config.services.postgresql.settings.port;
|
||||
DB_USER = "SOPS_ONLY";
|
||||
DB_PASS = "SOPS_ONLY";
|
||||
};
|
||||
volumes = [ "${vars.primary_docker}/overseerr:/config" ];
|
||||
# TODO: remove ports later since this is going through web
|
||||
|
||||
@@ -49,7 +49,7 @@
|
||||
daily = 30;
|
||||
weekly = 0;
|
||||
monthly = 6;
|
||||
yearly = 3;
|
||||
yearly = 2;
|
||||
autosnap = true;
|
||||
autoprune = true;
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user