mirror of
https://github.com/NixOS/nixpkgs.git
synced 2026-09-30 03:39:59 +00:00
nixos/lemmy: reduce moving parts
(cherry picked from commit a3527512d7)
This commit is contained in:
@@ -167,7 +167,7 @@ in
|
||||
description = "Lemmy server";
|
||||
|
||||
environment = {
|
||||
LEMMY_CONFIG_LOCATION = "/run/lemmy/config.hjson";
|
||||
LEMMY_CONFIG_LOCATION = "${settingsFormat.generate "config.hjson" cfg.settings}";
|
||||
LEMMY_DATABASE_URL = mkIf (cfg.database.uri != null) cfg.database.uri;
|
||||
};
|
||||
|
||||
@@ -185,7 +185,6 @@ in
|
||||
serviceConfig = {
|
||||
DynamicUser = true;
|
||||
RuntimeDirectory = "lemmy";
|
||||
ExecStartPre = "${pkgs.coreutils}/bin/install -m 600 ${settingsFormat.generate "config.hjson" cfg.settings} /run/lemmy/config.hjson";
|
||||
ExecStart = "${cfg.server.package}/bin/lemmy_server";
|
||||
};
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user