1
0
Fork 0

allow extra apps in Nextcloud

This commit is contained in:
ibizaman 2024-01-05 13:40:38 -08:00 committed by Pierre Penninckx
parent 52f8b35252
commit 4a1291c075

View file

@ -134,6 +134,27 @@ in
'';
};
extraApps = lib.mkOption {
type = lib.types.raw;
description = ''
Extra apps to install. Should be a function returning an attrSet of appid to packages
generated by fetchNextcloudApp. The appid must be identical to the id value in the apps
appinfo/info.xml. You can still install apps through the appstore.
'';
default = apps: {};
example = lib.literalExpression ''
apps: {
inherit (apps) mail calendar contact;
phonetrack = pkgs.fetchNextcloudApp {
name = "phonetrack";
sha256 = "0qf366vbahyl27p9mshfma1as4nvql6w75zy2zk5xwwbp343vsbc";
url = "https://gitlab.com/eneiluj/phonetrack-oc/-/wikis/uploads/931aaaf8dca24bf31a7e169a83c17235/phonetrack-0.6.9.tar.gz";
version = "0.6.9";
};
}
'';
};
debug = lib.mkOption {
type = lib.types.bool;
description = "Enable more verbose logging.";
@ -209,6 +230,10 @@ in
# Very important for a bunch of scripts to load correctly. Otherwise you get Content-Security-Policy errors. See https://docs.nextcloud.com/server/13/admin_manual/configuration_server/harden_server.html#enable-http-strict-transport-security
https = config.shb.ssl.enable;
extraApps = cfg.extraApps pkgs.nextcloud27Packages.apps;
extraAppsEnable = true;
appstoreEnable = true;
extraOptions = let
protocol = if config.shb.ssl.enable then "https" else "http";
in {