Skip to content

Commit

Permalink
Merge master into staging-next
Browse files Browse the repository at this point in the history
  • Loading branch information
github-actions[bot] authored Aug 14, 2024
2 parents ae6040d + a42598a commit 261f1ed
Show file tree
Hide file tree
Showing 70 changed files with 1,256 additions and 780 deletions.
12 changes: 12 additions & 0 deletions maintainers/maintainer-list.nix
Original file line number Diff line number Diff line change
Expand Up @@ -5083,6 +5083,12 @@
githubId = 265220;
name = "David Leung";
};
diadatp = {
email = "[email protected]";
github = "diadatp";
githubId = 4490283;
name = "diadatp";
};
DianaOlympos = {
github = "DianaOlympos";
githubId = 15774340;
Expand Down Expand Up @@ -7388,6 +7394,12 @@
{ fingerprint = "MP2UpIRtJpbFFqyucP431H/FPCfn58UhEUTro4lXtRs"; }
];
};
geraldog = {
email = "[email protected]";
github = "geraldog";
githubId = 14135816;
name = "Geraldo Nascimento";
};
gerg-l = {
email = "[email protected]";
github = "Gerg-L";
Expand Down
12 changes: 9 additions & 3 deletions nixos/modules/services/web-apps/miniflux.nix
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,8 @@ in
};

adminCredentialsFile = mkOption {
type = types.path;
type = types.nullOr types.path;
default = null;
description = ''
File containing the ADMIN_USERNAME and
ADMIN_PASSWORD (length >= 6) in the format of
Expand All @@ -61,11 +62,16 @@ in
};

config = mkIf cfg.enable {
assertions = [
{ assertion = cfg.config.CREATE_ADMIN == 0 || cfg.adminCredentialsFile != null;
message = "services.miniflux.adminCredentialsFile must be set if services.miniflux.config.CREATE_ADMIN is 1";
}
];
services.miniflux.config = {
LISTEN_ADDR = mkDefault defaultAddress;
DATABASE_URL = lib.mkIf cfg.createDatabaseLocally "user=miniflux host=/run/postgresql dbname=miniflux";
RUN_MIGRATIONS = 1;
CREATE_ADMIN = 1;
CREATE_ADMIN = lib.mkDefault 1;
WATCHDOG = 1;
};

Expand Down Expand Up @@ -103,7 +109,7 @@ in
DynamicUser = true;
RuntimeDirectory = "miniflux";
RuntimeDirectoryMode = "0750";
EnvironmentFile = cfg.adminCredentialsFile;
EnvironmentFile = lib.mkIf (cfg.adminCredentialsFile != null) cfg.adminCredentialsFile;
WatchdogSec = 60;
WatchdogSignal = "SIGKILL";
Restart = "always";
Expand Down
Loading

0 comments on commit 261f1ed

Please sign in to comment.