2026-01-20 09:59:20 +00:00
|
|
|
{ config, pkgs, lib, ... }:
|
|
|
|
|
{
|
2026-01-20 14:35:20 +00:00
|
|
|
config = lib.mkIf (config.networking.hostName == "FredOS-Mediaserver") {
|
2026-01-20 14:42:21 +00:00
|
|
|
# Create symlink from home to storage
|
|
|
|
|
systemd.tmpfiles.rules = [
|
|
|
|
|
"L+ /home/fred/storage - - - - /mnt/storage"
|
|
|
|
|
];
|
2026-01-20 09:59:20 +00:00
|
|
|
|
2026-01-20 14:42:21 +00:00
|
|
|
# Basic system packages
|
2026-01-20 14:35:20 +00:00
|
|
|
environment.systemPackages = with pkgs; [
|
|
|
|
|
mergerfs
|
|
|
|
|
wget
|
|
|
|
|
btop
|
|
|
|
|
util-linux
|
2026-01-25 16:01:40 +00:00
|
|
|
javaPackages.compiler.temurin-bin.jre-25
|
2026-01-25 16:06:34 +00:00
|
|
|
unzip
|
2026-01-25 16:40:19 +00:00
|
|
|
screen
|
2026-01-26 15:22:01 +00:00
|
|
|
yt-dlp
|
2026-04-09 10:07:38 +01:00
|
|
|
ghostty.terminfo
|
2026-04-16 20:17:38 +01:00
|
|
|
matugen
|
2026-04-15 10:25:36 +01:00
|
|
|
(pkgs.writeShellScriptBin "transcode-hevc" ''
|
2026-04-15 19:31:37 +01:00
|
|
|
export PATH="${pkgs.jellyfin-ffmpeg}/bin:${pkgs.coreutils}/bin:${pkgs.findutils}/bin:${pkgs.gnugrep}/bin:${pkgs.gawk}/bin:${pkgs.bc}/bin:${pkgs.curl}/bin:$PATH"
|
2026-04-15 10:25:36 +01:00
|
|
|
exec ${pkgs.bash}/bin/bash ${../scripts/transcode-hevc.sh} "$@"
|
|
|
|
|
'')
|
2026-01-20 14:35:20 +00:00
|
|
|
];
|
2026-01-20 09:59:20 +00:00
|
|
|
|
2026-01-20 14:42:21 +00:00
|
|
|
# Basic networking
|
|
|
|
|
networking.useDHCP = lib.mkDefault true;
|
|
|
|
|
|
2026-01-20 21:38:23 +00:00
|
|
|
# Open firewall for SSH
|
|
|
|
|
networking.firewall.allowedTCPPorts = [ 22 ];
|
2026-01-20 14:42:21 +00:00
|
|
|
services.openssh = {
|
|
|
|
|
enable = true;
|
2026-04-06 21:48:08 +01:00
|
|
|
settings = {
|
|
|
|
|
PermitRootLogin = "no";
|
|
|
|
|
PasswordAuthentication = false;
|
|
|
|
|
};
|
2026-01-20 14:42:21 +00:00
|
|
|
};
|
2026-01-20 14:35:20 +00:00
|
|
|
};
|
2026-01-20 09:59:20 +00:00
|
|
|
}
|