1
1
Files
deployed-nixos-server-and-apps/nixos-apps/cutesealfanpage.love.nix
Bill Ewanick ae7fee9e32
All checks were successful
Gitea Actions Demo / Explore-Gitea-Actions (push) Successful in 5s
Gitea Actions Demo / build-site (push) Successful in 5s
WIP
2026-01-04 02:30:35 -05:00

40 lines
1021 B
Nix

{pkgs, ...}: let
PROJECT_ROOT = "/workspace/deployed-nixos-server-and-apps/nixos-apps/cutesealfanpage.love";
in {
services.caddy = {
enable = true;
virtualHosts = {
"cutesealfanpage.love" = {
serverAliases = ["www.cutesealfanpage.love"];
extraConfig = ''
root * ${PROJECT_ROOT}/_site
file_server
'';
};
};
};
systemd.services = {
cutesealfanpage-hakyll-site = {
enable = true;
description = "The hakyll executable that rebuilds the site when a new blog post is created.";
path = with pkgs; [nix git];
script = ''
cd ${PROJECT_ROOT}
nix run .#hakyll-site -- watch --no-server
'';
};
cutesealfanpage-generatePosts = {
enable = true;
description = "The haskell script that creates the new post of the day.";
startAt = "08:12:42";
path = with pkgs; [nix git];
script = ''
cd ${PROJECT_ROOT}
nix run .#generateSealPosts
'';
};
};
}