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

better

Changed files
+81 -10
hosts
modules
snippets
aylac-top
+4 -1
hosts/jezebel/default.nix
···
self.diskoConfigurations.btrfs-vps
];
-
networking.hostName = "jezebel";
system.stateVersion = "25.05";
time.timeZone = "America/Sao_Paulo";
nixpkgs.hostPlatform = "x86_64-linux";
···
self.diskoConfigurations.btrfs-vps
];
+
networking = {
+
firewall.allowedTCPPorts = [80 443];
+
hostName = "jezebel";
+
};
system.stateVersion = "25.05";
time.timeZone = "America/Sao_Paulo";
nixpkgs.hostPlatform = "x86_64-linux";
+21
hosts/jezebel/services.nix
···
{config, ...}: {
services = {
caddy = {
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, ...}: {
+
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}
+
'';
+
};
+
+
"${config.mySnippets.aylac-top.networkMap.glance.vHost}" = {
+
extraConfig = ''
+
encode gzip zstd
+
reverse_proxy ${config.mySnippets.aylac-top.networkMap.glance.hostName}:${toString config.mySnippets.aylac-top.networkMap.glance.port}
'';
};
};
+7 -5
hosts/nanpi/glance.nix
···
settings = {
pages = [
{
-
name = config.mySnippets.tailnet.networkMap.glance.vHost;
width = "slim";
hide-desktop-navigation = true;
center-vertically = true;
···
{
size = "full";
widgets = [
-
{
-
type = "search";
-
autofocus = true;
-
}
{
type = "monitor";
cache = "1m";
···
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";
}
];
}
···
settings = {
pages = [
{
+
name = config.mySnippets.aylac-top.networkMap.glance.vHost;
width = "slim";
hide-desktop-navigation = true;
center-vertically = true;
···
{
size = "full";
widgets = [
{
type = "monitor";
cache = "1m";
···
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";
}
];
}
+29
hosts/nanpi/services.nix
···
"${config.mySnippets.aylac-top.networkMap.vaultwarden.vHost}" = "http://${config.mySnippets.aylac-top.networkMap.vaultwarden.hostName}:${toString config.mySnippets.aylac-top.networkMap.vaultwarden.port}";
"${config.mySnippets.aylac-top.networkMap.forgejo.vHost}" = "http://${config.mySnippets.aylac-top.networkMap.forgejo.hostName}:${toString config.mySnippets.aylac-top.networkMap.forgejo.port}";
};
};
};
···
PORT = "7020";
};
environmentFile = config.age.secrets.gemini.path;
};
copyparty = {
···
"${config.mySnippets.aylac-top.networkMap.vaultwarden.vHost}" = "http://${config.mySnippets.aylac-top.networkMap.vaultwarden.hostName}:${toString config.mySnippets.aylac-top.networkMap.vaultwarden.port}";
"${config.mySnippets.aylac-top.networkMap.forgejo.vHost}" = "http://${config.mySnippets.aylac-top.networkMap.forgejo.hostName}:${toString config.mySnippets.aylac-top.networkMap.forgejo.port}";
+
+
"${config.mySnippets.aylac-top.networkMap.ntfy.vHost}" = "http://${config.mySnippets.aylac-top.networkMap.ntfy.hostName}:${toString config.mySnippets.aylac-top.networkMap.ntfy.port}";
};
};
};
···
PORT = "7020";
};
environmentFile = config.age.secrets.gemini.path;
+
};
+
+
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"
+
];
+
};
};
copyparty = {
+20 -4
modules/snippets/aylac-top/default.nix
···
-
{lib, ...}: {
options.mySnippets.aylac-top.networkMap = lib.mkOption {
type = lib.types.attrs;
description = "Hostnames, ports, and vHosts for aylac.top services.";
···
vHost = "vault.aylac.top";
};
uptime-kuma = {
-
# Only used for status pages
-
hostName = "jezebel";
-
port = 3008;
};
};
};
···
+
{
+
lib,
+
config,
+
...
+
}: {
options.mySnippets.aylac-top.networkMap = lib.mkOption {
type = lib.types.attrs;
description = "Hostnames, ports, and vHosts for aylac.top services.";
···
vHost = "vault.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";
};
};
};