ci: 云端发布改为 tag 触发(push v* 即审核发布),clone 动态 ref
All checks were successful
部署-局域网 / deploy (push) Successful in 4s
发布-云端 / deploy (push) Successful in 7s

This commit is contained in:
dafe
2026-11-02 15:15:40 +08:00
parent 02816ed932
commit 22cd96a948
2 changed files with 12 additions and 9 deletions

View File

@@ -1,5 +1,6 @@
name: 部署-局域网
# push 到 main 即自动上线 51.66(无人工环节)
# 合并/推送到 main 即自动上线 51.66(集成分支 = 内部预发布环境)
# feature 分支的 push 不触发,开发期不影响线上
on:
push:
branches: [main]
@@ -10,7 +11,7 @@ jobs:
steps:
- name: 拉取代码
run: |
git clone --depth 1 "http://dafe:${{ secrets.GITHUB_TOKEN }}@192.168.51.66:3000/dafe/homepage.git" site
git clone --depth 1 --branch "${GITHUB_REF_NAME}" "http://dafe:${{ secrets.GITHUB_TOKEN }}@192.168.51.66:3000/dafe/homepage.git" site
- name: 注入构建版本号(缓存击穿,版本=commit 短 SHA)
run: |