summaryrefslogtreecommitdiff
path: root/Biz/Devalloc.nix
diff options
context:
space:
mode:
authorBen Sima <ben@bsima.me>2021-08-18 13:25:31 -0400
committerBen Sima <ben@bsima.me>2021-11-26 13:47:37 -0500
commit1176a24a1f76f551ec32eda731e8d5cdf93ad085 (patch)
tree69d6ead8e57e54f2886808769a134d57b2e0893d /Biz/Devalloc.nix
parent2462d2c1377b645a99cba38875628b18d7da5ac8 (diff)
Rename Devalloc to Dragons
Diffstat (limited to 'Biz/Devalloc.nix')
-rw-r--r--Biz/Devalloc.nix66
1 files changed, 0 insertions, 66 deletions
diff --git a/Biz/Devalloc.nix b/Biz/Devalloc.nix
deleted file mode 100644
index a1c9bcf..0000000
--- a/Biz/Devalloc.nix
+++ /dev/null
@@ -1,66 +0,0 @@
-{ options
-, lib
-, config
-, pkgs
-, ...
-}:
-
-let
- cfg = config.services.devalloc;
-in
-{
- options.services.devalloc = {
- enable = lib.mkEnableOption "Enable the devalloc service";
- port = lib.mkOption {
- type = lib.types.int;
- default = 3000;
- description = ''
- The port on which devalloc will listen for
- incoming HTTP traffic.
- '';
- };
- keep = lib.mkOption {
- type = lib.types.path;
- default = "/var/devalloc/keep";
- description = "Keep location";
- };
- depo = lib.mkOption {
- type = lib.types.path;
- default = "/var/devalloc/depo";
- description = "depo location";
- };
- package = lib.mkOption {
- type = lib.types.package;
- description = "devalloc package to use";
- };
- };
- config = lib.mkIf cfg.enable {
- systemd.services.devalloc = {
- path = [ cfg.package pkgs.git ];
- wantedBy = [ "multi-user.target" ];
- preStart = ''
- mkdir -p ${cfg.keep}
- mkdir -p ${cfg.depo}
- '';
- script = ''
- ${cfg.package}/bin/devalloc
- '';
- description = ''
- Devalloc
- '';
- serviceConfig = {
- Environment = [
- "PORT=${toString cfg.port}"
- "AREA=Live"
- "DEPO=${cfg.depo}"
- "KEEP=${cfg.keep}"
- ];
- EnvironmentFile="/run/devalloc/env";
- KillSignal = "INT";
- Type = "simple";
- Restart = "on-abort";
- RestartSec = "1";
- };
- };
- };
-}