From ab912cf744d38d1ac1c4e3b6da0283f762559cf2 Mon Sep 17 00:00:00 2001 From: Francesco Zanini Date: Wed, 13 Feb 2019 09:08:13 +0100 Subject: [PATCH] atlassian services: allow overriding package (#55685) --- nixos/modules/services/web-apps/atlassian/confluence.nix | 9 +++++++-- nixos/modules/services/web-apps/atlassian/crowd.nix | 9 ++++++++- nixos/modules/services/web-apps/atlassian/jira.nix | 9 ++++++++- 3 files changed, 23 insertions(+), 4 deletions(-) diff --git a/nixos/modules/services/web-apps/atlassian/confluence.nix b/nixos/modules/services/web-apps/atlassian/confluence.nix index b71887fcc6ee..15744d90cc79 100644 --- a/nixos/modules/services/web-apps/atlassian/confluence.nix +++ b/nixos/modules/services/web-apps/atlassian/confluence.nix @@ -6,7 +6,7 @@ let cfg = config.services.confluence; - pkg = pkgs.atlassian-confluence.override (optionalAttrs cfg.sso.enable { + pkg = cfg.package.override (optionalAttrs cfg.sso.enable { enableSSO = cfg.sso.enable; crowdProperties = '' application.name ${cfg.sso.applicationName} @@ -125,7 +125,12 @@ in }; }; - + package = mkOption { + type = types.package; + default = pkgs.atlassian-confluence; + defaultText = "pkgs.atlassian-confluence"; + description = "Atlassian Confluence package to use."; + }; jrePackage = mkOption { type = types.package; diff --git a/nixos/modules/services/web-apps/atlassian/crowd.nix b/nixos/modules/services/web-apps/atlassian/crowd.nix index 9f48d1e16a44..c144b21bdaf2 100644 --- a/nixos/modules/services/web-apps/atlassian/crowd.nix +++ b/nixos/modules/services/web-apps/atlassian/crowd.nix @@ -6,7 +6,7 @@ let cfg = config.services.crowd; - pkg = pkgs.atlassian-crowd.override { + pkg = cfg.package.override { home = cfg.home; port = cfg.listenPort; openidPassword = cfg.openidPassword; @@ -93,6 +93,13 @@ in }; }; + package = mkOption { + type = types.package; + default = pkgs.atlassian-crowd; + defaultText = "pkgs.atlassian-crowd"; + description = "Atlassian Crowd package to use."; + }; + jrePackage = mkOption { type = types.package; default = pkgs.oraclejre8; diff --git a/nixos/modules/services/web-apps/atlassian/jira.nix b/nixos/modules/services/web-apps/atlassian/jira.nix index dba970c612bc..0b3a5722d6c8 100644 --- a/nixos/modules/services/web-apps/atlassian/jira.nix +++ b/nixos/modules/services/web-apps/atlassian/jira.nix @@ -6,7 +6,7 @@ let cfg = config.services.jira; - pkg = pkgs.atlassian-jira.override (optionalAttrs cfg.sso.enable { + pkg = cfg.package.override (optionalAttrs cfg.sso.enable { enableSSO = cfg.sso.enable; crowdProperties = '' application.name ${cfg.sso.applicationName} @@ -131,6 +131,13 @@ in }; }; + package = mkOption { + type = types.package; + default = pkgs.atlassian-jira; + defaultText = "pkgs.atlassian-jira"; + description = "Atlassian JIRA package to use."; + }; + jrePackage = mkOption { type = types.package; default = pkgs.oraclejre8;