Created
January 31, 2022 12:49
-
-
Save mz0/7cb34da555f254e9f2b95492e97e35f8 to your computer and use it in GitHub Desktop.
Tomcat/Shsha(w/Hazelcast 3.12) Unit file for EL7/JDK11
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# this is /etc/default/tomcat-shsha | |
TOMCAT=/srv/tomcat | |
JAVA_OPTS=-Djava.util.logging.manager=org.apache.juli.ClassLoaderLogManager \ | |
-Djdk.tls.ephemeralDHKeySize=2048 \ | |
-Djava.protocol.handler.pkgs=org.apache.catalina.webresources \ | |
-Dorg.apache.catalina.security.SecurityListener.UMASK=0027 \ | |
-Dhazelcast.logging.type=log4j2 \ | |
--add-modules java.se \ | |
--add-exports java.base/jdk.internal.ref=ALL-UNNAMED \ | |
--add-opens java.base/java.lang=ALL-UNNAMED \ | |
--add-opens java.base/java.nio=ALL-UNNAMED \ | |
--add-opens java.base/sun.nio.ch=ALL-UNNAMED \ | |
--add-opens java.management/sun.management=ALL-UNNAMED \ | |
--add-opens jdk.management/com.sun.management.internal=ALL-UNNAMED |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[Unit] | |
Description=Tomcat.Shsha | |
After=network.target mysqld.service | |
[Service] | |
SyslogIdentifier=tomcat-shsha | |
User=shsha | |
Group=shsha | |
EnvironmentFile=/etc/default/tomcat-shsha | |
# view STDOUT: sudo journalctl -u tomcat-shsha | |
#StandardOutput=append:/srv/tomcat/logs/catalina.out - OK Ubuntu 20.04 systemd 245 | |
ExecStart=/usr/bin/java $JAVA_OPTS -Dcatalina.base=${TOMCAT} \ | |
-Dcatalina.home=${TOMCAT} -Djava.io.tmpdir=${TOMCAT}/temp \ | |
-Djava.util.logging.config.file=${TOMCAT}/conf/logging.properties \ | |
-classpath ${TOMCAT}/bin/bootstrap.jar:${TOMCAT}/bin/tomcat-juli.jar \ | |
org.apache.catalina.startup.Bootstrap start | |
ExecStop=/usr/bin/java $JAVA_OPTS -Dcatalina.base=${TOMCAT} \ | |
-Dcatalina.home=${TOMCAT} -Djava.io.tmpdir=${TOMCAT}/temp \ | |
-Djava.util.logging.config.file=${TOMCAT}/conf/logging.properties \ | |
-classpath ${TOMCAT}/bin/bootstrap.jar:${TOMCAT}/bin/tomcat-juli.jar \ | |
org.apache.catalina.startup.Bootstrap stop | |
SuccessExitStatus=143 | |
[Install] | |
WantedBy=multi-user.target |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment