我是靠谱客的博主 开放小海豚,这篇文章主要介绍springboot项目运行shell,现在分享给大家,希望可以做个参考。

#启动脚本文件
deploy.sh

#!/bin/bash
echo "publish----------"

process_id=`ps -ef | grep wiki.jar | grep -v grep |awk '{print $2}'`
if [ $process_id ] ; then
sudo kill -9 $process_id
fi

source /etc/profile
nohup java -jar -Dspring.profiles.active=prod /home/wwwroot/wiki/wiki.jar > /dev/null 2>&1 &

echo "end publish"

#执行脚本
sh deploy.sh

最后

以上就是开放小海豚最近收集整理的关于springboot项目运行shell的全部内容,更多相关springboot项目运行shell内容请搜索靠谱客的其他文章。

本图文内容来源于网友提供,作为学习参考使用,或来自网络收集整理,版权属于原作者所有。
点赞(184)

评论列表共有 0 条评论

立即
投稿
返回
顶部