tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Christopher Schultz <ch...@christopherschultz.net>
Subject Re: Multiple instances?
Date Thu, 18 Dec 2014 18:07:14 GMT
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256

Billy,

On 12/18/14 9:25 AM, Billy Bones wrote:
> Ok soooo, here is a small update.
> 
> I've finally found what does this SERVICE_NAME mean, indeed you
> have to copy the original unit, then add the Systemd's directive 
> named Environment like this:
> 
> Environment="SERVICE_NAME=<YOUROWNSERVICENAMEHERE"
> 
> then you will copy the default tomcat config file found on the 
> /etc/sysconfig directory.
> 
> And as you supposed it Cristophe and Daniel, you then have to copy
> the whole CATALINA_{HOME/BASE} or update the previous config file
> to point out to another tomcat installation.

You should not have to copy the whole CATALINA_HOME. Instead, create a
CATALINA_BASE (which is basically just a few directories and a few
configuration files) for each service and then set the CATALINA_BASE
environment variable to point to each one for each service, set
CATALINA_HOME to point to where the full installation of Tomcat is
(with no web applications installed in it), and each service should
operate independently.

So you should be able to have something like this:

SERVICE_NAME=tomcat-one
CATALINA_HOME=/opt/apache-tomcat-7.0.57
CATALINA_BASE=/opt/tomcat/tomcat-one

SERVICE_NAME=tomcat-two
CATALINA_HOME=/opt/apache-tomcat-7.0.57
CATALINA_BASE=/opt/tomcat/tomcat-two

Then you configure /opt/tomcat/tomcat-(one|two) to have the
configuration and applications you want.

You should be able to start tomcat-one and tomcat-two independently of
each other. I don't know exactly what systemd does with all of this,
but once you end up calling catalina.sh with the right environment
variables set, Tomcat will do the right thing.

- -chris
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1
Comment: GPGTools - http://gpgtools.org

iQIcBAEBCAAGBQJUkxfSAAoJEBzwKT+lPKRYrMkP/1afPF9gZXKIFRFlp0NKRFDx
If1VuhuhbOG8pUexfwEtZ06KzMkwL7zCj80Q6adGoF+uZrwSkiZD1ls2qtPKhNPF
3J24gSZtLmuWVfrRcUCqSbk0H92B/PnNA/d7Cio15FDaTgbplkE1x/WDEVoJgieA
1F0j5BOjzW5TyWGjUmnW79X0hWmlxl+8hVA9rW2KkmI1RaaMZluE9zU8cNrX6Px0
Pwb0SXmYqxUhFiLaolpbMZyIyj7lhRN+NjcT6I+xa8KJ1hjoEcfEeO8CKijFRXWK
4aaNbuJuxzcoxCNjFSb2QsEzqjReI15x4P+puruYSIhgbV9YP68mmLizAQz8+4Tm
nitP9Ke3fs8prJdvwtnN7KLHpctOdDAmBplgmj/GgOwB+khh/XTGYYIy3xG1xbH5
UQJAOSMFPpD0AfaZWB4C2fpQ9triTrPd2YsnAY/6Xq5rFyRj2CEO31bbAf2DXSpp
GauhU6dbrKRlUPhbizIDSM4FdXq8pb22O3qbW+xqNQklzwFZ5eUWJ80IyXfXxA/E
U6+fHiCoBm5KOVjDZVFmU+V9bd4cnhw1kCZgEH5Mwcahne0Uw7MSdoe/5V0yz1a1
ZnH0R3VR03UpHR7WhDy6SAYqHjulgReHnIv1U12M/c/guSoRWyEYuBrPH2SauYbK
up3fP9xZSZKSyNlPv+Xm
=Lztv
-----END PGP SIGNATURE-----

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Mime
View raw message