1
1
Fork 0

Add systemd services to generate posts and run site

Bill Ewanick 2023-08-09 19:07:15 -04:00
parent 97b21d6b23
commit 3fdd805ba3
1 changed files with 20 additions and 1 deletions

View File

@ -18,13 +18,32 @@ in
"cutesealfanpage.love" = {
serverAliases = [ "www.cutesealfanpage.love" ];
extraConfig = ''
root * ${PROJECT_ROOT}/cutesealfanpage.love/
root * ${PROJECT_ROOT}/cutesealfanpage.love/_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.";
script = ''
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";
script = ''
nix run .#generateSealPosts
'';
};
};
# when in doubt, clear away the certs with
# sudo rm -rf /var/lib/acme/
security.acme.acceptTerms = true;