Files
dotfiles/system-modules/hugo.nix
Lennart J. Kurzweg (Nx2) 68cb4377b7 New Flake Style XPS fix
2025-05-27 12:12:36 +02:00

33 lines
637 B
Nix

{ pkgs, hyper, ... }:
let p = pkgs; in
{
environment.systemPackages = with p; [
hugo
dart-sass
];
users = {
groups = {
"hugo".name = "hugo";
};
users = {
"${hyper.user}".extraGroups = [ "hugo" ];
"nginx".extraGroups = [ "hugo" ];
"hugo" = {
isSystemUser = true;
group = "hugo";
};
};
};
systemd.services."hugo" = {
script = with p; /* shell */ ''
${hugo}/bin/hugo serve --port 8000 --bind 10.0.1.1 --baseURL http://10.0.1.1:8000 -s /var/lib/hugo/nx2site/
'';
serviceConfig = {
Type = "simple";
User = "hugo";
};
};
}