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-09-10 16:42:47 +02:00
|
|
|
versionMinor = "0.81";
|
|
|
|
sha256 = "0mcr3caizqk6qrc0j9p91apdsg65ksawg0l6xpqk1fq6071nd5rq";
|
2016-09-07 17:47:01 +02:00
|
|
|
};
|
|
|
|
|
|
|
|
tomcat8 = common {
|
|
|
|
versionMajor = "8";
|
2017-09-10 16:42:47 +02:00
|
|
|
versionMinor = "0.46";
|
|
|
|
sha256 = "14wb9mgb7z02j6wvvmcsfc2zkcqnijc40gzyg1mnxcy5fvf8nzpk";
|
2016-09-07 17:47:01 +02:00
|
|
|
};
|
|
|
|
|
2016-09-07 18:20:54 +02:00
|
|
|
tomcat85 = common {
|
|
|
|
versionMajor = "8";
|
2018-01-08 18:09:04 +01:00
|
|
|
versionMinor = "5.23";
|
|
|
|
sha256 = "1qnww70x75c0qf2wn8mkpz5lszggjnh78dpb4chyw2fnbm3wxain";
|
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";
|
2017-02-18 04:30:41 +01:00
|
|
|
versionMinor = "0.0.M17";
|
|
|
|
sha256 = "1ilvka2062m7412bj2fsdwvfxbrjyj9qxcia40hhv22prvkxw3cg";
|
2016-09-07 18:20:54 +02:00
|
|
|
};
|
2016-09-07 17:47:01 +02:00
|
|
|
}
|