mirror of
https://gitlab.com/upRootNutrition/dotfiles.git
synced 2025-08-08 21:04:38 -05:00
feat: refactored wireguard and fixed self-hosted bookmarks
This commit is contained in:
parent
5c1d3e6356
commit
cd118791e5
14 changed files with 55 additions and 128 deletions
|
@ -3,12 +3,6 @@ let
|
||||||
|
|
||||||
inherit (flake.config.people) user0;
|
inherit (flake.config.people) user0;
|
||||||
user = config.home.username;
|
user = config.home.username;
|
||||||
keyLogic =
|
|
||||||
if user == user0 then
|
|
||||||
"$env.ANTHROPIC_API_KEY = (open /home/${user0}/.config/zed/claude-api-key)"
|
|
||||||
else
|
|
||||||
"";
|
|
||||||
|
|
||||||
in
|
in
|
||||||
{
|
{
|
||||||
programs.nushell = {
|
programs.nushell = {
|
||||||
|
@ -16,7 +10,6 @@ in
|
||||||
configFile.text = ''
|
configFile.text = ''
|
||||||
sleep 7ms
|
sleep 7ms
|
||||||
$env.config = {show_banner: false}
|
$env.config = {show_banner: false}
|
||||||
${keyLogic}
|
|
||||||
'';
|
'';
|
||||||
shellAliases = {
|
shellAliases = {
|
||||||
y = "yy";
|
y = "yy";
|
||||||
|
|
|
@ -31,7 +31,6 @@ in
|
||||||
lutris
|
lutris
|
||||||
heroic
|
heroic
|
||||||
zed
|
zed
|
||||||
vsCode
|
|
||||||
feishin
|
feishin
|
||||||
obsidian
|
obsidian
|
||||||
libreOffice
|
libreOffice
|
||||||
|
|
|
@ -21,12 +21,11 @@ in
|
||||||
keyword = "Discord";
|
keyword = "Discord";
|
||||||
}
|
}
|
||||||
{
|
{
|
||||||
name = "Elm-UI";
|
name = "Elm Packages";
|
||||||
url = "https://package.elm-lang.org/packages/mdgriffith/elm-ui/latest/";
|
url = "https://package.elm-lang.org/packages";
|
||||||
tags = [
|
tags = [
|
||||||
"elm-ui"
|
|
||||||
"elm"
|
"elm"
|
||||||
"ui"
|
"packages"
|
||||||
];
|
];
|
||||||
keyword = "Elm";
|
keyword = "Elm";
|
||||||
}
|
}
|
||||||
|
@ -52,7 +51,7 @@ in
|
||||||
}
|
}
|
||||||
{
|
{
|
||||||
name = "GitLab (Fallaryn)";
|
name = "GitLab (Fallaryn)";
|
||||||
url = "${gitlabURL}/fallaryn/dotfiles";
|
url = "${gitlabURL}/fallaryn";
|
||||||
tags = [
|
tags = [
|
||||||
"fallaryn"
|
"fallaryn"
|
||||||
] ++ gitlabTags;
|
] ++ gitlabTags;
|
||||||
|
@ -60,7 +59,7 @@ in
|
||||||
}
|
}
|
||||||
{
|
{
|
||||||
name = "GitLab (Isaac)";
|
name = "GitLab (Isaac)";
|
||||||
url = "${gitlabURL}/askyourself/dotfiles";
|
url = "${gitlabURL}/askyourself";
|
||||||
tags = [
|
tags = [
|
||||||
"isaac"
|
"isaac"
|
||||||
"askyourself"
|
"askyourself"
|
||||||
|
@ -69,9 +68,9 @@ in
|
||||||
}
|
}
|
||||||
{
|
{
|
||||||
name = "GitLab (Nick)";
|
name = "GitLab (Nick)";
|
||||||
url = "${gitlabURL}/upRootNutrition/dotfiles";
|
url = "${gitlabURL}/upRootNutrition";
|
||||||
tags = [
|
tags = [
|
||||||
"brbwaffles"
|
"uprootnutrition"
|
||||||
] ++ gitlabTags;
|
] ++ gitlabTags;
|
||||||
keyword = "GitLab";
|
keyword = "GitLab";
|
||||||
}
|
}
|
||||||
|
@ -85,14 +84,5 @@ in
|
||||||
];
|
];
|
||||||
keyword = "Hack";
|
keyword = "Hack";
|
||||||
}
|
}
|
||||||
{
|
|
||||||
name = "Discord-Haskell";
|
|
||||||
url = "https://hackage.haskell.org/package/discord-haskell-1.17.1";
|
|
||||||
tags = [
|
|
||||||
"discord"
|
|
||||||
"haskell"
|
|
||||||
];
|
|
||||||
keyword = "Dack";
|
|
||||||
}
|
|
||||||
];
|
];
|
||||||
}
|
}
|
||||||
|
|
|
@ -51,7 +51,7 @@ in
|
||||||
}
|
}
|
||||||
{
|
{
|
||||||
name = instances.forgejo.label;
|
name = instances.forgejo.label;
|
||||||
url = "https://${instances.forgejo.subdomain}.${instances.web.domains.url3}";
|
url = "https://${instances.forgejo.domains.url0}";
|
||||||
tags = [
|
tags = [
|
||||||
instances.forgejo.name
|
instances.forgejo.name
|
||||||
"forge"
|
"forge"
|
||||||
|
@ -59,19 +59,9 @@ in
|
||||||
];
|
];
|
||||||
keyword = instances.forgejo.label;
|
keyword = instances.forgejo.label;
|
||||||
}
|
}
|
||||||
# {
|
|
||||||
# name = instances.hledger.label;
|
|
||||||
# url = "http://localhost.${builtins.toString instances.hledger.ports.port0}";
|
|
||||||
# tags = [
|
|
||||||
# instances.hledger.name
|
|
||||||
# "hledger"
|
|
||||||
# "finances"
|
|
||||||
# ];
|
|
||||||
# keyword = instances.hledger.label;
|
|
||||||
# }
|
|
||||||
{
|
{
|
||||||
name = "${instances.jellyfin.label} (Internet)";
|
name = "${instances.jellyfin.label} (Internet)";
|
||||||
url = "https://${instances.jellyfin.name}.${instances.web.domains.url0}";
|
url = "https://${instances.jellyfin.domains.url0}";
|
||||||
tags = jellyfinTags;
|
tags = jellyfinTags;
|
||||||
keyword = instances.jellyfin.label;
|
keyword = instances.jellyfin.label;
|
||||||
}
|
}
|
||||||
|
@ -83,7 +73,7 @@ in
|
||||||
}
|
}
|
||||||
{
|
{
|
||||||
name = instances.mastodon.label;
|
name = instances.mastodon.label;
|
||||||
url = "https://${instances.mastodon.subdomain}.${instances.web.domains.url3}";
|
url = "https://${instances.mastodon.domains.url0}";
|
||||||
tags = [
|
tags = [
|
||||||
instances.mastodon.name
|
instances.mastodon.name
|
||||||
"mast"
|
"mast"
|
||||||
|
@ -104,7 +94,7 @@ in
|
||||||
}
|
}
|
||||||
{
|
{
|
||||||
name = instances.nextcloud.label;
|
name = instances.nextcloud.label;
|
||||||
url = "https://${instances.nextcloud.subdomain}.${instances.web.domains.url1}";
|
url = "https://${instances.nextcloud.domains.url0}";
|
||||||
tags = [
|
tags = [
|
||||||
instances.nextcloud.name
|
instances.nextcloud.name
|
||||||
"next"
|
"next"
|
||||||
|
@ -124,7 +114,7 @@ in
|
||||||
}
|
}
|
||||||
{
|
{
|
||||||
name = "${instances.glance.label} (Local)";
|
name = "${instances.glance.label} (Local)";
|
||||||
url = "http://${instances.web.localhost.address0}:${toString instances.glance.ports.port0}";
|
url = "https://${instances.glance.domains.url0}";
|
||||||
tags = [
|
tags = [
|
||||||
"glance"
|
"glance"
|
||||||
"dashboard"
|
"dashboard"
|
||||||
|
@ -135,7 +125,7 @@ in
|
||||||
}
|
}
|
||||||
{
|
{
|
||||||
name = "${instances.ollama.label} (Server)";
|
name = "${instances.ollama.label} (Server)";
|
||||||
url = "https://${instances.ollama.subdomain}.${instances.web.domains.url0}";
|
url = "https://${instances.ollama.domains.url0}";
|
||||||
tags = ollamaTags;
|
tags = ollamaTags;
|
||||||
keyword = instances.ollama.label;
|
keyword = instances.ollama.label;
|
||||||
}
|
}
|
||||||
|
@ -145,29 +135,6 @@ in
|
||||||
tags = ollamaTags;
|
tags = ollamaTags;
|
||||||
keyword = instances.ollama.label;
|
keyword = instances.ollama.label;
|
||||||
}
|
}
|
||||||
# {
|
|
||||||
# name = "${instances.owncast.label} (Admin)";
|
|
||||||
# url = "http://${ceres.ip.address0}:${toString instances.owncast.ports.port0}/admin";
|
|
||||||
# tags = owncastTags;
|
|
||||||
# keyword = instances.owncast.label;
|
|
||||||
# }
|
|
||||||
# {
|
|
||||||
# name = "${instances.owncast.label} (Server)";
|
|
||||||
# url = "http://${instances.owncast.subdomain}.${instances.web.domains.url1}";
|
|
||||||
# tags = owncastTags;
|
|
||||||
# keyword = instances.owncast.label;
|
|
||||||
# }
|
|
||||||
# {
|
|
||||||
# name = instances.peertube.label;
|
|
||||||
# url = "https://${instances.peertube.subdomain}.${instances.web.domains.url3}";
|
|
||||||
# tags = [
|
|
||||||
# instances.peertube.name
|
|
||||||
# "peer"
|
|
||||||
# "tube"
|
|
||||||
# "uprootnutrition"
|
|
||||||
# ];
|
|
||||||
# keyword = instances.peertube.label;
|
|
||||||
# }
|
|
||||||
{
|
{
|
||||||
name = "Router";
|
name = "Router";
|
||||||
url = "http://${instances.web.localhost.address2}";
|
url = "http://${instances.web.localhost.address2}";
|
||||||
|
@ -179,7 +146,7 @@ in
|
||||||
}
|
}
|
||||||
{
|
{
|
||||||
name = "${instances.searx.label} (Internet)";
|
name = "${instances.searx.label} (Internet)";
|
||||||
url = "https://${instances.searx.subdomain}.${instances.web.domains.url0}";
|
url = "https://${instances.searx.domains.url0}";
|
||||||
tags = [
|
tags = [
|
||||||
"search"
|
"search"
|
||||||
"sear"
|
"sear"
|
||||||
|
@ -215,7 +182,7 @@ in
|
||||||
}
|
}
|
||||||
{
|
{
|
||||||
name = instances.vaultwarden.label;
|
name = instances.vaultwarden.label;
|
||||||
url = "https://${instances.vaultwarden.subdomain}.${instances.web.domains.url0}";
|
url = "https://${instances.vaultwarden.domains.url0}";
|
||||||
tags = [
|
tags = [
|
||||||
instances.vaultwarden.name
|
instances.vaultwarden.name
|
||||||
"bitwarden"
|
"bitwarden"
|
||||||
|
|
|
@ -90,15 +90,6 @@
|
||||||
];
|
];
|
||||||
keyword = "Deep";
|
keyword = "Deep";
|
||||||
}
|
}
|
||||||
{
|
|
||||||
name = "Uncensored AI";
|
|
||||||
url = "https://www.aiuncensored.info";
|
|
||||||
tags = [
|
|
||||||
"uncensored"
|
|
||||||
"ai"
|
|
||||||
];
|
|
||||||
keyword = "AI";
|
|
||||||
}
|
|
||||||
{
|
{
|
||||||
name = "Canadian Blood Services";
|
name = "Canadian Blood Services";
|
||||||
url = "https://www.blood.ca/en";
|
url = "https://www.blood.ca/en";
|
||||||
|
|
|
@ -29,11 +29,10 @@ in
|
||||||
"terminal.integrated.fontSize" = fonts.sizes.applications;
|
"terminal.integrated.fontSize" = fonts.sizes.applications;
|
||||||
"terminal.integrated.fontFamily" = "'${fonts.name}', 'monospace', monospace";
|
"terminal.integrated.fontFamily" = "'${fonts.name}', 'monospace', monospace";
|
||||||
"editor.fontLigatures" = true;
|
"editor.fontLigatures" = true;
|
||||||
|
"editor.formatOnSave" = true;
|
||||||
"elmLS.disableElmLSDiagnostics" = true;
|
"elmLS.disableElmLSDiagnostics" = true;
|
||||||
"elmLS.elmReviewDiagnostics" = "warning";
|
"elmLS.elmReviewDiagnostics" = "warning";
|
||||||
"elmLS.elmReviewPath" =
|
"elmLS.elmReviewPath" = "/etc/profiles/per-user/nick/bin/elm-review";
|
||||||
"/nix/store/r19y19rx5b7l4dzapbx1g64d30yisby1-elm-review-2.10.3/bin/elm-review";
|
|
||||||
"editor.formatOnSave" = true;
|
|
||||||
"[elm]" = {
|
"[elm]" = {
|
||||||
"editor.defaultFormatter" = "elmTooling.elm-ls-vscode";
|
"editor.defaultFormatter" = "elmTooling.elm-ls-vscode";
|
||||||
};
|
};
|
||||||
|
|
|
@ -10,5 +10,6 @@ builtins.attrValues {
|
||||||
inherit (pkgs.elmPackages)
|
inherit (pkgs.elmPackages)
|
||||||
elm-language-server
|
elm-language-server
|
||||||
elm-review
|
elm-review
|
||||||
|
elm-format
|
||||||
;
|
;
|
||||||
}
|
}
|
||||||
|
|
|
@ -39,7 +39,7 @@
|
||||||
language_servers = [ "elm-language-server" ];
|
language_servers = [ "elm-language-server" ];
|
||||||
format_on_save = {
|
format_on_save = {
|
||||||
external = {
|
external = {
|
||||||
command = "elm-review";
|
command = "elm-format";
|
||||||
arguments = [ "--stdin" ];
|
arguments = [ "--stdin" ];
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
|
@ -18,12 +18,12 @@ let
|
||||||
;
|
;
|
||||||
};
|
};
|
||||||
extraPackagesPath = import (configPath + /extraPackages) { inherit pkgs; };
|
extraPackagesPath = import (configPath + /extraPackages) { inherit pkgs; };
|
||||||
# packagePath = flake.inputs.zed-editor.packages.${pkgs.system}.default;
|
packagePath = flake.inputs.zed-editor.packages.${pkgs.system}.default;
|
||||||
in
|
in
|
||||||
{
|
{
|
||||||
programs.zed-editor = {
|
programs.zed-editor = {
|
||||||
enable = true;
|
enable = true;
|
||||||
# package = packagePath;
|
package = packagePath;
|
||||||
extraPackages = extraPackagesPath;
|
extraPackages = extraPackagesPath;
|
||||||
extensions = extensionsPath;
|
extensions = extensionsPath;
|
||||||
userKeymaps = userKeymapsPath;
|
userKeymaps = userKeymapsPath;
|
||||||
|
|
|
@ -7,7 +7,6 @@ in
|
||||||
mars = {
|
mars = {
|
||||||
imports = builtins.attrValues {
|
imports = builtins.attrValues {
|
||||||
inherit (modules)
|
inherit (modules)
|
||||||
mullvad
|
|
||||||
syncthing
|
syncthing
|
||||||
ollama
|
ollama
|
||||||
plasma
|
plasma
|
||||||
|
@ -17,6 +16,7 @@ in
|
||||||
wayland
|
wayland
|
||||||
searx
|
searx
|
||||||
flatpak
|
flatpak
|
||||||
|
wireGuard
|
||||||
;
|
;
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
@ -31,6 +31,7 @@ in
|
||||||
sddm
|
sddm
|
||||||
flatpak
|
flatpak
|
||||||
espanso
|
espanso
|
||||||
|
wireGuard
|
||||||
;
|
;
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
|
@ -1,7 +1,8 @@
|
||||||
{ config, flake, ... }:
|
{ config, flake, ... }:
|
||||||
let
|
let
|
||||||
inherit (flake.config.services.instances) wireGuard;
|
inherit (flake.config.services) instances;
|
||||||
service = wireGuard;
|
inherit (flake.config.machines.devices) ceres;
|
||||||
|
service = instances.wireGuard;
|
||||||
wireGuardInterface =
|
wireGuardInterface =
|
||||||
{
|
{
|
||||||
secret,
|
secret,
|
||||||
|
@ -49,6 +50,27 @@ let
|
||||||
in
|
in
|
||||||
{
|
{
|
||||||
networking = {
|
networking = {
|
||||||
|
hosts = {
|
||||||
|
${ceres.wireguard.ip0} = [
|
||||||
|
instances.searx.domains.url0
|
||||||
|
instances.glance.domains.url0
|
||||||
|
];
|
||||||
|
};
|
||||||
|
wireguard.interfaces = {
|
||||||
|
wg0 = {
|
||||||
|
peers = [
|
||||||
|
{
|
||||||
|
publicKey = "fs58+Kz+eG9qAXvvMB2NkW+wa88yP61uam4HHWaBJVw=";
|
||||||
|
allowedIPs = [
|
||||||
|
"${ceres.wireguard.ip0}/32"
|
||||||
|
"${instances.web.localhost.address4}/24"
|
||||||
|
];
|
||||||
|
endpoint = "${instances.web.remotehost.address0}:${builtins.toString service.ports.port1}";
|
||||||
|
persistentKeepalive = 25;
|
||||||
|
}
|
||||||
|
];
|
||||||
|
};
|
||||||
|
};
|
||||||
wg-quick.interfaces = builtins.listToAttrs (map wireGuardInterface interfaces);
|
wg-quick.interfaces = builtins.listToAttrs (map wireGuardInterface interfaces);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
@ -23,10 +23,10 @@ in
|
||||||
path = "/home/${user0}/.ssh/known_hosts";
|
path = "/home/${user0}/.ssh/known_hosts";
|
||||||
owner = user0;
|
owner = user0;
|
||||||
};
|
};
|
||||||
"claude-api-key" = {
|
# "claude-api-key" = {
|
||||||
path = "/home/${user0}/.config/zed/claude-api-key";
|
# path = "/home/${user0}/.config/zed/claude-api-key";
|
||||||
owner = user0;
|
# owner = user0;
|
||||||
};
|
# };
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,33 +1,15 @@
|
||||||
{ config, flake, ... }:
|
{ config, flake, ... }:
|
||||||
let
|
let
|
||||||
inherit (flake.config.services.instances) wireGuard web;
|
inherit (flake.config.services.instances) wireGuard;
|
||||||
inherit (flake.config.services) instances;
|
inherit (flake.config.machines.devices) deimos;
|
||||||
inherit (flake.config.machines.devices) ceres deimos;
|
|
||||||
service = wireGuard;
|
service = wireGuard;
|
||||||
in
|
in
|
||||||
{
|
{
|
||||||
networking = {
|
networking = {
|
||||||
hosts = {
|
|
||||||
${ceres.wireguard.ip0} = [
|
|
||||||
instances.searx.domains.url0
|
|
||||||
instances.glance.domains.url0
|
|
||||||
];
|
|
||||||
};
|
|
||||||
wireguard.interfaces = {
|
wireguard.interfaces = {
|
||||||
wg0 = {
|
wg0 = {
|
||||||
ips = [ "${deimos.wireguard.ip0}/32" ];
|
ips = [ "${deimos.wireguard.ip0}/32" ];
|
||||||
privateKeyFile = config.sops.secrets."${service.name}-deimos-private".path;
|
privateKeyFile = config.sops.secrets."${service.name}-deimos-private".path;
|
||||||
peers = [
|
|
||||||
{
|
|
||||||
publicKey = "fs58+Kz+eG9qAXvvMB2NkW+wa88yP61uam4HHWaBJVw=";
|
|
||||||
allowedIPs = [
|
|
||||||
"${ceres.wireguard.ip0}/32"
|
|
||||||
"${web.localhost.address4}/24"
|
|
||||||
];
|
|
||||||
endpoint = "${web.remotehost.address0}:${builtins.toString service.ports.port1}";
|
|
||||||
persistentKeepalive = 25;
|
|
||||||
}
|
|
||||||
];
|
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
|
@ -1,33 +1,15 @@
|
||||||
{ config, flake, ... }:
|
{ config, flake, ... }:
|
||||||
let
|
let
|
||||||
inherit (flake.config.services.instances) wireGuard web;
|
inherit (flake.config.services.instances) wireGuard;
|
||||||
inherit (flake.config.services) instances;
|
inherit (flake.config.machines.devices) mars;
|
||||||
inherit (flake.config.machines.devices) ceres mars;
|
|
||||||
service = wireGuard;
|
service = wireGuard;
|
||||||
in
|
in
|
||||||
{
|
{
|
||||||
networking = {
|
networking = {
|
||||||
hosts = {
|
|
||||||
${ceres.wireguard.ip0} = [
|
|
||||||
instances.searx.domains.url0
|
|
||||||
instances.glance.domains.url0
|
|
||||||
];
|
|
||||||
};
|
|
||||||
wireguard.interfaces = {
|
wireguard.interfaces = {
|
||||||
wg0 = {
|
wg0 = {
|
||||||
ips = [ "${mars.wireguard.ip0}/32" ];
|
ips = [ "${mars.wireguard.ip0}/32" ];
|
||||||
privateKeyFile = config.sops.secrets."${service.name}-mars-private".path;
|
privateKeyFile = config.sops.secrets."${service.name}-mars-private".path;
|
||||||
peers = [
|
|
||||||
{
|
|
||||||
publicKey = "fs58+Kz+eG9qAXvvMB2NkW+wa88yP61uam4HHWaBJVw=";
|
|
||||||
allowedIPs = [
|
|
||||||
"${ceres.wireguard.ip0}/32"
|
|
||||||
"${web.localhost.address4}/24"
|
|
||||||
];
|
|
||||||
endpoint = "${web.remotehost.address0}:${builtins.toString service.ports.port1}";
|
|
||||||
persistentKeepalive = 25;
|
|
||||||
}
|
|
||||||
];
|
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue