formatting

This commit is contained in:
mjallen18
2024-02-28 21:49:51 -06:00
parent bdfd5e92b7
commit 347d30094b
40 changed files with 459 additions and 503 deletions

View File

@@ -1,11 +1,8 @@
{ lib, pkgs, config, ... }:
with lib;
let
cfg = config.nas-apps.collabora;
let cfg = config.nas-apps.collabora;
in {
imports = [
./options.nix
];
imports = [ ./options.nix ];
config = mkIf cfg.enable {
virtualisation.oci-containers.containers."${cfg.name}" = {
@@ -16,9 +13,9 @@ in {
# ...
];
environment = {
PUID = cfg.puid;
PGID = cfg.pgid;
TZ = cfg.timeZone;
PUID = cfg.puid;
PGID = cfg.pgid;
TZ = cfg.timeZone;
};
};
};

View File

@@ -1,9 +1,8 @@
{ lib, ... }:
with lib;
{
with lib; {
options.nas-apps.collabora = {
enable = mkEnableOption "collabora docker service";
autoStart = mkOption {
type = types.bool;
default = true;

View File

@@ -1,14 +1,11 @@
{ lib, pkgs, config, ... }:
with lib;
let
cfg = config.nas-apps.jellyfin;
let cfg = config.nas-apps.jellyfin;
in {
imports = [
./options.nix
];
imports = [ ./options.nix ];
config = mkIf cfg.enable {
systemd.services.jellyfin-nvidia-docker = {
path = [ pkgs.bash pkgs.docker ];
script = ''
@@ -74,4 +71,4 @@ in {
# # PGID = "1000";
# # };
# # };
# }
# }

View File

@@ -1,9 +1,8 @@
{ lib, ... }:
with lib;
{
with lib; {
options.nas-apps.jellyfin = {
enable = mkEnableOption "jellyfin docker service";
autoStart = mkOption {
type = types.bool;
default = true;
@@ -55,4 +54,4 @@ with lib;
};
};
}
}

View File

@@ -1,24 +1,19 @@
{ lib, pkgs, config, ... }:
with lib;
let
cfg = config.nas-apps.jellyseerr;
let cfg = config.nas-apps.jellyseerr;
in {
imports = [
./options.nix
];
imports = [ ./options.nix ];
config = mkIf cfg.enable {
virtualisation.oci-containers.containers."${cfg.name}" = {
autoStart = cfg.autoStart;
image = cfg.image;
ports = [ "${cfg.port}:5055" ];
volumes = [
"${cfg.configPath}:/config"
];
volumes = [ "${cfg.configPath}:/config" ];
environment = {
PUID = cfg.puid;
PGID = cfg.pgid;
TZ = cfg.timeZone;
PUID = cfg.puid;
PGID = cfg.pgid;
TZ = cfg.timeZone;
};
};
};

View File

@@ -1,9 +1,8 @@
{ lib, ... }:
with lib;
{
with lib; {
options.nas-apps.jellyseerr = {
enable = mkEnableOption "jellyseerr docker service";
autoStart = mkOption {
type = types.bool;
default = true;
@@ -45,4 +44,4 @@ with lib;
};
};
}
}

View File

@@ -1,28 +1,23 @@
{ lib, pkgs, config, ... }:
with lib;
let
cfg = config.nas-apps.mariadb;
let cfg = config.nas-apps.mariadb;
in {
imports = [
./options.nix
];
imports = [ ./options.nix ];
config = mkIf cfg.enable {
virtualisation.oci-containers.containers."${cfg.name}" = {
autoStart = cfg.autoStart;
image = cfg.image;
ports = [ "${cfg.port}:3306" ];
volumes = [
"${cfg.configPath}:/config"
];
volumes = [ "${cfg.configPath}:/config" ];
environment = {
PUID = cfg.puid;
PGID = cfg.pgid;
TZ = cfg.timeZone;
MYSQL_ROOT_PASSWORD = cfg.rootPassword;
MYSQL_DATABASE = cfg.databaseName;
MYSQL_USER = cfg.databaseUser;
MYSQL_PASSWORD = cfg.databasePassword;
PUID = cfg.puid;
PGID = cfg.pgid;
TZ = cfg.timeZone;
MYSQL_ROOT_PASSWORD = cfg.rootPassword;
MYSQL_DATABASE = cfg.databaseName;
MYSQL_USER = cfg.databaseUser;
MYSQL_PASSWORD = cfg.databasePassword;
};
};
};

View File

@@ -1,9 +1,8 @@
{ lib, ... }:
with lib;
{
with lib; {
options.nas-apps.mariadb = {
enable = mkEnableOption "mariadb docker service";
autoStart = mkOption {
type = types.bool;
default = true;

View File

@@ -1,25 +1,19 @@
{ lib, pkgs, config, ... }:
with lib;
let
cfg = config.nas-apps.nextcloud;
let cfg = config.nas-apps.nextcloud;
in {
imports = [
./options.nix
];
imports = [ ./options.nix ];
config = mkIf cfg.enable {
virtualisation.oci-containers.containers."${cfg.name}" = {
autoStart = cfg.autoStart;
image = cfg.image;
ports = [ "${cfg.httpPort}:80" "${cfg.httpsPort}:443" ];
volumes = [
"${cfg.configPath}:/config"
"${cfg.dataPath}:/data"
];
volumes = [ "${cfg.configPath}:/config" "${cfg.dataPath}:/data" ];
environment = {
PUID = cfg.puid;
PGID = cfg.pgid;
TZ = cfg.timeZone;
PUID = cfg.puid;
PGID = cfg.pgid;
TZ = cfg.timeZone;
};
};
};

View File

@@ -1,9 +1,8 @@
{ lib, ... }:
with lib;
{
with lib; {
options.nas-apps.nextcloud = {
enable = mkEnableOption "nextcloud docker service";
autoStart = mkOption {
type = types.bool;
default = true;
@@ -54,4 +53,4 @@ with lib;
default = "America/Chicago";
};
};
}
}

View File

@@ -1,11 +1,8 @@
{ lib, pkgs, config, ... }:
with lib;
let
cfg = config.nas-apps.radarr;
let cfg = config.nas-apps.radarr;
in {
imports = [
./options.nix
];
imports = [ ./options.nix ];
config = mkIf cfg.enable {
virtualisation.oci-containers.containers."${cfg.name}" = {
@@ -13,14 +10,14 @@ in {
image = cfg.image;
ports = [ "${cfg.port}:7878" ];
volumes = [
"${cfg.configPath}:/config"
"${cfg.moviesPath}:/movies"
"${cfg.downloadsPath}:/downloads"
"${cfg.configPath}:/config"
"${cfg.moviesPath}:/movies"
"${cfg.downloadsPath}:/downloads"
];
environment = {
PUID = cfg.puid;
PGID = cfg.pgid;
TZ = cfg.timeZone;
PUID = cfg.puid;
PGID = cfg.pgid;
TZ = cfg.timeZone;
};
};
};

View File

@@ -1,9 +1,8 @@
{ lib, ... }:
with lib;
{
with lib; {
options.nas-apps.radarr = {
enable = mkEnableOption "radarr docker service";
autoStart = mkOption {
type = types.bool;
default = true;

View File

@@ -1,11 +1,8 @@
{ lib, pkgs, config, ... }:
with lib;
let
cfg = config.nas-apps.sabnzbd;
let cfg = config.nas-apps.sabnzbd;
in {
imports = [
./options.nix
];
imports = [ ./options.nix ];
config = mkIf cfg.enable {
virtualisation.oci-containers.containers."${cfg.name}" = {
@@ -13,16 +10,16 @@ in {
image = cfg.image;
ports = [ "${cfg.port}:8080" ];
volumes = [
"${cfg.configPath}:/config"
"${cfg.moviesPath}:/movies"
"${cfg.tvPath}:/tv"
"${cfg.downloadsPath}:/downloads"
"${cfg.downloadsIncompletePath}:/downloads-incomplete"
"${cfg.configPath}:/config"
"${cfg.moviesPath}:/movies"
"${cfg.tvPath}:/tv"
"${cfg.downloadsPath}:/downloads"
"${cfg.downloadsIncompletePath}:/downloads-incomplete"
];
environment = {
PUID = cfg.puid;
PGID = cfg.pgid;
TZ = cfg.timeZone;
PUID = cfg.puid;
PGID = cfg.pgid;
TZ = cfg.timeZone;
};
};
};

View File

@@ -1,9 +1,8 @@
{ lib, ... }:
with lib;
{
with lib; {
options.nas-apps.sabnzbd = {
enable = mkEnableOption "sabnzbd docker service";
autoStart = mkOption {
type = types.bool;
default = true;

View File

@@ -1,11 +1,8 @@
{ lib, pkgs, config, ... }:
with lib;
let
cfg = config.nas-apps.sonarr;
let cfg = config.nas-apps.sonarr;
in {
imports = [
./options.nix
];
imports = [ ./options.nix ];
config = mkIf cfg.enable {
virtualisation.oci-containers.containers."${cfg.name}" = {
@@ -13,14 +10,14 @@ in {
image = cfg.image;
ports = [ "${cfg.port}:8989" ];
volumes = [
"${cfg.configPath}:/config"
"${cfg.tvPath}:/tv"
"${cfg.downloadsPath}:/downloads"
"${cfg.configPath}:/config"
"${cfg.tvPath}:/tv"
"${cfg.downloadsPath}:/downloads"
];
environment = {
PUID = cfg.puid;
PGID = cfg.pgid;
TZ = cfg.timeZone;
PUID = cfg.puid;
PGID = cfg.pgid;
TZ = cfg.timeZone;
};
};
};

View File

@@ -1,9 +1,8 @@
{lib, ... }:
with lib;
{
{ lib, ... }:
with lib; {
options.nas-apps.sonarr = {
enable = mkEnableOption "sonarr docker service";
autoStart = mkOption {
type = types.bool;
default = true;

View File

@@ -1,14 +1,11 @@
{ lib, pkgs, config, ... }:
with lib;
let
cfg = config.nas-apps.swag;
let cfg = config.nas-apps.swag;
in {
imports = [
./options.nix
];
imports = [ ./options.nix ];
config = mkIf cfg.enable {
networking.firewall = {
allowedTCPPorts = [ cfg.httpPort cfg.httpsPort ];
allowedUDPPorts = [ cfg.httpPort cfg.httpsPort ];
@@ -18,17 +15,15 @@ in {
autoStart = cfg.autoStart;
image = cfg.image;
ports = [ "${toString cfg.httpPort}:80" "${toString cfg.httpsPort}:443" ];
volumes = [
"${cfg.configPath}:/config"
];
volumes = [ "${cfg.configPath}:/config" ];
environment = {
PUID = cfg.puid;
PGID = cfg.pgid;
TZ = cfg.timeZone;
EMAIL = cfg.email;
URL = cfg.url;
VALIDATION = cfg.validation;
SUBDOMAINS = cfg.subdomains;
PUID = cfg.puid;
PGID = cfg.pgid;
TZ = cfg.timeZone;
EMAIL = cfg.email;
URL = cfg.url;
VALIDATION = cfg.validation;
SUBDOMAINS = cfg.subdomains;
};
};
};

View File

@@ -1,6 +1,5 @@
{lib, ... }:
with lib;
{
{ lib, ... }:
with lib; {
options.nas-apps.swag = {
enable = mkEnableOption "swag docker service";
@@ -13,7 +12,7 @@ with lib;
type = types.int;
default = 80;
};
httpsPort = mkOption {
type = types.int;
default = 443;