Skip to content

Instantly share code, notes, and snippets.

@UZPENG
Last active February 24, 2018 13:14
Show Gist options
  • Save UZPENG/924ab1c613e406a488339ddf8b5f93ec to your computer and use it in GitHub Desktop.
Save UZPENG/924ab1c613e406a488339ddf8b5f93ec to your computer and use it in GitHub Desktop.
centos配置tomcat由systemd控制
[Unit]
Description=Apache Tomcat Web Application Container
After=syslog.target network.target
[Service]
Type=forking
PIDFile=/opt/tomcat/tomcat.pid
ExecStart=/opt/tomcat/bin/catalina.sh start
ExecReload=/bin/kill -s HUP $MAINPID
ExecStop=/bin/kill -s QUIT $MAINPID
PrivateTmp=true
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