bvm-twitterchiver: add twitterchiver-viewer
This commit is contained in:
parent
12e595bf43
commit
69aba17ba4
2 changed files with 20 additions and 2 deletions
|
@ -12,7 +12,7 @@
|
|||
];
|
||||
};
|
||||
|
||||
viewer = depot.third_party.buildGo.program {
|
||||
viewer = (depot.third_party.buildGo.program {
|
||||
name = "viewer";
|
||||
srcs = [ ./viewer/viewer.go ];
|
||||
deps = [
|
||||
|
@ -32,7 +32,13 @@
|
|||
cp -R ${builtins.filterSource (path: type: (type == "directory" && depot.lib.hasSuffix "/templates" path) || (depot.lib.hasInfix "/templates/" path)) ./viewer} $out
|
||||
''
|
||||
) ];
|
||||
};
|
||||
}).overrideAttrs (oldAttrs: {
|
||||
buildCommand = ''
|
||||
${oldAttrs.buildCommand}
|
||||
mkdir $out/share
|
||||
cp -R ${builtins.filterSource (path: type: (type == "directory" && depot.lib.hasSuffix "/templates" path) || (depot.lib.hasInfix "/templates/" path)) ./viewer}/* $out/share
|
||||
'';
|
||||
});
|
||||
|
||||
relatedfetcher = depot.third_party.buildGo.program {
|
||||
name = "relatedfetcher";
|
||||
|
|
|
@ -39,5 +39,17 @@
|
|||
group = "twitterchiver";
|
||||
};
|
||||
|
||||
systemd.services.twitterchiver-viewer = {
|
||||
description = "Twitterchiver Viewer";
|
||||
wants = ["network-online.target"];
|
||||
wantedBy = ["multi-user.target"];
|
||||
serviceConfig = {
|
||||
ExecStart = "${depot.go.viewer}/bin/minotarproxy --user_to_twitter=lukegb@lukegb.com:lukegb,bgekul";
|
||||
WorkingDirectory = "${depot.go.viewer}/share";
|
||||
User = "twitterchiver";
|
||||
Restart = "always";
|
||||
};
|
||||
};
|
||||
|
||||
system.stateVersion = "21.05";
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue