Skip to content

Commit

Permalink
Added template file
Browse files Browse the repository at this point in the history
  • Loading branch information
directdevops committed Dec 31, 2020
1 parent 0fb1907 commit bc64617
Showing 1 changed file with 23 additions and 0 deletions.
23 changes: 23 additions & 0 deletions Dec20/AdvancedScenarios/tomcat/tomcat.service.j2
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
[Unit]
Description=Tomcat 8.5 servlet container
After=network.target

[Service]
Type=forking

User=tomcat
Group=tomcat

Environment="JAVA_HOME=/usr/lib/jvm/java-1.8.0-openjdk-amd64"
Environment="JAVA_OPTS=-Djava.security.egd=file:///dev/urandom"

Environment="CATALINA_BASE=/opt/tomcat/latest"
Environment="CATALINA_HOME=/opt/tomcat/latest"
Environment="CATALINA_PID=/opt/tomcat/latest/temp/tomcat.pid"
Environment="CATALINA_OPTS=-Xms512M -Xmx1024M -server -XX:+UseParallelGC"

ExecStart=/opt/tomcat/latest/bin/startup.sh
ExecStop=/opt/tomcat/latest/bin/shutdown.sh

[Install]
WantedBy=multi-user.target

0 comments on commit bc64617

Please sign in to comment.