about summary refs log tree commit diff
diff options
context:
space:
mode:
authordanbst <abcz2.uprola@gmail.com>2016-09-07 15:58:08 +0000
committerBjørn Forsman <bjorn.forsman@gmail.com>2016-09-09 18:29:12 +0200
commit0c2d943529fcbf240fab31b7f5df2e01759a5b7f (patch)
treeb515d7f4c73ae8b6b151082a3f0d9d05330fd9ca
parent39ad7a9e600a3f92ea5e095fa57a0a4458df8fd9 (diff)
downloadnixlib-0c2d943529fcbf240fab31b7f5df2e01759a5b7f.tar
nixlib-0c2d943529fcbf240fab31b7f5df2e01759a5b7f.tar.gz
nixlib-0c2d943529fcbf240fab31b7f5df2e01759a5b7f.tar.bz2
nixlib-0c2d943529fcbf240fab31b7f5df2e01759a5b7f.tar.lz
nixlib-0c2d943529fcbf240fab31b7f5df2e01759a5b7f.tar.xz
nixlib-0c2d943529fcbf240fab31b7f5df2e01759a5b7f.tar.zst
nixlib-0c2d943529fcbf240fab31b7f5df2e01759a5b7f.zip
tomcat: split default webapps to separate output (~6M)
-rw-r--r--nixos/modules/services/web-servers/tomcat.nix4
-rw-r--r--pkgs/servers/http/tomcat/default.nix3
2 files changed, 5 insertions, 2 deletions
diff --git a/nixos/modules/services/web-servers/tomcat.nix b/nixos/modules/services/web-servers/tomcat.nix
index c3be20b41e29..c1166b697681 100644
--- a/nixos/modules/services/web-servers/tomcat.nix
+++ b/nixos/modules/services/web-servers/tomcat.nix
@@ -74,8 +74,8 @@ in
 
       webapps = mkOption {
         type = types.listOf types.package;
-        default = [ tomcat ];
-        defaultText = "[ tomcat ]";
+        default = [ tomcat.webapps ];
+        defaultText = "[ tomcat.webapps ]";
         description = "List containing WAR files or directories with WAR files which are web applications to be deployed on Tomcat";
       };
 
diff --git a/pkgs/servers/http/tomcat/default.nix b/pkgs/servers/http/tomcat/default.nix
index 3653679aa012..70d39e7216e8 100644
--- a/pkgs/servers/http/tomcat/default.nix
+++ b/pkgs/servers/http/tomcat/default.nix
@@ -11,10 +11,13 @@ let
       inherit sha256;
     };
     
+    outputs = [ "out" "webapps" ];
     installPhase =
       ''
         mkdir $out
         mv * $out
+        mkdir -p $webapps/webapps
+        mv $out/webapps $webapps/
       '';
     
     meta = {