microbin works

This commit is contained in:
Anish Lakhwara 2023-05-12 20:51:28 +10:00
parent 27138bdc7d
commit 41a64a3248

View file

@ -25,6 +25,17 @@ in
description = "Group account under which microbin runs.";
};
hostname = mkOption {
type = types.str;
description = "Hostname of your microbin service";
};
port = mkOption {
type = types.port;
default = 8080;
description = "Port on which to run the serice";
};
};
};
@ -34,18 +45,17 @@ in
after = [ "remote-fs.target" "network.target" ];
wantedBy = [ "multi-user.target" ];
serviceConfig = {
ExecStart = "${pkgs.microbin}/bin/microbin --port ${cfg.port} \\
--public-path ${cfg.hostname} \\
--editable \\
--enable-burn-after \\
--private \\
--qr \\
--title=sealight \\
--highlightsyntax";
ExecStart = ''${pkgs.microbin}/bin/microbin --port ${builtins.toString cfg.port}
--public-path ${cfg.hostname}
--editable
--enable-burn-after
--private
--qr
--title=sealight
--highlightsyntax'';
WorkingDirectory = dataFolder;
TimeoutStopSec = " 20 ";
KillMode = " process ";
Restart = " on-failure ";
RestartSec = " 10 ";
User = cfg.user;
Group = cfg.group;