💎一站式轻松地调用各大LLM模型接口,支持GPT4、智谱、星火、月之暗面及文生图 广告
## 一、说明 流水线」,又名「Flow」,是一款企业级、自动化的研发交付流水线, 提供灵活易用的持续集成、持续验证、 持续发布功能,帮助企业高质量、高效率的交付业务。 流水线是持续交付的载体,通过构建自动化、集成自动化、验证自动化、部署自动化,完成从开发到上线过程的持续交付。通过持续向团队提供及时反馈,让交付过程高效顺畅。 ## 二、创建步骤 ### 1、选择模板 ![](https://cdn.nlark.com/yuque/0/2021/png/682965/1636003755010-fbbac59d-8dae-4594-a104-d5c663187b6e.png)![](https://img.kancloud.cn/56/06/5606bad9eadf2346f11105378684308f_909x785.png) ### 2、填写基本资料 ![](https://cdn.nlark.com/yuque/0/2021/png/682965/1636003837236-ac1603f8-8197-4c54-8aa4-55ab8ba52c88.png)![](https://img.kancloud.cn/6f/9f/6f9fccbff9948701cb9ffa07aca5f66e_1341x1028.png) ### 3、流程配置-添加代码源 ![](https://cdn.nlark.com/yuque/0/2021/png/682965/1636003981074-bac2c830-daa8-4eba-9dd4-d26e987ed290.png)![](https://img.kancloud.cn/43/87/43876dcf49de9a915f7241b74136348b_870x985.png) ![](https://cdn.nlark.com/yuque/0/2021/png/682965/1636004020429-639062a7-64ad-405e-bf2f-82c93a8550a6.png) ### 4、流程配置-构建上传 ![](https://cdn.nlark.com/yuque/0/2021/png/682965/1636004124934-ecaf07c3-ab3a-4a35-bb58-84ac8d78101e.png)![](https://img.kancloud.cn/2a/24/2a248615c826d759abca369484428947_889x1017.png) ![](https://cdn.nlark.com/yuque/0/2021/png/682965/1636004169597-4a589953-2c62-4433-928b-9e4f20f95520.png) ### 5、流程配置-主机部署 ![](https://cdn.nlark.com/yuque/0/2021/png/682965/1636004405025-221929a1-870c-4a15-951b-45c4165b41a9.png)![](https://img.kancloud.cn/1d/9a/1d9a6c812e2513e0de389aded8afeba0_713x929.png) ![](https://cdn.nlark.com/yuque/0/2021/png/682965/1636004426316-a69eb9d4-6f17-4d00-b56a-114197705066.png) ~~~bash cd /usr/ydc/apps/ydc-partner-gateway tar zxvf package.tgz sh start.sh restart ~~~ ~~~bash #!/bin/bash #这里可替换为你自己的执行程序,其他代码无需更改 export JAVA_HOME=/usr/local/java/jdk1.8.0_131 APP_PATH="/usr/ydc/apps/ydc-partner-gateway" APP_NAME="ydc-partner-gateway" FULL_PATH=${APP_PATH}/${APP_NAME}".jar" #启动方法 start(){ pid=`ps -ef|grep $APP_NAME|grep -v grep|awk '{print $2}'` if [ "$pid" ]; then echo "$APP_NAME is already running. pid=$pid ." else nohup $JAVA_HOME/bin/java -jar $FULL_PATH --spring.profiles.active=test >/dev/null 2>&1 & echo $! echo "$APP_NAME now is running" fi } #停止方法 stop(){ pid=`ps -ef|grep $APP_NAME|grep -v grep|awk '{print $2}'` if [ "$pid" ]; then kill -9 $pid echo "Pid:$pid stopped" else echo "$APP_NAME is not running" fi } #输出运行状态 status(){ pid=`ps -ef|grep $APP_NAME|grep -v grep|awk '{print $2}'` if [ "$pid" ]; then echo "$APP_NAME is running. Pid is ${pid}" else echo "$APP_NAME is NOT running." fi } #根据输入参数,选择执行对应方法,不输入则执行使用说明 case "$1" in start) start ;; stop) stop ;; status) status ;; restart) stop sleep 5 start ;; *) echo "Usage:{start|stop|status|restart}" ;; esac exit 0 ~~~