Navigation Menu

Skip to content

Instantly share code, notes, and snippets.

View MissakaI's full-sized avatar

Missaka Iddamalgoda MissakaI

View GitHub Profile
@MissakaI
MissakaI / README-tomcat-as-systemd-service.md
Created February 13, 2022 19:56 — forked from drmalex07/README-tomcat-as-systemd-service.md
An example configuration for Tomcat as systemd service. #tomcat #systemd #systemd.service

README

Let Tomcat is download and installed under /opt/tomcat. Also, let tomcat be a non-provileged user under which the server will be running.

We assume that we keep server's binaries under /opt/tomcat and we will create a server instance named foo under /var/tomcat/ (carrying its own conf, logs, webapps, work, lib directories). See also https://dzone.com/articles/running-multiple-tomcat.

Create a template service unit file at /etc/systemd/system/tomcat@.service: