2016-09-08 10:47:04 +02:00
|
|
|
{ stdenv, lib, fetchurl }:
|
2016-09-07 17:47:01 +02:00
|
|
|
|
|
|
|
let
|
|
|
|
|
|
|
|
common = { versionMajor, versionMinor, sha256 } @ args: stdenv.mkDerivation (rec {
|
|
|
|
name = "apache-tomcat-${version}";
|
|
|
|
version = "${versionMajor}.${versionMinor}";
|
2016-09-23 02:16:26 +02:00
|
|
|
|
2016-09-07 17:47:01 +02:00
|
|
|
src = fetchurl {
|
|
|
|
url = "mirror://apache/tomcat/tomcat-${versionMajor}/v${version}/bin/${name}.tar.gz";
|
|
|
|
inherit sha256;
|
|
|
|
};
|
2016-09-23 02:16:26 +02:00
|
|
|
|
2016-09-07 17:58:08 +02:00
|
|
|
outputs = [ "out" "webapps" ];
|
2016-09-07 17:47:01 +02:00
|
|
|
installPhase =
|
|
|
|
''
|
|
|
|
mkdir $out
|
|
|
|
mv * $out
|
2016-09-07 17:58:08 +02:00
|
|
|
mkdir -p $webapps/webapps
|
|
|
|
mv $out/webapps $webapps/
|
2016-09-07 17:47:01 +02:00
|
|
|
'';
|
2016-09-23 02:16:26 +02:00
|
|
|
|
2016-09-07 17:47:01 +02:00
|
|
|
meta = {
|
2016-09-08 10:47:04 +02:00
|
|
|
homepage = https://tomcat.apache.org/;
|
2016-09-07 17:47:01 +02:00
|
|
|
description = "An implementation of the Java Servlet and JavaServer Pages technologies";
|
2016-09-08 10:47:04 +02:00
|
|
|
platforms = with lib.platforms; all;
|
|
|
|
maintainers = with lib.maintainers; [ danbst ];
|
|
|
|
license = [ lib.licenses.asl20 ];
|
2016-09-07 17:47:01 +02:00
|
|
|
};
|
|
|
|
});
|
|
|
|
|
|
|
|
in {
|
|
|
|
tomcat7 = common {
|
|
|
|
versionMajor = "7";
|
2017-02-18 04:28:01 +01:00
|
|
|
versionMinor = "0.75";
|
|
|
|
sha256 = "0w5adsy4792qkf3ws46f539lrdbpz7lghy79s6b04c9yqaxjz6ni";
|
2016-09-07 17:47:01 +02:00
|
|
|
};
|
|
|
|
|
|
|
|
tomcat8 = common {
|
|
|
|
versionMajor = "8";
|
2016-12-01 00:21:16 +01:00
|
|
|
versionMinor = "0.39";
|
|
|
|
sha256 = "16hyypdawby66qa8y66sfprcf78wjy319a0gsi4jgfqfywcsm4s0";
|
2016-09-07 17:47:01 +02:00
|
|
|
};
|
|
|
|
|
2016-09-07 18:20:54 +02:00
|
|
|
tomcat85 = common {
|
|
|
|
versionMajor = "8";
|
2016-12-19 23:20:34 +01:00
|
|
|
versionMinor = "5.9";
|
|
|
|
sha256 = "1dy8bf18jwyi6p7ayb96gbhd4iyfq4d37s3qxnlll8vklfx388np";
|
2016-09-07 18:20:54 +02:00
|
|
|
};
|
2016-09-23 02:16:26 +02:00
|
|
|
|
2016-09-07 18:20:54 +02:00
|
|
|
tomcatUnstable = common {
|
|
|
|
versionMajor = "9";
|
2016-12-19 23:20:58 +01:00
|
|
|
versionMinor = "0.0.M15";
|
|
|
|
sha256 = "1spbq5vh2dplp83ki3fbbwl0klxq36s4rwkpcjdnwjxjymg9k432";
|
2016-09-07 18:20:54 +02:00
|
|
|
};
|
2016-09-07 17:47:01 +02:00
|
|
|
}
|