From 0b5365ef40526b9b8cb80a0e01451465164d4ed8 Mon Sep 17 00:00:00 2001 From: Franck Cuny Date: Wed, 13 Apr 2022 15:36:40 -0700 Subject: drone: configuration fixes --- modules/services/drone/default.nix | 2 +- modules/services/drone/server/default.nix | 7 ++++++- 2 files changed, 7 insertions(+), 2 deletions(-) (limited to 'modules/services/drone') diff --git a/modules/services/drone/default.nix b/modules/services/drone/default.nix index 352ee3d..dedf120 100644 --- a/modules/services/drone/default.nix +++ b/modules/services/drone/default.nix @@ -20,7 +20,7 @@ }; admin = mkOption { type = types.str; - default = "ambroisie"; + default = "fcuny"; example = "admin"; description = "Name of the admin user"; }; diff --git a/modules/services/drone/server/default.nix b/modules/services/drone/server/default.nix index 199aa47..9c1d1a1 100644 --- a/modules/services/drone/server/default.nix +++ b/modules/services/drone/server/default.nix @@ -1,5 +1,7 @@ { config, lib, pkgs, ... }: -let cfg = config.my.services.drone; +let + cfg = config.my.services.drone; + secrets = config.age.secrets; in { config = lib.mkIf cfg.enable { systemd.services.drone-server = { @@ -7,6 +9,8 @@ in { serviceConfig = { EnvironmentFile = [ cfg.sharedSecretFile ]; Environment = [ + "DRONE_DATABASE_DRIVER=sqlite3" + "DRONE_DATABASE_DATASOURCE=/var/lib/drone-server/drone.sqlite" "DRONE_SERVER_HOST=${cfg.vhostName}" "DRONE_SERVER_PROTO=https" "DRONE_SERVER_PORT=:${toString cfg.port}" @@ -14,6 +18,7 @@ in { "DRONE_JSONNET_ENABLED=true" "DRONE_STARLARK_ENABLED=true" ]; + StateDirectory = "drone-server"; ExecStart = "${pkgs.drone}/bin/drone-server"; User = "drone"; Group = "drone"; -- cgit 1.4.1