forked from aylac.top/nixcfg
this repo has no description

reorganised and disabled nvidia just to see something

Changed files
+1201 -668
hosts
modules
hardware
acer
aspire
A515-52G
home
desktop
gnome
nixos
desktop
gnome
profiles
arr
autoUpgrade
services
audiobookshelf
cloudflared
copyparty
couchdb
fail2ban
forgejo
glance
jellyfin
jellyseerr
karakeep
miniflux
ntfy
pds
qbittorrent
radicale
redlib
uptime-kuma
vaultwarden
webdav-server-rs
snippets
aylac-top
+18 -18
flake.lock
···
"nixpkgs": "nixpkgs"
},
"locked": {
-
"lastModified": 1755903555,
-
"narHash": "sha256-bxHqVgbAMcha/Xobz1v6QSySofwzrJEC7QES6naocvs=",
+
"lastModified": 1756071305,
+
"narHash": "sha256-X1Rs+GV5daPlu4waWuk+4G0LT3nSWySCjF2uzNhlOr4=",
"owner": "9001",
"repo": "copyparty",
-
"rev": "ad0e6c7fde1fc67a681ff1b69426b001c8b43b4b",
+
"rev": "abffda5474cd9309c53fa0736395221c7c43bec1",
"type": "github"
},
"original": {
···
]
},
"locked": {
-
"lastModified": 1755879220,
-
"narHash": "sha256-2KZl6cU5rzEwXKMW369kLTzinJXXkF3TRExA6qEeVbc=",
+
"lastModified": 1755960406,
+
"narHash": "sha256-RF7j6C1TmSTK9tYWO6CdEMtg6XZaUKcvZwOCD2SICZs=",
"owner": "cachix",
"repo": "git-hooks.nix",
-
"rev": "3ff4596663c8cbbffe06d863ee4c950bce2c3b78",
+
"rev": "e891a93b193fcaf2fc8012d890dc7f0befe86ec2",
"type": "github"
},
"original": {
···
]
},
"locked": {
-
"lastModified": 1755914636,
-
"narHash": "sha256-VJ+Gm6YsHlPfUCpmRQxvdiZW7H3YPSrdVOewQHAhZN8=",
+
"lastModified": 1756022458,
+
"narHash": "sha256-J1i35r4HfNDdPpwL0vOBaZopQudAUVtartEerc1Jryc=",
"owner": "nix-community",
"repo": "home-manager",
-
"rev": "8b55a6ac58b678199e5bba701aaff69e2b3281c0",
+
"rev": "9e3a33c0bcbc25619e540b9dfea372282f8a9740",
"type": "github"
},
"original": {
···
},
"nixpkgs-unstable": {
"locked": {
-
"lastModified": 1755736253,
-
"narHash": "sha256-jlIQRypNhB1PcB1BE+expE4xZeJxzoAGr1iUbHQta8s=",
+
"lastModified": 1755829505,
+
"narHash": "sha256-4/Jd+LkQ2ssw8luQVkqVs9spDBVE6h/u/hC/tzngsPo=",
"owner": "NixOS",
"repo": "nixpkgs",
-
"rev": "596312aae91421d6923f18cecce934a7d3bfd6b8",
+
"rev": "f937f8ecd1c70efd7e9f90ba13dfb400cf559de4",
"type": "github"
},
"original": {
···
"nixpkgs": "nixpkgs_4"
},
"locked": {
-
"lastModified": 1755918818,
-
"narHash": "sha256-a7k/fml8k4CxIcVW26luwqVl3lsRMNXBRCyC8uSF0GA=",
+
"lastModified": 1756071831,
+
"narHash": "sha256-ofdJDbiSzq0uOT7aLneiK6VQruXvbifrJ1Y8w1xmn/o=",
"owner": "nix-community",
"repo": "NUR",
-
"rev": "1a47d83c521c098debd6d1f2c2ae313a5bb729f9",
+
"rev": "4b342fb632bfbcc68ea9bc8f0c04df1ab4051f59",
"type": "github"
},
"original": {
···
]
},
"locked": {
-
"lastModified": 1755904687,
-
"narHash": "sha256-ABBEPeZ1oJYlWSahpxo5zgLC8L9aCcQdOZsZ5IiYFRI=",
+
"lastModified": 1756073902,
+
"narHash": "sha256-c+nkNP2iK4BtNL9fkSgjO/ZQstfJKE0G6hanuTtGtf8=",
"owner": "0xc000022070",
"repo": "zen-browser-flake",
-
"rev": "446073255a1097755b583291f5854204b57bbee2",
+
"rev": "7c096513336dbff12d5e11e352148a676d042820",
"type": "github"
},
"original": {
+6 -1
hosts/jezebel/default.nix
···
}: {
imports = [
./secrets.nix
-
./services.nix
self.nixosModules.locale-en-gb
"${modulesPath}/profiles/qemu-guest.nix"
self.diskoConfigurations.btrfs-vps
···
enable = true;
enableCaddy = true;
};
+
uptime-kuma.enable = true;
};
+
};
+
+
security.acme = {
+
acceptTerms = true;
+
defaults.email = "contact@aylac.top";
};
}
-39
hosts/jezebel/services.nix
···
-
{config, ...}: {
-
security.acme = {
-
acceptTerms = true;
-
defaults.email = "contact@aylac.top";
-
};
-
-
services = {
-
caddy = {
-
email = "contact@aylac.top";
-
-
virtualHosts = {
-
"${config.mySnippets.tailnet.networkMap.uptime-kuma.vHost}" = {
-
extraConfig = ''
-
bind tailscale/uptime-kuma
-
encode zstd gzip
-
reverse_proxy ${config.mySnippets.tailnet.networkMap.uptime-kuma.hostName}:${toString config.mySnippets.tailnet.networkMap.uptime-kuma.port}
-
'';
-
};
-
-
"${config.mySnippets.aylac-top.networkMap.uptime-kuma.vHost}" = {
-
extraConfig = ''
-
encode gzip zstd
-
reverse_proxy ${config.mySnippets.aylac-top.networkMap.uptime-kuma.hostName}:${toString config.mySnippets.aylac-top.networkMap.uptime-kuma.port}
-
'';
-
};
-
};
-
};
-
-
uptime-kuma = {
-
enable = true;
-
appriseSupport = true;
-
-
settings = {
-
PORT = toString config.mySnippets.aylac-top.networkMap.uptime-kuma.port;
-
HOST = "0.0.0.0";
-
};
-
};
-
};
-
}
+1
hosts/morgana/default.nix
···
autoUpgrade = {
enable = true;
+
allowReboot = false;
operation = "switch";
};
};
-1
hosts/morgana/secrets.nix
···
tailscaleAuthKey.file = "${self.inputs.secrets}/tailscale/auth.age";
syncthingCert.file = "${self.inputs.secrets}/ayla/syncthing/morgana/cert.age";
syncthingKey.file = "${self.inputs.secrets}/ayla/syncthing/morgana/key.age";
-
rclone.file = "${self.inputs.secrets}/rclone.age";
ntfyAuto.file = "${self.inputs.secrets}/ntfyAuto.age";
};
}
+22 -10
hosts/nanpi/default.nix
···
imports = [
./home.nix
./secrets.nix
-
./services.nix
-
./glance.nix
./notifier.nix
self.nixosModules.locale-en-gb
self.diskoConfigurations.luks-btrfs-subvolumes
···
profiles = {
base.enable = true;
server.enable = true;
-
#autoUpgrade = {
-
# enable = true;
-
# operation = "boot";
-
#};
+
autoUpgrade = {
+
enable = true;
+
operation = "boot";
+
allowReboot = false;
+
};
backups.enable = true;
btrfs = {
enable = true;
···
arr.enable = true;
};
services = {
+
audiobookshelf.enable = true;
caddy.enable = true;
+
cloudflared.enable = true;
+
copyparty.enable = true;
+
couchdb.enable = true;
dnsmasq.enable = true;
+
forgejo = {
+
enable = true;
+
db = "postgresql";
+
};
+
glance.enable = true;
+
jellyfin.enable = true;
+
karakeep.enable = true;
+
miniflux.enable = true;
+
ntfy.enable = true;
+
pds.enable = true;
tailscale = {
enable = true;
enableCaddy = true;
···
webuiPort = config.mySnippets.tailnet.networkMap.qbittorrent.port;
openFirewall = true;
};
-
forgejo = {
-
enable = true;
-
db = "postgresql";
-
};
+
radicale.enable = true;
+
redlib.enable = true;
+
webdav.enable = true;
};
};
-166
hosts/nanpi/glance.nix
···
-
{config, ...}: {
-
services.glance = {
-
enable = true;
-
openFirewall = true;
-
-
settings = {
-
pages = [
-
{
-
name = config.mySnippets.aylac-top.networkMap.glance.vHost;
-
width = "slim";
-
hide-desktop-navigation = true;
-
center-vertically = true;
-
columns = [
-
{
-
size = "full";
-
widgets = [
-
{
-
type = "monitor";
-
cache = "1m";
-
title = "Public Services";
-
-
sites = [
-
{
-
title = "Forgejo";
-
url = "https://${config.mySnippets.aylac-top.networkMap.forgejo.vHost}/";
-
check-url = "http://${config.mySnippets.aylac-top.networkMap.forgejo.hostName}:${toString config.mySnippets.aylac-top.networkMap.forgejo.port}/";
-
icon = "di:forgejo";
-
}
-
{
-
title = "PDS";
-
url = "https://${config.mySnippets.aylac-top.networkMap.pds.vHost}/";
-
check-url = "http://${config.mySnippets.aylac-top.networkMap.pds.hostName}:${toString config.mySnippets.aylac-top.networkMap.pds.port}/";
-
icon = "di:bluesky";
-
}
-
{
-
title = "Vaultwarden";
-
url = "https://${config.mySnippets.aylac-top.networkMap.vaultwarden.vHost}/";
-
check-url = "http://${config.mySnippets.aylac-top.networkMap.vaultwarden.hostName}:${toString config.mySnippets.aylac-top.networkMap.vaultwarden.port}/";
-
icon = "di:vaultwarden";
-
}
-
{
-
title = "ntfy";
-
url = "https://${config.mySnippets.aylac-top.networkMap.ntfy.vHost}/";
-
check-url = "http://${config.mySnippets.aylac-top.networkMap.ntfy.hostName}:${toString config.mySnippets.aylac-top.networkMap.ntfy.port}/";
-
icon = "di:ntfy";
-
}
-
];
-
}
-
{
-
type = "monitor";
-
cache = "1m";
-
title = "Private Services";
-
-
sites = [
-
{
-
title = "Karakeep";
-
url = "https://${config.mySnippets.tailnet.networkMap.karakeep.vHost}/";
-
check-url = "http://${config.mySnippets.tailnet.networkMap.karakeep.hostName}:${toString config.mySnippets.tailnet.networkMap.karakeep.port}/";
-
icon = "di:karakeep";
-
}
-
{
-
title = "Jellyfin";
-
url = "https://${config.mySnippets.tailnet.networkMap.jellyfin.vHost}/";
-
check-url = "http://${config.mySnippets.tailnet.networkMap.jellyfin.hostName}:${toString config.mySnippets.tailnet.networkMap.jellyfin.port}/web/index.html";
-
icon = "di:jellyfin";
-
}
-
{
-
title = "Jellyseerr";
-
url = "https://${config.mySnippets.tailnet.networkMap.jellyseerr.vHost}/";
-
check-url = "http://${config.mySnippets.tailnet.networkMap.jellyseerr.hostName}:${toString config.mySnippets.tailnet.networkMap.jellyseerr.port}/";
-
icon = "di:jellyseerr";
-
}
-
{
-
title = "Sonarr";
-
url = "https://${config.mySnippets.tailnet.networkMap.sonarr.vHost}/";
-
check-url = "http://${config.mySnippets.tailnet.networkMap.sonarr.hostName}:${toString config.mySnippets.tailnet.networkMap.sonarr.port}/";
-
icon = "di:sonarr";
-
}
-
{
-
title = "Radarr";
-
url = "https://${config.mySnippets.tailnet.networkMap.radarr.vHost}/";
-
check-url = "http://${config.mySnippets.tailnet.networkMap.radarr.hostName}:${toString config.mySnippets.tailnet.networkMap.radarr.port}/";
-
icon = "di:radarr";
-
}
-
#{
-
# title = "Lidarr";
-
# url = "https://${config.mySnippets.tailnet.networkMap.lidarr.vHost}/";
-
# check-url = "http://${config.mySnippets.tailnet.networkMap.lidarr.hostName}:${toString config.mySnippets.tailnet.networkMap.lidarr.port}/";
-
# icon = "di:lidarr";
-
#}
-
{
-
title = "Prowlarr";
-
url = "https://${config.mySnippets.tailnet.networkMap.prowlarr.vHost}/";
-
check-url = "http://${config.mySnippets.tailnet.networkMap.prowlarr.hostName}:${toString config.mySnippets.tailnet.networkMap.prowlarr.port}/";
-
icon = "di:prowlarr";
-
}
-
{
-
title = "Bazarr";
-
url = "https://${config.mySnippets.tailnet.networkMap.bazarr.vHost}/";
-
check-url = "http://${config.mySnippets.tailnet.networkMap.bazarr.hostName}:${toString config.mySnippets.tailnet.networkMap.bazarr.port}/";
-
icon = "di:bazarr";
-
}
-
{
-
title = "Autobrr";
-
url = "https://${config.mySnippets.tailnet.networkMap.autobrr.vHost}/";
-
check-url = "http://${config.mySnippets.tailnet.networkMap.autobrr.hostName}:${toString config.mySnippets.tailnet.networkMap.autobrr.port}/";
-
icon = "di:autobrr";
-
}
-
{
-
title = "qBittorrent";
-
url = "https://${config.mySnippets.tailnet.networkMap.qbittorrent.vHost}/";
-
check-url = "http://${config.mySnippets.tailnet.networkMap.qbittorrent.hostName}:${toString config.mySnippets.tailnet.networkMap.qbittorrent.port}/";
-
icon = "di:qbittorrent";
-
alt-status-codes = [401];
-
}
-
{
-
title = "Uptime Kuma";
-
url = "https://${config.mySnippets.tailnet.networkMap.uptime-kuma.vHost}/";
-
check-url = "http://${config.mySnippets.tailnet.networkMap.uptime-kuma.hostName}:${toString config.mySnippets.tailnet.networkMap.uptime-kuma.port}/";
-
icon = "di:uptime-kuma";
-
}
-
{
-
title = "Radicale";
-
url = "https://${config.mySnippets.tailnet.networkMap.radicale.vHost}/";
-
check-url = "http://${config.mySnippets.tailnet.networkMap.radicale.hostName}:${toString config.mySnippets.tailnet.networkMap.radicale.port}/";
-
icon = "di:radicale";
-
}
-
{
-
title = "Copyparty";
-
url = "https://${config.mySnippets.tailnet.networkMap.copyparty.vHost}/";
-
check-url = "http://${config.mySnippets.tailnet.networkMap.copyparty.hostName}:${toString config.mySnippets.tailnet.networkMap.copyparty.port}/";
-
icon = "di:copyparty";
-
}
-
{
-
title = "Redlib";
-
url = "https://${config.mySnippets.tailnet.networkMap.redlib.vHost}/";
-
check-url = "http://${config.mySnippets.tailnet.networkMap.redlib.hostName}:${toString config.mySnippets.tailnet.networkMap.redlib.port}/";
-
icon = "di:redlib";
-
}
-
{
-
title = "Miniflux";
-
url = "https://${config.mySnippets.tailnet.networkMap.miniflux.vHost}/";
-
check-url = "http://${config.mySnippets.tailnet.networkMap.miniflux.hostName}:${toString config.mySnippets.tailnet.networkMap.miniflux.port}/";
-
icon = "di:miniflux";
-
}
-
{
-
title = "audiobookshelf";
-
url = "https://${config.mySnippets.tailnet.networkMap.audiobookshelf.vHost}/";
-
check-url = "http://${config.mySnippets.tailnet.networkMap.audiobookshelf.hostName}:${toString config.mySnippets.tailnet.networkMap.audiobookshelf.port}/";
-
icon = "di:audiobookshelf";
-
}
-
];
-
}
-
];
-
}
-
];
-
}
-
];
-
-
server = {
-
host = "0.0.0.0";
-
inherit (config.mySnippets.tailnet.networkMap.glance) port;
-
};
-
};
-
};
-
}
-12
hosts/nanpi/secrets.nix
···
{self, ...}: {
age.secrets = {
-
cloudflareCertificate.file = "${self.inputs.secrets}/cloudflare/certificate.age";
-
cloudflareCredentials.file = "${self.inputs.secrets}/cloudflare/credentials.age";
pds.file = "${self.inputs.secrets}/pds.age";
resticPassword.file = "${self.inputs.secrets}/restic-passwd.age";
rclone.file = "${self.inputs.secrets}/rclone.age";
tailscaleAuthKey.file = "${self.inputs.secrets}/tailscale/auth.age";
syncthingCert.file = "${self.inputs.secrets}/ayla/syncthing/nanpi/cert.age";
syncthingKey.file = "${self.inputs.secrets}/ayla/syncthing/nanpi/key.age";
-
vaultwarden.file = "${self.inputs.secrets}/vaultwarden.age";
-
gemini.file = "${self.inputs.secrets}/gemini.age";
-
copyparty = {
-
file = "${self.inputs.secrets}/copyparty.age";
-
owner = "copyparty";
-
group = "copyparty";
-
mode = "0400";
-
};
-
autobrr.file = "${self.inputs.secrets}/autobrr.age";
ntfyAuto.file = "${self.inputs.secrets}/ntfyAuto.age";
-
miniflux.file = "${self.inputs.secrets}/miniflux.age";
};
}
-352
hosts/nanpi/services.nix
···
-
{
-
config,
-
pkgs,
-
...
-
}: let
-
dataDirectory = "/var/lib";
-
-
mkCaddyVHosts = services:
-
pkgs.lib.listToAttrs (map (service: let
-
netMap = config.mySnippets.${service.location or "tailnet"}.networkMap.${service.name};
-
flush = service.flushInterval or false;
-
proxyConfig =
-
if flush
-
then ''
-
reverse_proxy ${netMap.hostName}:${toString netMap.port} {
-
flush_interval -1
-
}
-
''
-
else "reverse_proxy ${netMap.hostName}:${toString netMap.port}";
-
in
-
pkgs.lib.nameValuePair "${netMap.vHost}" {
-
extraConfig = ''
-
bind tailscale/${service.name}
-
encode zstd gzip
-
${proxyConfig}
-
'';
-
})
-
services);
-
-
mkCloudflareIngress = services:
-
pkgs.lib.listToAttrs (map (service: let
-
netMap = config.mySnippets.${service.location or "aylac-top"}.networkMap.${service.name};
-
in
-
pkgs.lib.nameValuePair netMap.vHost "http://${netMap.hostName}:${toString netMap.port}")
-
services);
-
-
pdsHomePage = ''
-
hiii this is an ATProto PDS!! You will find my (ayla) account here!!
-
i should probably put some cool ass art in here or maybe an actual homepage
-
but having this by itself is fun
-
-
most API routes are under /xrpc/
-
'';
-
in {
-
services = {
-
cloudflared = {
-
enable = true;
-
certificateFile = config.age.secrets.cloudflareCertificate.path;
-
tunnels = {
-
"efe3d484-102d-4c58-bb17-ceaede4d7a4f" = {
-
certificateFile = config.age.secrets.cloudflareCertificate.path;
-
credentialsFile = config.age.secrets.cloudflareCredentials.path;
-
default = "http_status:404";
-
ingress =
-
mkCloudflareIngress [
-
{name = "forgejo";}
-
{name = "glance";}
-
{name = "ntfy";}
-
{name = "vaultwarden";}
-
]
-
// {
-
"${config.mySnippets.aylac-top.networkMap.pds.vHost}" = "http://${config.mySnippets.aylac-top.networkMap.pds.hostName}";
-
};
-
};
-
};
-
};
-
-
caddy.virtualHosts =
-
mkCaddyVHosts [
-
{name = "audiobookshelf";}
-
{name = "autobrr";}
-
{name = "bazarr";}
-
{name = "copyparty";}
-
{name = "couchdb";}
-
{name = "glance";}
-
{
-
name = "jellyfin";
-
flushInterval = true;
-
}
-
{name = "jellyseerr";}
-
{name = "karakeep";}
-
{name = "miniflux";}
-
{name = "prowlarr";}
-
{name = "qbittorrent";}
-
{name = "radarr";}
-
{name = "radicale";}
-
{name = "redlib";}
-
{name = "sonarr";}
-
{name = "webdav";}
-
]
-
// {
-
"http://${config.mySnippets.aylac-top.networkMap.pds.vHost}" = {
-
extraConfig = ''
-
encode zstd gzip
-
-
handle / {
-
respond "${pdsHomePage}"
-
}
-
-
handle /xrpc/app.bsky.unspecced.getAgeAssuranceState {
-
header content-type "application/json"
-
header access-control-allow-headers "authorization,dpop,atproto-accept-labelers,atproto-proxy"
-
header access-control-allow-origin "*"
-
respond `{"lastInitiatedAt":"2025-07-14T14:22:43.912Z","status":"assured"}` 200
-
}
-
-
handle {
-
reverse_proxy ${config.mySnippets.aylac-top.networkMap.pds.hostName}:${toString config.mySnippets.aylac-top.networkMap.pds.port}
-
}
-
'';
-
};
-
};
-
-
pds = {
-
enable = true;
-
environmentFiles = [config.age.secrets.pds.path];
-
pdsadmin.enable = true;
-
settings = {
-
PDS_HOSTNAME = config.mySnippets.aylac-top.networkMap.pds.vHost;
-
# PDS_BSKY_APP_VIEW_URL = "https://bsky.zeppelin.social";
-
# PDS_BSKY_APP_VIEW_DID = "did:web:bsky.zeppelin.social";
-
};
-
};
-
-
#immich = {
-
# enable = true;
-
# host = "0.0.0.0";
-
# mediaLocation = "${dataDirectory}/immich";
-
# openFirewall = true;
-
# inherit (config.mySnippets.tailnet.networkMap.immich) port;
-
#};
-
-
audiobookshelf = {
-
enable = true;
-
host = "0.0.0.0";
-
openFirewall = true;
-
inherit (config.mySnippets.tailnet.networkMap.audiobookshelf) port;
-
};
-
-
vaultwarden = {
-
enable = true;
-
-
config = {
-
DOMAIN = "https://${config.mySnippets.aylac-top.networkMap.vaultwarden.vHost}";
-
ROCKET_ADDRESS = "0.0.0.0";
-
ROCKET_LOG = "critical";
-
ROCKET_PORT = config.mySnippets.aylac-top.networkMap.vaultwarden.port;
-
SIGNUPS_ALLOWED = false;
-
ICON_SERVICE = "bitwarden";
-
ICON_CACHE_TTL = 0;
-
IP_HEADER = "CF-Connecting-IP";
-
};
-
-
environmentFile = config.age.secrets.vaultwarden.path;
-
};
-
-
jellyfin = {
-
enable = true;
-
openFirewall = true;
-
dataDir = "${dataDirectory}/jellyfin";
-
};
-
-
radicale = {
-
enable = true;
-
settings = {
-
server = {
-
hosts = ["0.0.0.0:${toString config.mySnippets.tailnet.networkMap.radicale.port}" "[::]:${toString config.mySnippets.tailnet.networkMap.radicale.port}"];
-
};
-
auth = {
-
type = "htpasswd";
-
htpasswd_filename = "/var/lib/radicale/users";
-
htpasswd_encryption = "autodetect";
-
};
-
storage = {
-
filesystem_folder = "/var/lib/radicale/collections";
-
};
-
};
-
};
-
-
redlib = {
-
enable = true;
-
openFirewall = true;
-
inherit (config.mySnippets.tailnet.networkMap.redlib) port;
-
settings = {
-
ENABLE_RSS = "on";
-
REDLIB_DEFAULT_SHOW_NSFW = "on";
-
REDLIB_DEFAULT_USE_HLS = "on";
-
FULL_URL = "https://${config.mySnippets.tailnet.networkMap.redlib.vHost}";
-
};
-
};
-
-
karakeep = {
-
enable = true;
-
-
extraEnvironment = rec {
-
DISABLE_NEW_RELEASE_CHECK = "true";
-
DISABLE_SIGNUPS = "true";
-
OPENAI_BASE_URL = "https://generativelanguage.googleapis.com/v1beta/openai/";
-
INFERENCE_TEXT_MODEL = "gemini-2.5-flash";
-
INFERENCE_IMAGE_MODEL = INFERENCE_TEXT_MODEL;
-
EMBEDDING_TEXT_MODEL = INFERENCE_TEXT_MODEL;
-
INFERENCE_CONTEXT_LENGTH = "600000";
-
INFERENCE_LANG = "english";
-
INFERENCE_NUM_WORKERS = "2";
-
NEXTAUTH_URL = "https://${config.mySnippets.tailnet.networkMap.karakeep.vHost}";
-
PORT = "7020";
-
};
-
environmentFile = config.age.secrets.gemini.path;
-
};
-
-
miniflux = {
-
enable = true;
-
adminCredentialsFile = config.age.secrets.miniflux.path;
-
config = {
-
BATCH_SIZE = 100;
-
CLEANUP_FREQUENCY_HOURS = 48;
-
LISTEN_ADDR = "${config.mySnippets.tailnet.networkMap.miniflux.hostName}:${toString config.mySnippets.tailnet.networkMap.miniflux.port}";
-
BASE_URL = "https://${config.mySnippets.tailnet.networkMap.miniflux.vHost}";
-
WEBAUTHN = "enabled";
-
};
-
};
-
-
ntfy-sh = {
-
enable = true;
-
user = "ntfy";
-
group = "ntfy";
-
settings = {
-
listen-http = ":${toString config.mySnippets.aylac-top.networkMap.ntfy.port}";
-
base-url = "https://${config.mySnippets.aylac-top.networkMap.ntfy.vHost}";
-
cache-duration = "30d";
-
cache-startup-queries = ''
-
pragma journal_mode = WAL;
-
pragma synchronous = normal;
-
pragma temp_store = memory;
-
'';
-
behind-proxy = true;
-
auth-default-access = "deny-all";
-
auth-users = [
-
"ayla:$2a$10$hh05DMOuVQ3Zf67Rn8VUl.HYUop/.90V04IhNPmOsSYh9FSHCbL1K:admin"
-
"auto:$2a$10$w7EDB/6orrpM9JVBqu4jHeBKvXliA4jvRI7Nd.fn.Fo4rGTHD50ju:user"
-
];
-
auth-access = [
-
"everyone:up*:wo"
-
"auto:*:wo"
-
"everyone:message-to-ayla:wo"
-
];
-
};
-
};
-
-
jellyseerr = {
-
enable = true;
-
inherit (config.mySnippets.tailnet.networkMap.jellyseerr) port;
-
openFirewall = true;
-
};
-
-
copyparty = {
-
enable = true;
-
settings = {
-
i = "0.0.0.0";
-
p = [config.mySnippets.tailnet.networkMap.copyparty.port (config.mySnippets.tailnet.networkMap.copyparty.port + 1)];
-
no-reload = true;
-
ignored-flag = false;
-
};
-
accounts = {
-
ayla = {
-
passwordFile = config.age.secrets.copyparty.path;
-
};
-
};
-
volumes = {
-
"/" = {
-
path = "/data/copyparty";
-
access = {
-
r = ["*"];
-
A = ["ayla"];
-
};
-
flags = {
-
fk = 4;
-
scan = 480;
-
};
-
};
-
};
-
};
-
-
webdav-server-rs = {
-
enable = true;
-
settings = {
-
server.listen = ["0.0.0.0:${toString config.mySnippets.tailnet.networkMap.webdav.port}" "[::]:${toString config.mySnippets.tailnet.networkMap.webdav.port}"];
-
accounts = {
-
auth-type = "htpasswd.default";
-
acct-type = "unix";
-
};
-
htpasswd.default = {
-
htpasswd = pkgs.writeText "htpasswd" ''
-
ayla:$2y$05$LD.VqJF.yVGsp.C3L6IJFO0SvYTeCKbGoGn70ZQaht4gxyEq2XbCS
-
'';
-
};
-
location = [
-
{
-
route = ["/*path"];
-
directory = "${dataDirectory}/webdav";
-
handler = "filesystem";
-
methods = ["webdav-rw"];
-
autoindex = true;
-
auth = "true";
-
}
-
];
-
};
-
};
-
-
couchdb = {
-
inherit (config.mySnippets.tailnet.networkMap.couchdb) port;
-
enable = true;
-
bindAddress = "0.0.0.0";
-
-
extraConfig = {
-
couchdb = {
-
single_node = true;
-
max_document_size = 50000000;
-
};
-
-
chttpd = {
-
require_valid_user = true;
-
max_http_request_size = 4294967296;
-
enable_cors = true;
-
};
-
-
chttpd_auth = {
-
require_valid_user = true;
-
authentication_redirect = "/_utils/session.html";
-
};
-
-
httpd = {
-
enable_cors = true;
-
"WWW-Authenticate" = "Basic realm=\"couchdb\"";
-
bind_address = "0.0.0.0";
-
};
-
-
cors = {
-
origins = "app://obsidian.md,capacitor://localhost,http://localhost";
-
credentials = true;
-
headers = "accept, authorization, content-type, origin, referer";
-
methods = "GET,PUT,POST,HEAD,DELETE";
-
max_age = 3600;
-
};
-
};
-
};
-
};
-
-
systemd.tmpfiles.rules = [
-
"d /var/lib/webdav 0755 webdav webdav - -"
-
];
-
}
+2 -1
modules/hardware/acer/aspire/A515-52G/default.nix
···
};
myHardware = {
-
nvidia.gpu.enable = true;
+
# disabled it to see if my laptop gets less hot
+
nvidia.gpu.enable = false;
intel = {
cpu.enable = true;
gpu.enable = true;
+2
modules/home/desktop/gnome/default.nix
···
gnome-tweaks
adw-gtk3
gnome-extension-manager
+
morewaita-icon-theme
+
nautilus-open-any-terminal
];
myHome.profiles.defaultApps = {
-1
modules/nixos/desktop/gnome/default.nix
···
services.gnome.gcr-ssh-agent.enable = true;
programs = {
-
nautilus-open-any-terminal.enable = true;
kdeconnect = {
enable = true;
package = pkgs.gnomeExtensions.gsconnect;
+63 -17
modules/nixos/profiles/arr/default.nix
···
{
config,
lib,
+
self,
...
-
}: {
+
}: let
+
cfg = config.myNixOS.profiles.arr;
+
+
netMap = config.mySnippets.tailnet.networkMap;
+
in {
options.myNixOS.profiles.arr = {
enable = lib.mkEnableOption "*arr services";
···
default = "/var/lib";
description = "The directory where *arr stores its data files.";
};
+
+
autoProxy = lib.mkOption {
+
default = true;
+
example = false;
+
description = "auto proxy the *arrs";
+
type = lib.types.bool;
+
};
};
config = lib.mkMerge [
-
(lib.mkIf config.myNixOS.profiles.arr.enable {
+
(lib.mkIf cfg.enable {
+
age.secrets.autobrr.file = "${self.inputs.secrets}/autobrr.age";
+
services = {
+
caddy.virtualHosts = lib.mkIf cfg.autoProxy {
+
"${netMap.autobrr.vHost}".extraConfig = ''
+
bind tailscale/autobrr
+
encode zstd gzip
+
reverse_proxy ${netMap.autobrr.hostName}:${toString netMap.autobrr.port}
+
'';
+
+
"${netMap.bazarr.vHost}".extraConfig = ''
+
bind tailscale/bazarr
+
encode zstd gzip
+
reverse_proxy ${netMap.bazarr.hostName}:${toString netMap.bazarr.port}
+
'';
+
+
"${netMap.prowlarr.vHost}".extraConfig = ''
+
bind tailscale/prowlarr
+
encode zstd gzip
+
reverse_proxy ${netMap.prowlarr.hostName}:${toString netMap.prowlarr.port}
+
'';
+
+
"${netMap.radarr.vHost}".extraConfig = ''
+
bind tailscale/radarr
+
encode zstd gzip
+
reverse_proxy ${netMap.radarr.hostName}:${toString netMap.radarr.port}
+
'';
+
+
"${netMap.sonarr.vHost}".extraConfig = ''
+
bind tailscale/sonarr
+
encode zstd gzip
+
reverse_proxy ${netMap.sonarr.hostName}:${toString netMap.sonarr.port}
+
'';
+
};
+
+
autobrr = {
+
enable = true;
+
openFirewall = true; # Port: 7474
+
secretFile = config.age.secrets.autobrr.path;
+
settings = {
+
host = "0.0.0.0";
+
port = 7474;
+
};
+
};
+
bazarr = {
enable = true;
-
dataDir = "${config.myNixOS.profiles.arr.dataDir}/bazarr";
+
dataDir = "${cfg.dataDir}/bazarr";
openFirewall = true; # Port: 6767
};
#lidarr = {
# enable = true;
-
# dataDir = "${config.myNixOS.profiles.arr.dataDir}/lidarr/.config/Lidarr";
+
# dataDir = "${cfg.dataDir}/lidarr/.config/Lidarr";
# openFirewall = true; # Port: 8686
#};
prowlarr = {
enable = true;
-
# dataDir = "${config.myNixOS.profiles.arr.dataDir}/prowlarr";
+
# dataDir = "${cfg.dataDir}/prowlarr";
openFirewall = true; # Port: 9696
};
radarr = {
enable = true;
-
dataDir = "${config.myNixOS.profiles.arr.dataDir}/radarr/.config/Radarr/";
+
dataDir = "${cfg.dataDir}/radarr/.config/Radarr/";
openFirewall = true; # Port: 7878
};
sonarr = {
enable = true;
-
dataDir = "${config.myNixOS.profiles.arr.dataDir}/sonarr/.config/NzbDrone/";
+
dataDir = "${cfg.dataDir}/sonarr/.config/NzbDrone/";
openFirewall = true; # Port: 8989
-
};
-
-
autobrr = {
-
enable = true;
-
openFirewall = true; # Port: 7474
-
secretFile = config.age.secrets.autobrr.path;
-
settings = {
-
host = "0.0.0.0";
-
port = 7474;
-
};
};
};
+7 -1
modules/nixos/profiles/autoUpgrade/default.nix
···
default = "boot";
description = "Operation to perform on auto-upgrade. Can be 'boot', 'switch', or 'test'.";
};
+
+
allowReboot = lib.mkOption {
+
type = lib.types.bool;
+
default = true;
+
description = "Allow auto-upgrade to reboot the system.";
+
};
};
config = lib.mkIf config.myNixOS.profiles.autoUpgrade.enable {
···
inherit (config.myNixOS.profiles.autoUpgrade) operation;
enable = true;
-
allowReboot = lib.mkDefault true;
+
inherit (config.myNixOS.profiles.autoUpgrade) allowReboot;
dates = "02:00";
flags = ["--accept-flake-config"];
flake = config.environment.variables.FLAKE or "github:ayla6/nixcfg";
+38
modules/nixos/services/audiobookshelf/default.nix
···
+
{
+
config,
+
lib,
+
...
+
}: let
+
name = "audiobookshelf";
+
cfg = config.myNixOS.services.${name};
+
+
network = config.mySnippets.tailnet;
+
service = network.networkMap.${name};
+
in {
+
options.myNixOS.services.${name} = {
+
enable = lib.mkEnableOption "${name} server";
+
autoProxy = lib.mkOption {
+
default = true;
+
example = false;
+
description = "${name} auto proxy";
+
type = lib.types.bool;
+
};
+
};
+
+
config = lib.mkIf cfg.enable {
+
services = {
+
caddy.virtualHosts."${service.vHost}".extraConfig = lib.mkIf cfg.autoProxy ''
+
bind tailscale/${name}
+
encode zstd gzip
+
reverse_proxy ${service.hostName}:${toString service.port}
+
'';
+
+
audiobookshelf = {
+
enable = true;
+
host = "0.0.0.0";
+
openFirewall = true;
+
inherit (service) port;
+
};
+
};
+
};
+
}
+27
modules/nixos/services/cloudflared/default.nix
···
+
{
+
config,
+
lib,
+
self,
+
...
+
}: {
+
options.myNixOS.services.cloudflared.enable = lib.mkEnableOption "Cloudflared for all your cloudflare tunnels needs";
+
+
config = lib.mkIf config.myNixOS.services.cloudflared.enable {
+
age.secrets = {
+
cloudflareCertificate.file = "${self.inputs.secrets}/cloudflare/certificate.age";
+
cloudflareCredentials.file = "${self.inputs.secrets}/cloudflare/credentials.age";
+
};
+
+
services.cloudflared = {
+
enable = true;
+
certificateFile = config.age.secrets.cloudflareCertificate.path;
+
tunnels = {
+
${config.mySnippets.aylac-top.cloudflareTunnel} = {
+
certificateFile = config.age.secrets.cloudflareCertificate.path;
+
credentialsFile = config.age.secrets.cloudflareCredentials.path;
+
default = "http_status:404";
+
};
+
};
+
};
+
};
+
}
+67
modules/nixos/services/copyparty/default.nix
···
+
{
+
config,
+
self,
+
lib,
+
...
+
}: let
+
name = "copyparty";
+
cfg = config.myNixOS.services.${name};
+
+
network = config.mySnippets.tailnet;
+
service = network.networkMap.${name};
+
in {
+
options.myNixOS.services.${name} = {
+
enable = lib.mkEnableOption "${name} server";
+
autoProxy = lib.mkOption {
+
default = true;
+
example = false;
+
description = "${name} auto proxy";
+
type = lib.types.bool;
+
};
+
};
+
+
config = lib.mkIf cfg.enable {
+
age.secrets.copyparty = {
+
file = "${self.inputs.secrets}/copyparty.age";
+
owner = "copyparty";
+
group = "copyparty";
+
mode = "0400";
+
};
+
+
services = {
+
caddy.virtualHosts."${service.vHost}".extraConfig = lib.mkIf cfg.autoProxy ''
+
bind tailscale/${name}
+
encode zstd gzip
+
reverse_proxy ${service.hostName}:${toString service.port}
+
'';
+
+
copyparty = {
+
enable = true;
+
settings = {
+
i = "0.0.0.0";
+
p = [service.port (service.port + 1)];
+
no-reload = true;
+
ignored-flag = false;
+
};
+
accounts = {
+
ayla = {
+
passwordFile = config.age.secrets.copyparty.path;
+
};
+
};
+
volumes = {
+
"/" = {
+
path = "/data/copyparty";
+
access = {
+
r = ["*"];
+
A = ["ayla"];
+
};
+
flags = {
+
fk = 4;
+
scan = 480;
+
};
+
};
+
};
+
};
+
};
+
};
+
}
+69
modules/nixos/services/couchdb/default.nix
···
+
{
+
config,
+
lib,
+
...
+
}: let
+
name = "couchdb";
+
cfg = config.myNixOS.services.${name};
+
+
network = config.mySnippets.tailnet;
+
service = network.networkMap.${name};
+
in {
+
options.myNixOS.services.${name} = {
+
enable = lib.mkEnableOption "${name} server";
+
autoProxy = lib.mkOption {
+
default = true;
+
example = false;
+
description = "${name} auto proxy";
+
type = lib.types.bool;
+
};
+
};
+
+
config = lib.mkIf cfg.enable {
+
services = {
+
caddy.virtualHosts."${service.vHost}".extraConfig = lib.mkIf cfg.autoProxy ''
+
bind tailscale/${name}
+
encode zstd gzip
+
reverse_proxy ${service.hostName}:${toString service.port}
+
'';
+
+
couchdb = {
+
inherit (service) port;
+
enable = true;
+
bindAddress = "0.0.0.0";
+
+
extraConfig = {
+
couchdb = {
+
single_node = true;
+
max_document_size = 50000000;
+
};
+
+
chttpd = {
+
require_valid_user = true;
+
max_http_request_size = 4294967296;
+
enable_cors = true;
+
};
+
+
chttpd_auth = {
+
require_valid_user = true;
+
authentication_redirect = "/_utils/session.html";
+
};
+
+
httpd = {
+
enable_cors = true;
+
"WWW-Authenticate" = "Basic realm=\"couchdb\"";
+
bind_address = "0.0.0.0";
+
};
+
+
cors = {
+
origins = "app://obsidian.md,capacitor://localhost,http://localhost";
+
credentials = true;
+
headers = "accept, authorization, content-type, origin, referer";
+
methods = "GET,PUT,POST,HEAD,DELETE";
+
max_age = 3600;
+
};
+
};
+
};
+
};
+
};
+
}
+17 -1
modules/nixos/services/default.nix
···
{...}: {
imports = [
+
./audiobookshelf
./aria2
+
./couchdb
+
./cloudflared
+
./copyparty
./caddy
./dnsmasq
./fail2ban
./forgejo
./gdm
+
./glance
+
./jellyfin
+
./jellyseerr
+
./karakeep
+
./miniflux
+
./monitoring
+
./ntfy
+
./pds
./qbittorrent
+
./radicale
+
./redlib
./syncthing
./tailscale
-
./monitoring
+
./uptime-kuma
+
./vaultwarden
+
./webdav-server-rs
];
}
+5 -1
modules/nixos/services/fail2ban/default.nix
···
options.myNixOS.services.fail2ban.enable = lib.mkEnableOption "fail2ban";
config = lib.mkIf config.myNixOS.services.fail2ban.enable {
+
age.secrets = {
+
cloudflareFail2ban.file = "${self.inputs.secrets}/cloudflare/fail2ban.age";
+
};
+
environment.etc = {
"fail2ban/action.d/mycloudflare.conf" = {
user = "root";
group = "root";
mode = "0640";
-
source = "${self.inputs.secrets}/cloudflare/fail2ban.age";
+
source = config.age.secrets.cloudflareFail2ban.path;
};
"fail2ban/action.d/ntfy.conf".text = ''
+27 -12
modules/nixos/services/forgejo/default.nix
···
pkgs,
self,
...
-
}: {
+
}: let
+
name = "forgejo";
+
cfg = config.myNixOS.services.${name};
+
+
network = config.mySnippets.aylac-top;
+
service = network.networkMap.${name};
+
in {
options.myNixOS.services.forgejo = {
-
enable = lib.mkEnableOption "forĝejo git forge";
+
enable = lib.mkEnableOption "forgejo git forge";
db = lib.mkOption {
description = "Database to use (sqlite or postgresql).";
default = "sqlite";
type = lib.types.str;
};
+
+
autoProxy = lib.mkOption {
+
default = true;
+
example = false;
+
description = "${name} auto proxy";
+
type = lib.types.bool;
+
};
};
-
config = lib.mkIf config.myNixOS.services.forgejo.enable {
-
age.secrets = {
-
postgres-forgejo.file = "${self.inputs.secrets}/postgres/forgejo.age";
-
};
+
config = lib.mkIf cfg.enable {
+
age.secrets.forgejo.file = "${self.inputs.secrets}/postgres/forgejo.age";
services = {
-
postgresql = lib.mkIf (config.myNixOS.services.forgejo.db
+
cloudflared.tunnels."${network.cloudflareTunnel}".ingress = lib.mkIf cfg.autoProxy {
+
"${service.vHost}" = "http://${service.hostName}:${toString service.port}";
+
};
+
+
postgresql = lib.mkIf (cfg.db
== "postgresql") {
enable = true;
package = pkgs.postgresql_16;
···
forgejo = {
enable = true;
-
database = lib.mkIf (config.myNixOS.services.forgejo.db
+
database = lib.mkIf (cfg.db
== "postgresql") {
createDatabase = true;
host = "127.0.0.1";
name = "forgejo";
-
passwordFile = config.age.secrets.postgres-forgejo.path;
+
passwordFile = config.age.secrets.forgejo.path;
type = "postgres";
user = "forgejo";
};
···
security.PASSWORD_CHECK_PWN = true;
server = {
-
DOMAIN = config.mySnippets.aylac-top.networkMap.forgejo.vHost;
-
HTTP_PORT = config.mySnippets.aylac-top.networkMap.forgejo.port;
+
DOMAIN = service.vHost;
+
HTTP_PORT = service.port;
LANDING_PAGE = "explore";
LFS_START_SERVER = true;
-
ROOT_URL = "https://${config.mySnippets.aylac-top.networkMap.forgejo.vHost}/";
+
ROOT_URL = "https://${service.vHost}/";
DISABLE_SSH = true;
};
+203
modules/nixos/services/glance/default.nix
···
+
{
+
config,
+
lib,
+
...
+
}: let
+
name = "glance";
+
cfg = config.myNixOS.services.${name};
+
+
inherit (config.mySnippets) aylac-top;
+
inherit (config.mySnippets) tailnet;
+
+
publicNetwork = aylac-top;
+
privateNetwork = tailnet;
+
in {
+
options.myNixOS.services.${name} = {
+
enable = lib.mkEnableOption "${name} server";
+
autoProxy = lib.mkOption {
+
default = true;
+
example = false;
+
description = "${name} auto proxy";
+
type = lib.types.bool;
+
};
+
};
+
+
config = lib.mkIf cfg.enable {
+
services = {
+
caddy.virtualHosts."${privateNetwork.networkMap.${name}.vHost}".extraConfig = lib.mkIf cfg.autoProxy ''
+
bind tailscale/${name}
+
encode zstd gzip
+
reverse_proxy ${privateNetwork.networkMap.${name}.hostName}:${toString privateNetwork.networkMap.${name}.port}
+
'';
+
+
cloudflared.tunnels."${publicNetwork.cloudflareTunnel}".ingress = lib.mkIf cfg.autoProxy {
+
"${publicNetwork.networkMap.pds.vHost}" = "http://${publicNetwork.networkMap.pds.hostName}";
+
};
+
+
glance = {
+
enable = true;
+
openFirewall = true;
+
+
settings = {
+
pages = [
+
{
+
name = publicNetwork.networkMap.glance.vHost;
+
width = "slim";
+
hide-desktop-navigation = true;
+
center-vertically = true;
+
columns = [
+
{
+
size = "full";
+
widgets = [
+
{
+
type = "monitor";
+
cache = "1m";
+
title = "Public Services";
+
+
sites = [
+
{
+
title = "Forgejo";
+
url = "https://${aylac-top.networkMap.forgejo.vHost}/";
+
check-url = "http://${aylac-top.networkMap.forgejo.hostName}:${toString aylac-top.networkMap.forgejo.port}/";
+
icon = "di:forgejo";
+
}
+
{
+
title = "PDS";
+
url = "https://${aylac-top.networkMap.pds.vHost}/";
+
check-url = "http://${aylac-top.networkMap.pds.hostName}:${toString aylac-top.networkMap.pds.port}/";
+
icon = "di:bluesky";
+
}
+
{
+
title = "Vaultwarden";
+
url = "https://${aylac-top.networkMap.vaultwarden.vHost}/";
+
check-url = "http://${aylac-top.networkMap.vaultwarden.hostName}:${toString aylac-top.networkMap.vaultwarden.port}/";
+
icon = "di:vaultwarden";
+
}
+
{
+
title = "ntfy";
+
url = "https://${aylac-top.networkMap.ntfy.vHost}/";
+
check-url = "http://${aylac-top.networkMap.ntfy.hostName}:${toString aylac-top.networkMap.ntfy.port}/";
+
icon = "di:ntfy";
+
}
+
];
+
}
+
{
+
type = "monitor";
+
cache = "1m";
+
title = "Private Services";
+
+
sites = [
+
{
+
title = "Karakeep";
+
url = "https://${tailnet.networkMap.karakeep.vHost}/";
+
check-url = "http://${tailnet.networkMap.karakeep.hostName}:${toString tailnet.networkMap.karakeep.port}/";
+
icon = "di:karakeep";
+
}
+
{
+
title = "Jellyfin";
+
url = "https://${tailnet.networkMap.jellyfin.vHost}/";
+
check-url = "http://${tailnet.networkMap.jellyfin.hostName}:${toString tailnet.networkMap.jellyfin.port}/web/index.html";
+
icon = "di:jellyfin";
+
}
+
{
+
title = "Jellyseerr";
+
url = "https://${tailnet.networkMap.jellyseerr.vHost}/";
+
check-url = "http://${tailnet.networkMap.jellyseerr.hostName}:${toString tailnet.networkMap.jellyseerr.port}/";
+
icon = "di:jellyseerr";
+
}
+
{
+
title = "Sonarr";
+
url = "https://${tailnet.networkMap.sonarr.vHost}/";
+
check-url = "http://${tailnet.networkMap.sonarr.hostName}:${toString tailnet.networkMap.sonarr.port}/";
+
icon = "di:sonarr";
+
}
+
{
+
title = "Radarr";
+
url = "https://${tailnet.networkMap.radarr.vHost}/";
+
check-url = "http://${tailnet.networkMap.radarr.hostName}:${toString tailnet.networkMap.radarr.port}/";
+
icon = "di:radarr";
+
}
+
#{
+
# title = "Lidarr";
+
# url = "https://${tailnet.networkMap.lidarr.vHost}/";
+
# check-url = "http://${tailnet.networkMap.lidarr.hostName}:${toString tailnet.networkMap.lidarr.port}/";
+
# icon = "di:lidarr";
+
#}
+
{
+
title = "Prowlarr";
+
url = "https://${tailnet.networkMap.prowlarr.vHost}/";
+
check-url = "http://${tailnet.networkMap.prowlarr.hostName}:${toString tailnet.networkMap.prowlarr.port}/";
+
icon = "di:prowlarr";
+
}
+
{
+
title = "Bazarr";
+
url = "https://${tailnet.networkMap.bazarr.vHost}/";
+
check-url = "http://${tailnet.networkMap.bazarr.hostName}:${toString tailnet.networkMap.bazarr.port}/";
+
icon = "di:bazarr";
+
}
+
{
+
title = "Autobrr";
+
url = "https://${tailnet.networkMap.autobrr.vHost}/";
+
check-url = "http://${tailnet.networkMap.autobrr.hostName}:${toString tailnet.networkMap.autobrr.port}/";
+
icon = "di:autobrr";
+
}
+
{
+
title = "qBittorrent";
+
url = "https://${tailnet.networkMap.qbittorrent.vHost}/";
+
check-url = "http://${tailnet.networkMap.qbittorrent.hostName}:${toString tailnet.networkMap.qbittorrent.port}/";
+
icon = "di:qbittorrent";
+
alt-status-codes = [401];
+
}
+
{
+
title = "Uptime Kuma";
+
url = "https://${tailnet.networkMap.uptime-kuma.vHost}/";
+
check-url = "http://${tailnet.networkMap.uptime-kuma.hostName}:${toString tailnet.networkMap.uptime-kuma.port}/";
+
icon = "di:uptime-kuma";
+
}
+
{
+
title = "Radicale";
+
url = "https://${tailnet.networkMap.radicale.vHost}/";
+
check-url = "http://${tailnet.networkMap.radicale.hostName}:${toString tailnet.networkMap.radicale.port}/";
+
icon = "di:radicale";
+
}
+
{
+
title = "Copyparty";
+
url = "https://${tailnet.networkMap.copyparty.vHost}/";
+
check-url = "http://${tailnet.networkMap.copyparty.hostName}:${toString tailnet.networkMap.copyparty.port}/";
+
icon = "di:copyparty";
+
}
+
{
+
title = "Redlib";
+
url = "https://${tailnet.networkMap.redlib.vHost}/";
+
check-url = "http://${tailnet.networkMap.redlib.hostName}:${toString tailnet.networkMap.redlib.port}/";
+
icon = "di:redlib";
+
}
+
{
+
title = "Miniflux";
+
url = "https://${tailnet.networkMap.miniflux.vHost}/";
+
check-url = "http://${tailnet.networkMap.miniflux.hostName}:${toString tailnet.networkMap.miniflux.port}/";
+
icon = "di:miniflux";
+
}
+
{
+
title = "audiobookshelf";
+
url = "https://${tailnet.networkMap.audiobookshelf.vHost}/";
+
check-url = "http://${tailnet.networkMap.audiobookshelf.hostName}:${toString tailnet.networkMap.audiobookshelf.port}/";
+
icon = "di:audiobookshelf";
+
}
+
];
+
}
+
];
+
}
+
];
+
}
+
];
+
+
server = {
+
host = "0.0.0.0";
+
inherit (tailnet.networkMap.glance) port;
+
};
+
};
+
};
+
};
+
};
+
}
+41
modules/nixos/services/jellyfin/default.nix
···
+
{
+
config,
+
lib,
+
...
+
}: let
+
name = "jellyfin";
+
cfg = config.myNixOS.services.${name};
+
+
network = config.mySnippets.tailnet;
+
service = network.networkMap.${name};
+
+
dataDirectory = "/var/lib";
+
in {
+
options.myNixOS.services.${name} = {
+
enable = lib.mkEnableOption "${name} server";
+
autoProxy = lib.mkOption {
+
default = true;
+
example = false;
+
description = "${name} auto proxy";
+
type = lib.types.bool;
+
};
+
};
+
+
config = lib.mkIf cfg.enable {
+
services = {
+
caddy.virtualHosts."${service.vHost}".extraConfig = lib.mkIf cfg.autoProxy ''
+
bind tailscale/${name}
+
encode zstd gzip
+
reverse_proxy ${service.hostName}:${toString service.port} {
+
flush_interval -1
+
}
+
'';
+
+
jellyfin = {
+
enable = true;
+
openFirewall = true;
+
dataDir = "${dataDirectory}/jellyfin";
+
};
+
};
+
};
+
}
+37
modules/nixos/services/jellyseerr/default.nix
···
+
{
+
config,
+
lib,
+
...
+
}: let
+
name = "jellyseerr";
+
cfg = config.myNixOS.services.${name};
+
+
network = config.mySnippets.tailnet;
+
service = network.networkMap.${name};
+
in {
+
options.myNixOS.services.${name} = {
+
enable = lib.mkEnableOption "${name} server";
+
autoProxy = lib.mkOption {
+
default = true;
+
example = false;
+
description = "${name} auto proxy";
+
type = lib.types.bool;
+
};
+
};
+
+
config = lib.mkIf cfg.enable {
+
services = {
+
caddy.virtualHosts."${service.vHost}".extraConfig = lib.mkIf cfg.autoProxy ''
+
bind tailscale/${name}
+
encode zstd gzip
+
reverse_proxy ${service.hostName}:${toString service.port}
+
'';
+
+
jellyseerr = {
+
enable = true;
+
inherit (service) port;
+
openFirewall = true;
+
};
+
};
+
};
+
}
+53
modules/nixos/services/karakeep/default.nix
···
+
{
+
config,
+
lib,
+
self,
+
...
+
}: let
+
name = "karakeep";
+
cfg = config.myNixOS.services.${name};
+
+
network = config.mySnippets.tailnet;
+
service = network.networkMap.${name};
+
in {
+
options.myNixOS.services.${name} = {
+
enable = lib.mkEnableOption "${name} server";
+
autoProxy = lib.mkOption {
+
default = true;
+
example = false;
+
description = "${name} auto proxy";
+
type = lib.types.bool;
+
};
+
};
+
+
config = lib.mkIf cfg.enable {
+
age.secrets.gemini.file = "${self.inputs.secrets}/gemini.age";
+
+
services = {
+
caddy.virtualHosts."${service.vHost}".extraConfig = lib.mkIf cfg.autoProxy ''
+
bind tailscale/${name}
+
encode zstd gzip
+
reverse_proxy ${service.hostName}:${toString service.port}
+
'';
+
+
karakeep = {
+
enable = true;
+
+
extraEnvironment = rec {
+
DISABLE_NEW_RELEASE_CHECK = "true";
+
DISABLE_SIGNUPS = "true";
+
OPENAI_BASE_URL = "https://generativelanguage.googleapis.com/v1beta/openai/";
+
INFERENCE_TEXT_MODEL = "gemini-2.5-flash";
+
INFERENCE_IMAGE_MODEL = INFERENCE_TEXT_MODEL;
+
EMBEDDING_TEXT_MODEL = INFERENCE_TEXT_MODEL;
+
INFERENCE_CONTEXT_LENGTH = "600000";
+
INFERENCE_LANG = "english";
+
INFERENCE_NUM_WORKERS = "2";
+
NEXTAUTH_URL = "https://${service.vHost}";
+
PORT = "7020";
+
};
+
environmentFile = config.age.secrets.gemini.path;
+
};
+
};
+
};
+
}
+46
modules/nixos/services/miniflux/default.nix
···
+
{
+
config,
+
lib,
+
self,
+
...
+
}: let
+
name = "miniflux";
+
cfg = config.myNixOS.services.${name};
+
+
network = config.mySnippets.tailnet;
+
service = network.networkMap.${name};
+
in {
+
options.myNixOS.services.${name} = {
+
enable = lib.mkEnableOption "${name} server";
+
autoProxy = lib.mkOption {
+
default = true;
+
example = false;
+
description = "${name} auto proxy";
+
type = lib.types.bool;
+
};
+
};
+
+
config = lib.mkIf cfg.enable {
+
age.secrets.miniflux.file = "${self.inputs.secrets}/miniflux.age";
+
+
services = {
+
caddy.virtualHosts."${service.vHost}".extraConfig = lib.mkIf cfg.autoProxy ''
+
bind tailscale/${name}
+
encode zstd gzip
+
reverse_proxy ${service.hostName}:${toString service.port}
+
'';
+
+
miniflux = {
+
enable = true;
+
adminCredentialsFile = config.age.secrets.miniflux.path;
+
config = {
+
BATCH_SIZE = 100;
+
CLEANUP_FREQUENCY_HOURS = 48;
+
LISTEN_ADDR = "${service.hostName}:${toString service.port}";
+
BASE_URL = "https://${service.vHost}";
+
WEBAUTHN = "enabled";
+
};
+
};
+
};
+
};
+
}
+56
modules/nixos/services/ntfy/default.nix
···
+
{
+
config,
+
lib,
+
...
+
}: let
+
name = "ntfy";
+
cfg = config.myNixOS.services.${name};
+
+
network = config.mySnippets.aylac-top;
+
service = network.networkMap.${name};
+
in {
+
options.myNixOS.services.${name} = {
+
enable = lib.mkEnableOption "${name} server";
+
autoProxy = lib.mkOption {
+
default = true;
+
example = false;
+
description = "${name} auto proxy";
+
type = lib.types.bool;
+
};
+
};
+
+
config = lib.mkIf cfg.enable {
+
services = {
+
cloudflared.tunnels."${network.cloudflareTunnel}".ingress = lib.mkIf cfg.autoProxy {
+
"${service.vHost}" = "http://${service.hostName}:${toString service.port}";
+
};
+
+
ntfy-sh = {
+
enable = true;
+
user = "ntfy";
+
group = "ntfy";
+
settings = {
+
listen-http = ":${toString service.port}";
+
base-url = "https://${service.vHost}";
+
cache-duration = "30d";
+
cache-startup-queries = ''
+
pragma journal_mode = WAL;
+
pragma synchronous = normal;
+
pragma temp_store = memory;
+
'';
+
behind-proxy = true;
+
auth-default-access = "deny-all";
+
auth-users = [
+
"ayla:$2a$10$hh05DMOuVQ3Zf67Rn8VUl.HYUop/.90V04IhNPmOsSYh9FSHCbL1K:admin"
+
"auto:$2a$10$w7EDB/6orrpM9JVBqu4jHeBKvXliA4jvRI7Nd.fn.Fo4rGTHD50ju:user"
+
];
+
auth-access = [
+
"everyone:up*:wo"
+
"auto:*:wo"
+
"everyone:message-to-ayla:wo"
+
];
+
};
+
};
+
};
+
};
+
}
+67
modules/nixos/services/pds/default.nix
···
+
{
+
config,
+
lib,
+
...
+
}: let
+
name = "pds";
+
cfg = config.myNixOS.services.${name};
+
+
network = config.mySnippets.aylac-top;
+
service = network.networkMap.${name};
+
+
pdsHomePage = ''
+
hiii this is an ATProto PDS!! You will find my (ayla) account here!!
+
i should probably put some cool ass art in here or maybe an actual homepage
+
but having this by itself is fun
+
+
most API routes are under /xrpc/
+
'';
+
in {
+
options.myNixOS.services.${name} = {
+
enable = lib.mkEnableOption "atproto pds";
+
autoProxy = lib.mkOption {
+
default = true;
+
example = false;
+
description = "${name} auto proxy";
+
type = lib.types.bool;
+
};
+
};
+
+
config = lib.mkIf cfg.enable {
+
services = {
+
cloudflared.tunnels."${network.cloudflareTunnel}".ingress = lib.mkIf cfg.autoProxy {
+
"${service.vHost}" = "http://${service.hostName}";
+
};
+
+
caddy.virtualHosts."http://${service.vHost}".extraConfig = lib.mkIf cfg.autoProxy ''
+
encode zstd gzip
+
+
handle / {
+
respond "${pdsHomePage}"
+
}
+
+
handle /xrpc/app.bsky.unspecced.getAgeAssuranceState {
+
header content-type "application/json"
+
header access-control-allow-headers "authorization,dpop,atproto-accept-labelers,atproto-proxy"
+
header access-control-allow-origin "*"
+
respond `{"lastInitiatedAt":"2025-07-14T14:22:43.912Z","status":"assured"}` 200
+
}
+
+
handle {
+
reverse_proxy ${service.hostName}:${toString service.port}
+
}
+
'';
+
+
pds = {
+
enable = true;
+
environmentFiles = [config.age.secrets.pds.path];
+
pdsadmin.enable = true;
+
settings = {
+
PDS_HOSTNAME = service.vHost;
+
# PDS_BSKY_APP_VIEW_URL = "https://bsky.zeppelin.social";
+
# PDS_BSKY_APP_VIEW_DID = "did:web:bsky.zeppelin.social";
+
};
+
};
+
};
+
};
+
}
+18 -1
modules/nixos/services/qbittorrent/default.nix
···
utils,
...
}: let
-
cfg = config.myNixOS.services.qbittorrent;
+
name = "qbittorrent";
+
cfg = config.myNixOS.services.${name};
+
+
network = config.mySnippets.tailnet;
+
service = network.networkMap.${name};
in {
options.myNixOS.services.qbittorrent = {
enable = lib.mkEnableOption "qBittorrent headless";
···
"--confirm-legal-notice"
];
};
+
+
autoProxy = lib.mkOption {
+
default = true;
+
example = false;
+
description = "${name} auto proxy";
+
type = lib.types.bool;
+
};
};
config = lib.mkIf cfg.enable {
···
lib.optionals (cfg.webuiPort != null) [cfg.webuiPort]
++ lib.optionals (cfg.torrentingPort != null) [cfg.torrentingPort]
);
+
+
services.caddy.virtualHosts."${service.vHost}".extraConfig = lib.mkIf cfg.autoProxy ''
+
bind tailscale/${name}
+
encode zstd gzip
+
reverse_proxy ${service.hostName}:${toString service.port}
+
'';
systemd.services.qbittorrent = {
after = ["local-fs.target" "network-online.target"];
+48
modules/nixos/services/radicale/default.nix
···
+
{
+
config,
+
lib,
+
...
+
}: let
+
name = "radicale";
+
cfg = config.myNixOS.services.${name};
+
+
network = config.mySnippets.tailnet;
+
service = network.networkMap.${name};
+
in {
+
options.myNixOS.services.${name} = {
+
enable = lib.mkEnableOption "${name} server";
+
autoProxy = lib.mkOption {
+
default = true;
+
example = false;
+
description = "${name} auto proxy";
+
type = lib.types.bool;
+
};
+
};
+
+
config = lib.mkIf cfg.enable {
+
services = {
+
caddy.virtualHosts."${service.vHost}".extraConfig = lib.mkIf cfg.autoProxy ''
+
bind tailscale/${name}
+
encode zstd gzip
+
reverse_proxy ${service.hostName}:${toString service.port}
+
'';
+
+
radicale = {
+
enable = true;
+
settings = {
+
server = {
+
hosts = ["0.0.0.0:${toString service.port}" "[::]:${toString service.port}"];
+
};
+
auth = {
+
type = "htpasswd";
+
htpasswd_filename = "/var/lib/radicale/users";
+
htpasswd_encryption = "autodetect";
+
};
+
storage = {
+
filesystem_folder = "/var/lib/radicale/collections";
+
};
+
};
+
};
+
};
+
};
+
}
+43
modules/nixos/services/redlib/default.nix
···
+
{
+
config,
+
lib,
+
...
+
}: let
+
name = "redlib";
+
cfg = config.myNixOS.services.${name};
+
+
network = config.mySnippets.tailnet;
+
service = network.networkMap.${name};
+
in {
+
options.myNixOS.services.${name} = {
+
enable = lib.mkEnableOption "${name} server";
+
autoProxy = lib.mkOption {
+
default = true;
+
example = false;
+
description = "${name} auto proxy";
+
type = lib.types.bool;
+
};
+
};
+
+
config = lib.mkIf cfg.enable {
+
services = {
+
caddy.virtualHosts."${service.vHost}".extraConfig = lib.mkIf cfg.autoProxy ''
+
bind tailscale/${name}
+
encode zstd gzip
+
reverse_proxy ${service.hostName}:${toString service.port}
+
'';
+
+
redlib = {
+
enable = true;
+
openFirewall = true;
+
inherit (service) port;
+
settings = {
+
ENABLE_RSS = "on";
+
REDLIB_DEFAULT_SHOW_NSFW = "on";
+
REDLIB_DEFAULT_USE_HLS = "on";
+
FULL_URL = "https://${service.vHost}";
+
};
+
};
+
};
+
};
+
}
+63
modules/nixos/services/uptime-kuma/default.nix
···
+
{
+
config,
+
lib,
+
...
+
}: let
+
name = "uptime-kuma";
+
cfg = config.myNixOS.services.${name};
+
+
inherit (config.mySnippets) aylac-top;
+
inherit (config.mySnippets) tailnet;
+
+
publicNetwork = aylac-top;
+
privateNetwork = tailnet;
+
in {
+
options.myNixOS.services.${name} = {
+
enable = lib.mkEnableOption "${name} server";
+
autoProxy = lib.mkOption {
+
default = true;
+
example = false;
+
description = "${name} auto proxy";
+
type = lib.types.bool;
+
};
+
publicProxy = lib.mkOption {
+
default = "caddy";
+
example = "cf";
+
description = "Public proxy provider for ${name}";
+
type = lib.types.enum ["none" "cf" "caddy"];
+
};
+
};
+
+
config = lib.mkIf cfg.enable {
+
services = {
+
caddy.virtualHosts = {
+
"${privateNetwork.networkMap.${name}.vHost}".extraConfig = lib.mkIf cfg.autoProxy ''
+
bind tailscale/${name}
+
encode zstd gzip
+
reverse_proxy ${privateNetwork.networkMap.${name}.hostName}:${toString privateNetwork.networkMap.${name}.port}
+
'';
+
+
"${publicNetwork.networkMap.${name}.vHost}" = lib.mkIf (cfg.publicProxy == "caddy") {
+
extraConfig = ''
+
encode gzip zstd
+
reverse_proxy ${publicNetwork.networkMap.${name}.hostName}:${toString publicNetwork.networkMap.${name}.port}
+
'';
+
};
+
};
+
+
cloudflared.tunnels."${publicNetwork.cloudflareTunnel}".ingress = lib.mkIf (cfg.publicProxy == "cf") {
+
"${publicNetwork.networkMap.pds.vHost}" = "http://${publicNetwork.networkMap.pds.hostName}";
+
};
+
+
uptime-kuma = {
+
enable = true;
+
appriseSupport = true;
+
+
settings = {
+
PORT = toString publicNetwork.networkMap.${name}.port;
+
HOST = "0.0.0.0";
+
};
+
};
+
};
+
};
+
}
+49
modules/nixos/services/vaultwarden/default.nix
···
+
{
+
config,
+
lib,
+
self,
+
...
+
}: let
+
name = "vaultwarden";
+
cfg = config.myNixOS.services.${name};
+
+
network = config.mySnippets.aylac-top;
+
service = network.networkMap.${name};
+
in {
+
options.myNixOS.services.${name} = {
+
enable = lib.mkEnableOption "${name} server";
+
autoProxy = lib.mkOption {
+
default = true;
+
example = false;
+
description = "${name} auto proxy";
+
type = lib.types.bool;
+
};
+
};
+
+
config = lib.mkIf cfg.enable {
+
age.secrets.vaultwarden.file = "${self.inputs.secrets}/vaultwarden.age";
+
+
services = {
+
cloudflared.tunnels."${network.cloudflareTunnel}".ingress = lib.mkIf cfg.autoProxy {
+
"${service.vHost}" = "http://${service.hostName}:${toString service.port}";
+
};
+
+
vaultwarden = {
+
enable = true;
+
+
config = {
+
DOMAIN = "https://${service.vHost}";
+
ROCKET_ADDRESS = "0.0.0.0";
+
ROCKET_LOG = "critical";
+
ROCKET_PORT = service.port;
+
SIGNUPS_ALLOWED = false;
+
ICON_SERVICE = "bitwarden";
+
ICON_CACHE_TTL = 0;
+
IP_HEADER = "CF-Connecting-IP";
+
};
+
+
environmentFile = config.age.secrets.vaultwarden.path;
+
};
+
};
+
};
+
}
+64
modules/nixos/services/webdav-server-rs/default.nix
···
+
{
+
config,
+
lib,
+
pkgs,
+
...
+
}: let
+
name = "webdav";
+
cfg = config.myNixOS.services.${name};
+
+
network = config.mySnippets.tailnet;
+
service = network.networkMap.${name};
+
+
dataDirectory = "/var/lib";
+
in {
+
options.myNixOS.services.${name} = {
+
enable = lib.mkEnableOption "${name} server";
+
autoProxy = lib.mkOption {
+
default = true;
+
example = false;
+
description = "${name} auto proxy";
+
type = lib.types.bool;
+
};
+
};
+
+
config = lib.mkIf cfg.enable {
+
services = {
+
caddy.virtualHosts."${service.vHost}".extraConfig = lib.mkIf cfg.autoProxy ''
+
bind tailscale/${name}
+
encode zstd gzip
+
reverse_proxy ${service.hostName}:${toString service.port}
+
'';
+
+
webdav-server-rs = {
+
enable = true;
+
settings = {
+
server.listen = ["0.0.0.0:${toString service.port}" "[::]:${toString service.port}"];
+
accounts = {
+
auth-type = "htpasswd.default";
+
acct-type = "unix";
+
};
+
htpasswd.default = {
+
htpasswd = pkgs.writeText "htpasswd" ''
+
ayla:$2y$05$LD.VqJF.yVGsp.C3L6IJFO0SvYTeCKbGoGn70ZQaht4gxyEq2XbCS
+
'';
+
};
+
location = [
+
{
+
route = ["/*path"];
+
directory = "${dataDirectory}/webdav";
+
handler = "filesystem";
+
methods = ["webdav-rw"];
+
autoindex = true;
+
auth = "true";
+
}
+
];
+
};
+
};
+
};
+
+
systemd.tmpfiles.rules = [
+
"d /var/lib/webdav 0755 webdav webdav - -"
+
];
+
};
+
}
+42 -34
modules/snippets/aylac-top/default.nix
···
config,
...
}: {
-
options.mySnippets.aylac-top.networkMap = lib.mkOption {
-
type = lib.types.attrs;
-
description = "Hostnames, ports, and vHosts for aylac.top services.";
+
options.mySnippets.aylac-top = {
+
cloudflareTunnel = lib.mkOption {
+
type = lib.types.str;
+
description = "Cloudflare Tunnel ID";
+
default = "efe3d484-102d-4c58-bb17-ceaede4d7a4f";
+
};
-
default = {
-
forgejo = {
-
hostName = "nanpi";
-
port = 3001;
-
sshVHost = "ssh.aylac.top";
-
vHost = "git.aylac.top";
-
};
+
networkMap = lib.mkOption {
+
type = lib.types.attrs;
+
description = "Hostnames, ports, and vHosts for aylac.top services.";
-
pds = {
-
hostName = "nanpi";
-
port = 3000;
-
vHost = "pds.aylac.top";
-
};
+
default = {
+
forgejo = {
+
hostName = "nanpi";
+
port = 3001;
+
sshVHost = "ssh.aylac.top";
+
vHost = "git.aylac.top";
+
};
-
vaultwarden = {
-
hostName = "nanpi";
-
port = 8222;
-
vHost = "vault.aylac.top";
-
};
+
pds = {
+
hostName = "nanpi";
+
port = 3000;
+
vHost = "pds.aylac.top";
+
};
-
ntfy = {
-
hostName = "nanpi";
-
port = 9024;
-
vHost = "ntfy.aylac.top";
-
};
+
vaultwarden = {
+
hostName = "nanpi";
+
port = 8222;
+
vHost = "vault.aylac.top";
+
};
-
uptime-kuma = {
-
inherit (config.mySnippets.tailnet.networkMap.uptime-kuma) hostName;
-
inherit (config.mySnippets.tailnet.networkMap.uptime-kuma) port;
-
vHost = "status.aylac.top";
-
};
+
ntfy = {
+
hostName = "nanpi";
+
port = 9024;
+
vHost = "ntfy.aylac.top";
+
};
+
+
uptime-kuma = {
+
inherit (config.mySnippets.tailnet.networkMap.uptime-kuma) hostName;
+
inherit (config.mySnippets.tailnet.networkMap.uptime-kuma) port;
+
vHost = "status.aylac.top";
+
};
-
glance = {
-
inherit (config.mySnippets.tailnet.networkMap.glance) hostName;
-
inherit (config.mySnippets.tailnet.networkMap.glance) port;
-
vHost = "services.aylac.top";
+
glance = {
+
inherit (config.mySnippets.tailnet.networkMap.glance) hostName;
+
inherit (config.mySnippets.tailnet.networkMap.glance) port;
+
vHost = "services.aylac.top";
+
};
};
};
};