linux-utils/packages/bookwyrm/nixos-module.nix

28 lines
466 B
Nix
Raw Normal View History

2025-03-04 13:21:29 +01:00
{ pkgs , ... } :
2025-03-04 16:02:02 +01:00
with pkgs ;
with pkgs . kernelmaft ;
{
systemd = {
units = {
"bookwyrm.service" = {
text = ''
[Unit]
2025-03-04 16:09:58 +01:00
After=network.target
[Service]
2025-03-04 16:09:58 +01:00
ExecStartPre=${coreutils-full}/bin/ln -sf ${bookwyrm}/var/lib/bookwyrm/VERSION /var/lib/bookwyrm/
ExecStart=${bookwyrm}/bin/bookwyrm
2025-03-04 16:09:58 +01:00
WorkingDirectory=/var/lib/bookwyrm
2025-03-04 16:09:58 +01:00
# Creates /var/lib/bookwyrm directory
StateDirectory=bookwyrm
'' ;
} ;
} ;
} ;
}