Remove Dokploy webhook from workflow
All checks were successful
Build and deploy Flutter Web / build (push) Successful in 3m3s

This commit is contained in:
Ruslan Bakiev
2026-05-13 14:33:48 +07:00
parent 765219cc20
commit 8c7e62d9e1

View File

@@ -12,7 +12,6 @@ jobs:
SERVICE_NAME: flutter
IMAGE_SHA: gitea.dsrptlab.com/mapflow/flutter:${{ github.sha }}
IMAGE_LATEST: gitea.dsrptlab.com/mapflow/flutter:latest
DOKPLOY_DEPLOY_WEBHOOK: http://sin.dsrptlab.com:3000/api/deploy/b7iCKmvlGMU-2HmI79fcC
steps:
- uses: actions/checkout@v4
@@ -46,32 +45,6 @@ jobs:
--build-arg TELEGRAM_BOT_USERNAME="carfteebot" \
.
- name: Skip stale deployment
run: |
set -euo pipefail
latest_sha="$(git ls-remote origin refs/heads/main | awk '{print $1}')"
if [ "$latest_sha" = "${GITHUB_SHA}" ]; then
touch .deploy-current
else
echo "A newer main commit exists: $latest_sha. Skipping deploy for ${GITHUB_SHA}."
fi
- name: Trigger Dokploy webhook
run: |
set -euo pipefail
[ -f .deploy-current ] || exit 0
payload=$(cat <<JSON
{"ref":"refs/heads/main","after":"$GITHUB_SHA","commits":[{"id":"$GITHUB_SHA","message":"$SERVICE_NAME #${GITHUB_RUN_NUMBER:-0} ${GITHUB_SHA:0:7}"}]}
JSON
)
response_file="$(mktemp)"
status_code="$(curl -sS -o "$response_file" -w "%{http_code}" -X POST "$DOKPLOY_DEPLOY_WEBHOOK" \
-H "x-gitea-event: push" \
-H "Content-Type: application/json" \
-d "$payload")"
cat "$response_file"
[ "$status_code" = "200" ]
- name: Prune shared BuildKit cache
run: |
set -euo pipefail