This commit is contained in:
acgist
2022-11-18 08:26:33 +08:00
parent 76d8780040
commit 7ebac2e092
10 changed files with 151 additions and 101 deletions

View File

@@ -31,5 +31,6 @@ fi
cp -rf ${project.basedir}/target/${project.artifactId}-${project.version}/* $base/../deploy/${project.artifactId}
# 启动服务
cd $base/../deploy/${project.artifactId}
sh bin/startup.sh
#cd $base/../deploy/${project.artifactId}
#sh bin/startup.sh
systemctl restart taoyao

17
docs/bin/taoyao.service Normal file
View File

@@ -0,0 +1,17 @@
[Unit]
Description=桃夭
After=network.target
Wants=network.target
[Service]
User=root
Type=forking
KillMode=process
ExecStart=/data/taoyao/bin/startup.sh
ExecReload=/bin/kill -HUP $MAINPID
ExecStop=/bin/kill -QUIT $MAINPID
Restart=always
RestartSec=5s
[Install]
WantedBy=multi-user.target