ci: update deploy.json on web after each release via docker exec
Some checks failed
release / build-and-release (push) Failing after 30s

Adds docker-cli to build container (docker socket passed through by runner)
and writes sha + timestamp to xetup-web container after successful release.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
X9 Dev 2026-04-21 09:59:47 +02:00
parent c6a166f119
commit 2be9e4e827

View file

@ -26,7 +26,7 @@ jobs:
- name: Setup - name: Setup
working-directory: / working-directory: /
run: | run: |
apk add --no-cache git curl jq mingw-w64-gcc apk add --no-cache git curl jq mingw-w64-gcc docker-cli
git clone --depth=1 \ git clone --depth=1 \
"http://x9:${{ secrets.FORGEJO_TOKEN }}@xetup-forgejo:3000/${{ github.repository }}.git" \ "http://x9:${{ secrets.FORGEJO_TOKEN }}@xetup-forgejo:3000/${{ github.repository }}.git" \
/repo /repo
@ -80,3 +80,11 @@ jobs:
--data-binary @xetup.exe --data-binary @xetup.exe
echo "Released xetup.exe (commit ${SHORT})" echo "Released xetup.exe (commit ${SHORT})"
- name: Update deploy.json
run: |
SHORT=$(echo "${{ github.sha }}" | cut -c1-7)
TS=$(date -u +%Y-%m-%dT%H:%M:%SZ)
docker exec xetup-web sh -c \
"echo '{\"sha\":\"${SHORT}\",\"ts\":\"${TS}\"}' > /usr/share/nginx/html/data/deploy.json"
echo "deploy.json updated: ${SHORT} at ${TS}"