Compare commits
10 commits
63d14c58fd
...
f7c5255017
Author | SHA1 | Date | |
---|---|---|---|
Chandler Swift | f7c5255017 | ||
Chandler Swift | 0f4b0295c8 | ||
Chandler Swift | 9e80802351 | ||
Chandler Swift | 9e3c4ee13e | ||
Chandler Swift | 542b9dd68d | ||
Chandler Swift | 5271fe9965 | ||
Chandler Swift | e9e8913fe6 | ||
Chandler Swift | 0b821f6111 | ||
Chandler Swift | 3e7ead9d5f | ||
Chandler Swift | 815c1ad671 |
|
@ -8,6 +8,7 @@
|
||||||
./services/http/index.nix
|
./services/http/index.nix
|
||||||
./services/monitoring.nix
|
./services/monitoring.nix
|
||||||
./services/forgejo.nix
|
./services/forgejo.nix
|
||||||
|
./services/navidrome.nix
|
||||||
];
|
];
|
||||||
|
|
||||||
# Bootloader
|
# Bootloader
|
||||||
|
@ -35,8 +36,11 @@
|
||||||
boot.initrd.luks.devices."luks-48836129-1aa0-45c7-9fd1-6b053fa620b1".device = "/dev/disk/by-uuid/48836129-1aa0-45c7-9fd1-6b053fa620b1";
|
boot.initrd.luks.devices."luks-48836129-1aa0-45c7-9fd1-6b053fa620b1".device = "/dev/disk/by-uuid/48836129-1aa0-45c7-9fd1-6b053fa620b1";
|
||||||
networking.hostName = "bert";
|
networking.hostName = "bert";
|
||||||
|
|
||||||
# Enable networking
|
fileSystems."/mnt/bigbird-public" = {
|
||||||
networking.networkmanager.enable = true;
|
device = "//bigbird/public";
|
||||||
|
fsType = "cifs";
|
||||||
|
options = [ "guest" ];
|
||||||
|
};
|
||||||
|
|
||||||
time.timeZone = "America/Chicago";
|
time.timeZone = "America/Chicago";
|
||||||
i18n.defaultLocale = "en_US.UTF-8";
|
i18n.defaultLocale = "en_US.UTF-8";
|
||||||
|
|
20
bert/services/http/0hats.com.nix
Normal file
20
bert/services/http/0hats.com.nix
Normal file
|
@ -0,0 +1,20 @@
|
||||||
|
|
||||||
|
{
|
||||||
|
services.caddy.virtualHosts."0hats.com" = {
|
||||||
|
serverAliases = ["www.0hats.com"];
|
||||||
|
extraConfig = ''
|
||||||
|
encode zstd gzip
|
||||||
|
file_server
|
||||||
|
root * /srv/www/0hats.com
|
||||||
|
|
||||||
|
handle_errors {
|
||||||
|
respond "{err.status_code} {err.status_text}"
|
||||||
|
}
|
||||||
|
'';
|
||||||
|
};
|
||||||
|
systemd.tmpfiles.settings."10-0hats-com" = {
|
||||||
|
"/srv/www/0hats.com" = {
|
||||||
|
d = {};
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
|
@ -4,6 +4,10 @@
|
||||||
encode zstd gzip
|
encode zstd gzip
|
||||||
file_server
|
file_server
|
||||||
root * /srv/www/files.chandlerswift.com
|
root * /srv/www/files.chandlerswift.com
|
||||||
|
|
||||||
|
handle_errors {
|
||||||
|
respond "{err.status_code} {err.status_text}"
|
||||||
|
}
|
||||||
'';
|
'';
|
||||||
systemd.tmpfiles.settings."10-files-chandlerswift-com" = {
|
systemd.tmpfiles.settings."10-files-chandlerswift-com" = {
|
||||||
"/srv/www/files.chandlerswift.com" = {
|
"/srv/www/files.chandlerswift.com" = {
|
||||||
|
|
|
@ -6,14 +6,18 @@
|
||||||
encode zstd gzip
|
encode zstd gzip
|
||||||
file_server
|
file_server
|
||||||
root * /srv/www/harborpaperco.com
|
root * /srv/www/harborpaperco.com
|
||||||
|
|
||||||
|
handle_errors {
|
||||||
|
respond "{err.status_code} {err.status_text}"
|
||||||
|
}
|
||||||
|
'';
|
||||||
|
};
|
||||||
|
services.caddy.virtualHosts."pureserendipityweddings.com" = {
|
||||||
|
serverAliases = ["www.pureserendipityweddings.com"];
|
||||||
|
extraConfig = ''
|
||||||
|
redir https://harborpaperco.com
|
||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
# services.caddy.virtualHosts."pureserendipityweddings.com" = {
|
|
||||||
# serverAliases = ["www.pureserendipityweddings.com"];
|
|
||||||
# extraConfig = ''
|
|
||||||
# redir https://harborpaperco.com
|
|
||||||
# '';
|
|
||||||
# };
|
|
||||||
systemd.tmpfiles.settings."10-harborpaperco-com" = {
|
systemd.tmpfiles.settings."10-harborpaperco-com" = {
|
||||||
"/srv/www/harborpaperco.com" = {
|
"/srv/www/harborpaperco.com" = {
|
||||||
d = {};
|
d = {};
|
||||||
|
|
|
@ -6,6 +6,20 @@
|
||||||
root * /srv/www/home.chandlerswift.com
|
root * /srv/www/home.chandlerswift.com
|
||||||
reverse_proxy /grafana/* localhost:3000
|
reverse_proxy /grafana/* localhost:3000
|
||||||
# hide .git # ???
|
# hide .git # ???
|
||||||
|
|
||||||
|
file_server /sheets/* {
|
||||||
|
browse ${./caddy-browse-template.html}
|
||||||
|
|
||||||
|
# TOOD: is there a better way to strip the prefix here? This shouldn't be
|
||||||
|
# vulnerable to a directory traversal attack (and it doesn't really
|
||||||
|
# matter anyway; everything in there is public somewhere or another!) but
|
||||||
|
# it sorta feels wrong to do this without a `/sheets` suffix.
|
||||||
|
root /mnt/bigbird-public
|
||||||
|
}
|
||||||
|
|
||||||
|
handle_errors {
|
||||||
|
respond "{err.status_code} {err.status_text}"
|
||||||
|
}
|
||||||
'';
|
'';
|
||||||
systemd.tmpfiles.settings."10-home-chandlerswift-com" = {
|
systemd.tmpfiles.settings."10-home-chandlerswift-com" = {
|
||||||
"/srv/www/home.chandlerswift.com" = {
|
"/srv/www/home.chandlerswift.com" = {
|
||||||
|
|
|
@ -1,11 +1,13 @@
|
||||||
{
|
{
|
||||||
imports = [
|
imports = [
|
||||||
|
./0hats.com.nix
|
||||||
./files.chandlerswift.com.nix
|
./files.chandlerswift.com.nix
|
||||||
./git.chandlerswift.com.nix
|
./git.chandlerswift.com.nix
|
||||||
./harborpaperco.com.nix
|
./harborpaperco.com.nix
|
||||||
./home.chandlerswift.com.nix
|
./home.chandlerswift.com.nix
|
||||||
./katherineandchandler.com.nix
|
./katherineandchandler.com.nix
|
||||||
./maps.chandlerswift.com.nix
|
./maps.chandlerswift.com.nix
|
||||||
|
./music.chandlerswift.com.nix
|
||||||
./stjohnscccc.org.nix
|
./stjohnscccc.org.nix
|
||||||
./swiftgang.net.nix
|
./swiftgang.net.nix
|
||||||
];
|
];
|
||||||
|
|
|
@ -5,6 +5,10 @@
|
||||||
file_server
|
file_server
|
||||||
root * /srv/www/katherineandchandler.com
|
root * /srv/www/katherineandchandler.com
|
||||||
# hide .git # ???
|
# hide .git # ???
|
||||||
|
|
||||||
|
handle_errors {
|
||||||
|
respond "{err.status_code} {err.status_text}"
|
||||||
|
}
|
||||||
'';
|
'';
|
||||||
systemd.tmpfiles.settings."10-katherineandchandler-com" = {
|
systemd.tmpfiles.settings."10-katherineandchandler-com" = {
|
||||||
"/srv/www/katherineandchandler.com" = {
|
"/srv/www/katherineandchandler.com" = {
|
||||||
|
|
|
@ -5,6 +5,10 @@
|
||||||
file_server
|
file_server
|
||||||
root * /srv/www/maps.chandlerswift.com
|
root * /srv/www/maps.chandlerswift.com
|
||||||
# hide .git # ???
|
# hide .git # ???
|
||||||
|
|
||||||
|
handle_errors {
|
||||||
|
respond "{err.status_code} {err.status_text}"
|
||||||
|
}
|
||||||
'';
|
'';
|
||||||
systemd.tmpfiles.settings."10-maps-chandlerswift-com" = {
|
systemd.tmpfiles.settings."10-maps-chandlerswift-com" = {
|
||||||
"/srv/www/maps.chandlerswift.com" = {
|
"/srv/www/maps.chandlerswift.com" = {
|
||||||
|
|
5
bert/services/http/music.chandlerswift.com.nix
Normal file
5
bert/services/http/music.chandlerswift.com.nix
Normal file
|
@ -0,0 +1,5 @@
|
||||||
|
{config, ...}: {
|
||||||
|
services.caddy.virtualHosts."music.chandlerswift.com".extraConfig = ''
|
||||||
|
reverse_proxy localhost:${toString config.services.navidrome.settings.Port}
|
||||||
|
'';
|
||||||
|
}
|
|
@ -4,6 +4,10 @@
|
||||||
encode zstd gzip
|
encode zstd gzip
|
||||||
file_server
|
file_server
|
||||||
root * /srv/www/swiftgang.net
|
root * /srv/www/swiftgang.net
|
||||||
|
|
||||||
|
handle_errors {
|
||||||
|
respond "{err.status_code} {err.status_text}"
|
||||||
|
}
|
||||||
'';
|
'';
|
||||||
systemd.tmpfiles.settings."10-swiftgang-net" = {
|
systemd.tmpfiles.settings."10-swiftgang-net" = {
|
||||||
"/srv/www/swiftgang.net" = {
|
"/srv/www/swiftgang.net" = {
|
||||||
|
|
10
bert/services/navidrome.nix
Normal file
10
bert/services/navidrome.nix
Normal file
|
@ -0,0 +1,10 @@
|
||||||
|
{
|
||||||
|
services.navidrome = {
|
||||||
|
enable = true;
|
||||||
|
settings = {
|
||||||
|
MusicFolder = "/mnt/bigbird-public/media/music";
|
||||||
|
ScanSchedule = "@every 12h";
|
||||||
|
EnableSharing = true;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
9
bigbird/README.md
Normal file
9
bigbird/README.md
Normal file
|
@ -0,0 +1,9 @@
|
||||||
|
# `bigbird`: ODROID HC4 NAS
|
||||||
|
|
||||||
|
## SD card notes
|
||||||
|
Many SD cards I attempted would boot fine but then fail to reset on reboot.
|
||||||
|
Some preliminary research suggests that this may be a kernel issue, but I'm not
|
||||||
|
entirely sure at this point. For now, I took the easy way out: Just keep trying
|
||||||
|
SD cards until one works! Thankfully, it seems to be reliable that an SD card
|
||||||
|
works either 100% or 0% of the time. Currently using a 32GB Microcenter cheapo,
|
||||||
|
in place of the nicer 128GB ones I was planning on instead.
|
|
@ -21,6 +21,8 @@
|
||||||
boot.zfs.forceImportRoot = false;
|
boot.zfs.forceImportRoot = false;
|
||||||
boot.zfs.extraPools = [ "nas" ];
|
boot.zfs.extraPools = [ "nas" ];
|
||||||
|
|
||||||
|
services.zfs.autoScrub.enable = true; # Current scan takes ~12h, runs monthly (I spend 2% of the time doing scans? lol)
|
||||||
|
|
||||||
networking.hostId = "66abd088"; # `openssl rand -hex 4`
|
networking.hostId = "66abd088"; # `openssl rand -hex 4`
|
||||||
|
|
||||||
time.timeZone = "America/Chicago";
|
time.timeZone = "America/Chicago";
|
||||||
|
|
|
@ -16,6 +16,7 @@
|
||||||
"steam"
|
"steam"
|
||||||
"steam-original"
|
"steam-original"
|
||||||
"steam-run"
|
"steam-run"
|
||||||
|
"steam-unwrapped"
|
||||||
];
|
];
|
||||||
|
|
||||||
# https://discourse.nixos.org/t/github-strategies-for-configuration-nix/1983/14
|
# https://discourse.nixos.org/t/github-strategies-for-configuration-nix/1983/14
|
||||||
|
|
Loading…
Reference in a new issue