Compare commits

...

2 Commits

Author SHA1 Message Date
a620906209 127101adb3 Merge pull request 'fix: 修正 CI 並發 fetch 導致 git ref 衝突' (#18) from fix/sentry-composer into master
Deploy Production / deploy (push) Failing after 1s
Reviewed-on: #18
2026-05-28 19:03:13 +00:00
a620906209 0160d72467 fix: 修正 CI 並發 fetch 導致 git ref 衝突
git pull 改為 flock + fetch + reset --hard:
- flock 防止兩次 CI 同時更新 ref 產生 race condition
- reset --hard 比 pull 更適合 CI 環境,不做 merge

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-05-29 03:00:57 +08:00
+2 -1
View File
@@ -12,7 +12,8 @@ jobs:
- name: Pull latest code - name: Pull latest code
run: | run: |
cd /root/myproject/CFDivePlatform cd /root/myproject/CFDivePlatform
git pull flock -w 30 /tmp/cfdive-deploy.lock git fetch origin
git reset --hard origin/master
- name: Install Composer dependencies - name: Install Composer dependencies
run: | run: |