From d2ee139c2f818751f9fd4c903b42cb168b96c5fb Mon Sep 17 00:00:00 2001 From: arlenops Date: Thu, 20 Nov 2025 12:53:25 +0800 Subject: [PATCH] =?UTF-8?q?=E6=96=B0=E5=A2=9E=E8=87=AA=E5=8A=A8=E5=8C=96?= =?UTF-8?q?=E6=96=87=E4=BB=B6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .drone.yml | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) create mode 100644 .drone.yml diff --git a/.drone.yml b/.drone.yml new file mode 100644 index 0000000..d3676d4 --- /dev/null +++ b/.drone.yml @@ -0,0 +1,19 @@ +kind: pipeline +name: default + +steps: + - name: Pull latest code from Gitea + image: alpine:latest + commands: + - apk add --no-cache git + - cd /www/wwwroot/hgdemo.hgidc.cn/public/web/BlackFruit-web + - git clone https://yiqiu:ycyawCOM996.@gitea.ycyaw.com/yiqiu/BlackFruit-UI.git . || git pull + - ls -l # 查看目录中的文件是否已经更新 + + - name: Restart Nginx + image: alpine:latest + commands: + - apk add --no-cache nginx + - nginx -s reload # 重新加载 Nginx 配置,确保服务更新 + when: + branch: main # 只在 main 分支触发,防止其他分支的提交也触发重启