aboutsummaryrefslogtreecommitdiff
path: root/hosts
diff options
context:
space:
mode:
authorCollin Williams <96917990+bluedragon1221@users.noreply.github.com>2026-10-02 11:23:45 -0500
committerCollin Williams <96917990+bluedragon1221@users.noreply.github.com>2026-10-02 11:23:45 -0500
commitb768ad0ca4208e8b3588b881067c43d85246e967 (patch)
tree460dca5c6568307efc94e256186346be0271478a /hosts
parent84364a52c3d7ca2f550cb3f7af56848405902bee (diff)
experiment with modular services; more unix domain sockets, clean up old code
Diffstat (limited to 'hosts')
-rw-r--r--hosts/ganymede/caddy.nix2
-rw-r--r--hosts/ganymede/config.nix7
-rw-r--r--hosts/ganymede/networking.nix13
-rw-r--r--hosts/mercury/hjem.nix47
-rw-r--r--hosts/mercury/networking.nix16
-rw-r--r--hosts/mercury/nixos.nix15
6 files changed, 62 insertions, 38 deletions
diff --git a/hosts/ganymede/caddy.nix b/hosts/ganymede/caddy.nix
index 96efc07..d98a8fc 100644
--- a/hosts/ganymede/caddy.nix
+++ b/hosts/ganymede/caddy.nix
@@ -90,7 +90,7 @@
};
collinux.services.glance.homelabServices."website" = {
- url = "https://williamsfam.us.com";
+ url = "https://collin.williamsfam.us.com";
icon = "mdi:web";
};
}
diff --git a/hosts/ganymede/config.nix b/hosts/ganymede/config.nix
index f1804e9..8e35c45 100644
--- a/hosts/ganymede/config.nix
+++ b/hosts/ganymede/config.nix
@@ -44,11 +44,8 @@
port = 8076;
};
cgit.enable = true;
- filebrowser.enable = true;
- glance = {
- enable = true;
- port = 8081;
- };
+ dufs.enable = true;
+ glance.enable = true;
caddy = {
enable = true;
diff --git a/hosts/ganymede/networking.nix b/hosts/ganymede/networking.nix
index 72eb026..7db36c2 100644
--- a/hosts/ganymede/networking.nix
+++ b/hosts/ganymede/networking.nix
@@ -15,17 +15,16 @@ in {
dhcpcd.enable = false;
useDHCP = false;
networkmanager.enable = false;
-
useNetworkd = true;
+ nameservers = ["127.0.0.1"];
+ resolvconf.enable = true;
+
firewall = {
enable = true;
checkReversePath = "loose";
};
- resolvconf.enable = true;
- nameservers = ["127.0.0.1"];
-
wireless = {
enable = true;
secretsFile = static.pskFile;
@@ -56,12 +55,10 @@ in {
};
};
+ # for next time I break networking...
networks."20-teather" = {
- # for next time I break networking...
name = "enp*";
- networkConfig = {
- DHCP = "yes";
- };
+ networkConfig.DHCP = "yes";
};
};
};
diff --git a/hosts/mercury/hjem.nix b/hosts/mercury/hjem.nix
index 307317a..e27e87c 100644
--- a/hosts/mercury/hjem.nix
+++ b/hosts/mercury/hjem.nix
@@ -1,4 +1,8 @@
-{pkgs, ...}: let
+{
+ pkgs,
+ lib,
+ ...
+}: let
rust-shell = let
rustProfile = pkgs.buildEnv {
name = "rust-profile";
@@ -26,16 +30,55 @@
export PYTHONSTARTUP=""
exec $SHELL
'';
+
+ smallObsidian = let
+ pname = "obsidian";
+ version = "1.13.7";
+ in
+ pkgs.stdenv.mkDerivation {
+ inherit pname version;
+
+ src = pkgs.fetchurl {
+ url = "https://github.com/obsidianmd/obsidian-releases/releases/download/v${version}/obsidian-${version}.tar.gz";
+ hash = "sha256-08vjdcv6QCTbGRC5gZFkn0E0xcSK7l5gtudxOYfc2yg=";
+ };
+ nativeBuildInputs = with pkgs; [
+ autoPatchelfHook
+ makeWrapper
+ imagemagick
+ asar
+ ];
+ installPhase = ''
+ runHook preInstall
+ mkdir -p $out/bin
+
+ # Mark Obsidian's app:// scheme `corsEnabled` to fix the internal PDF
+ # viewer; see https://github.com/NixOS/nixpkgs/pull/525772 for details.
+ # Remove once upstream registers the scheme with `corsEnabled`.
+ asar extract resources/app.asar app-src
+ substituteInPlace app-src/main.js \
+ --replace-fail "supportFetchAPI: true," "supportFetchAPI: true, corsEnabled: true,"
+ asar pack app-src resources/app.asar
+
+ makeWrapper ${pkgs.electron}/bin/electron $out/bin/obsidian \
+ --add-flags $out/share/obsidian/app.asar \
+ --add-flags "\''${NIXOS_OZONE_WL:+\''${WAYLAND_DISPLAY:+--ozone-platform=wayland --enable-wayland-ime=true --wayland-text-input-version=3}}"
+ install -m 755 -D obsidian-cli $out/bin/obsidian-cli
+ install -m 444 -D resources/app.asar $out/share/obsidian/app.asar
+ install -m 444 -D resources/obsidian.asar $out/share/obsidian/obsidian.asar
+ runHook postInstall
+ '';
+ };
in {
packages = with pkgs; [
anki
libreoffice-qt
musescore
vscodium
+ smallObsidian
noctalia-shell
- prismlauncher
mpv
irssi
diff --git a/hosts/mercury/networking.nix b/hosts/mercury/networking.nix
index cc1f995..dc0a3f3 100644
--- a/hosts/mercury/networking.nix
+++ b/hosts/mercury/networking.nix
@@ -18,25 +18,11 @@
systemd.network = {
enable = true;
-
networks."11-default" = {
name = "wl*";
networkConfig.DHCP = "yes";
-
- # never accept dhcp dns
- # dhcpV4Config.UseDNS = "no";
- # dhcpV6Config.UseDNS = "no";
};
};
- services.resolved = {
- enable = true;
- settings.Resolve = {
- # DNSOverTLS = true;
- # DNSSEC = "allow-downgrade";
-
- # LLMNR = false;
- # MulticastDNS = false;
- };
- };
+ services.resolved.enable = true;
}
diff --git a/hosts/mercury/nixos.nix b/hosts/mercury/nixos.nix
index ff386cd..4eab7b4 100644
--- a/hosts/mercury/nixos.nix
+++ b/hosts/mercury/nixos.nix
@@ -22,15 +22,16 @@
hosts
|> (lib.mapAttrsToList (hostname: hostAttrs:
if hostAttrs ? ip
- then ''
- Host ${hostname}
- ${
+ then
+ ''
+ Host ${hostname}
+ HostName ${hostAttrs.ip}
+ ''
+ + (
if hostAttrs ? jump
- then "ProxyJump ${hostAttrs.jump}"
+ then " ProxyJump ${hostAttrs.jump}"
else ""
- }
- HostName ${hostAttrs.ip}
- ''
+ )
else ""))
|> (builtins.filter (s: s != ""))
|> (lib.concatStringsSep "\n");