summaryrefslogtreecommitdiffstats
path: root/makefu/2configs/shiori.nix
diff options
context:
space:
mode:
Diffstat (limited to 'makefu/2configs/shiori.nix')
-rw-r--r--makefu/2configs/shiori.nix29
1 files changed, 29 insertions, 0 deletions
diff --git a/makefu/2configs/shiori.nix b/makefu/2configs/shiori.nix
new file mode 100644
index 000000000..fd6bc9aad
--- /dev/null
+++ b/makefu/2configs/shiori.nix
@@ -0,0 +1,29 @@
+{config, lib, pkgs, ...}:
+let
+ web_port = 9011;
+ statedir = "/var/lib/shiori";
+in {
+ state = [ statedir ];
+ systemd.services.shiori = {
+ description = "Shiori Server";
+ after = [ "network-online.target" ];
+ environment = {
+ SHIORI_DIR = statedir;
+ };
+ wantedBy = [ "multi-user.target" ];
+ serviceConfig = {
+ DynamicUser = true;
+ StateDirectory = "shiori";
+ ExecStart = "${pkgs.shiori}/bin/shiori serve -a 127.0.0.1 -p ${toString web_port}";
+ PrivateTmp = true;
+ };
+ };
+ services.nginx.virtualHosts."bookmark.euer.krebsco.de" = {
+ forceSSL = true;
+ enableACME = true;
+
+ locations."/" = {
+ proxyPass = "http://127.0.0.1:${toString web_port}/";
+ };
+ };
+}