about summary refs log tree commit diff
path: root/modules/services/drone/runner-exec
diff options
context:
space:
mode:
authorFranck Cuny <franck@fcuny.net>2023-04-23 14:53:55 -0700
committerFranck Cuny <franck@fcuny.net>2023-04-23 14:53:55 -0700
commitaecd9524b7cb0b80b86838f5463aa3e2b15686f8 (patch)
tree6345b170bbaddc60a4912afe3f9e87b6bcc61881 /modules/services/drone/runner-exec
parenthosts/carmel: enable promtail (diff)
downloadworld-aecd9524b7cb0b80b86838f5463aa3e2b15686f8.tar.gz
modules/services: delete unused services
I'm not using anymore sourcegraph drone and gitea.
Diffstat (limited to 'modules/services/drone/runner-exec')
-rw-r--r--modules/services/drone/runner-exec/default.nix58
1 files changed, 0 insertions, 58 deletions
diff --git a/modules/services/drone/runner-exec/default.nix b/modules/services/drone/runner-exec/default.nix
deleted file mode 100644
index cbfbb9d..0000000
--- a/modules/services/drone/runner-exec/default.nix
+++ /dev/null
@@ -1,58 +0,0 @@
-{ config, lib, pkgs, ... }:
-let
-  cfg = config.my.services.drone;
-  hasRunner = (name: builtins.elem name cfg.runners);
-  execPkg = pkgs.drone-runner-exec;
-in
-{
-  config = lib.mkIf (cfg.enable && hasRunner "exec") {
-    systemd.services.drone-runner-exec = {
-      wantedBy = [ "multi-user.target" ];
-      # might break deployment
-      restartIfChanged = false;
-      confinement.enable = true;
-      confinement.packages = with pkgs; [ git gnutar bash nixUnstable gzip ];
-      path = with pkgs; [ git gnutar bash nixUnstable gzip ];
-      serviceConfig = {
-        Environment = [
-          "DRONE_SERVER_HOST=${cfg.vhostName}"
-          "DRONE_SERVER_PROTO=https"
-          "DRONE_RUNNER_CAPACITY=10"
-          "CLIENT_DRONE_RPC_HOST=127.0.0.1:${toString cfg.port}"
-          "PAGER=cat"
-        ];
-        BindPaths = [
-          "/nix/var/nix/daemon-socket/socket"
-          "/var/run/docker.sock"
-        ];
-        BindReadOnlyPaths = [
-          "/etc/resolv.conf:/etc/resolv.conf"
-          "/etc/resolvconf.conf:/etc/resolvconf.conf"
-          "/etc/passwd:/etc/passwd"
-          "/etc/group:/etc/group"
-          "/nix/var/nix/profiles/system/etc/nix:/etc/nix"
-          "${
-            config.environment.etc."ssl/certs/ca-certificates.crt".source
-          }:/etc/ssl/certs/ca-certificates.crt"
-          "${
-            config.environment.etc."ssh/ssh_known_hosts".source
-          }:/etc/ssh/ssh_known_hosts"
-          "/etc/machine-id"
-          # channels are dynamic paths in the nix store, therefore we need to bind mount the whole thing
-          "/nix/"
-        ];
-        EnvironmentFile = [ cfg.sharedSecretFile ];
-        ExecStart = "${execPkg}/bin/drone-runner-exec";
-        User = "drone-runner-exec";
-        Group = "drone-runner-exec";
-      };
-    };
-
-    users.users.drone-runner-exec = {
-      isSystemUser = true;
-      group = "drone-runner-exec";
-      extraGroups = [ "docker" ]; # Give access to the daemon
-    };
-    users.groups.drone-runner-exec = { };
-  };
-}