From b3ff0f8a595813c199a279fdb0c704f71844d7a8 Mon Sep 17 00:00:00 2001 From: Sander van der Burg Date: Wed, 30 Jan 2008 11:00:00 +0000 Subject: [PATCH] Added tomcat service to NixOS svn path=/nixos/trunk/; revision=10402 --- system/options.nix | 17 +++++++++++++++++ upstart-jobs/default.nix | 6 ++++++ 2 files changed, 23 insertions(+) diff --git a/system/options.nix b/system/options.nix index a403ca81c00f..d0a26fd99371 100644 --- a/system/options.nix +++ b/system/options.nix @@ -1035,6 +1035,23 @@ }; }; + tomcat = { + enable = mkOption { + default = false; + description = "Whether to enable Apache Tomcat"; + }; + + baseDir = mkOption { + default = "/var/tomcat"; + description = "Location where Tomcat stores configuration files, webapplications and logfiles"; + }; + + user = mkOption { + default = "nobody"; + description = "User account under which Apache Tomcat runs."; + }; + }; + httpd = { enable = mkOption { diff --git a/upstart-jobs/default.nix b/upstart-jobs/default.nix index 5d5d24ec61f5..017c1c3fda09 100644 --- a/upstart-jobs/default.nix +++ b/upstart-jobs/default.nix @@ -188,6 +188,12 @@ let inherit config pkgs; }) + # Apache Tomcat service + ++ optional config.services.tomcat.enable + (import ../upstart-jobs/tomcat.nix { + inherit config pkgs; + }) + # Samba service. ++ optional config.services.samba.enable (import ../upstart-jobs/samba.nix {