Dokploy / Dokploy/dokploy

Gitea-linked Compose app silently fails to create the repo webhook (no error, no retry, no repair)

Open
#4,662 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

bug
Dominant language
TypeScript
Stars
37.4k
Forks
3k
Avg merge
1d 3h
Merged PRs (30d)
73

Description

Summary

Linking a Gitea repository to a Compose application (sourceType: gitea, Auto Deploy enabled) does not reliably create the corresponding repo webhook in Gitea. When this happens the failure is silent — there is no error in the Dokploy logs, no retry, and no way to detect or repair it from the UI. Pushes to the repo then never reach Dokploy.

Environment

  • Dokploy: v0.29.8 (Docker)
  • Gitea: 1.26.2
  • Source type: Compose → Gitea (OAuth provider), Auto Deploy = on, Trigger = push

Symptom

On a single Dokploy instance I have 3 Compose apps with sourceType=gitea, autoDeploy=true, identical config (giteaOwner/giteaRepository/giteaBranch set, valid giteaId, valid refreshToken). Created within the last ~10 days.

Querying the Gitea webhook table, only 1 of the 3 repos has a webhook pointing at Dokploy's deploy endpoint:

webhook_id | repo                  | url                                                    | is_active
         3 | lamualfa/centerbuild  | http://<host>:3000/api/deploy/compose/<refreshToken-A> | t

The other two repos (one created today, one ~9 days ago) have no webhook at all — not repo-level, not org-level, not system-level. So git push to those repos lands in Gitea (the internal post-receive hook fires) but nothing is delivered to Dokploy.

For the one repo that does have its webhook, the chain works perfectly — Gitea webhook delivery timestamps map 1:1 to Dokploy deployment rows with status=done. So the deploy side is fine; the problem is the webhook never getting created for the other repos.

Evidence that it's silent

$ docker logs --since 168h dokploy | grep -ic webhook
0

Zero webhook-related log lines over the last 7 days, and zero errors. The missing-webhook condition produces no signal anywhere I could find.

Expected

  • Creating/validating the repo webhook is part of "connect a Gitea source" (per the docs: "the webhook is automatically configured when you connect the repository"). If the creation API call fails (e.g. token state at connect time), Dokploy should:
    • surface the error, and
    • retry, or at least expose a "Repair webhook" / "Re-create webhook" action per Compose app.

Actual

  • Webhook creation silently no-ops for some repos.
  • No error is logged.
  • No retry, no reconciliation, no repair button.
  • The only fix is to manually create the webhook in Gitea (URL …/api/deploy/compose/<refreshToken>, push events, branch filter) or patch the Gitea DB directly.

Reproduction

  1. Stand up Dokploy + a Gitea instance. Connect a Gitea provider (OAuth).
  2. Create a Compose app, source = Gitea, pick a repo/branch, enable Auto Deploy, deploy once.
  3. Check the Gitea repo's webhooks (UI or GET /api/v1/repos/{owner}/{repo}/hooks).
  4. Repeat for several repos. Observe that some repos end up with no Dokploy webhook.

(I can reproduce the missing state, though I haven't isolated which connect-time condition triggers it — possibly OAuth token freshness at the moment the source is linked. Either way, the absence of detection/repair is the core issue.)

Workaround

A reconciliation script that enumerates Dokploy compose apps (sourceType=gitea, autoDeploy=true), derives the expected webhook URL (<dokploy>/api/deploy/compose/<refreshToken>), finds the matching Gitea repo, and creates the webhook if missing. Happy to share if useful.

Related

This lines up with the "Webhook & auto-deploy: a persistent pain point" theme noted in the project's own issues docs, and is adjacent to #4019 (orphan containers on project-name change), which I also hit here.


Thanks for the project — happy to provide more detail or test a fix.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the Gitea source connection and repository-webhook creation flow described in the issue, then reproduce the missing-webhook state across several Compose apps. Done means failures are visible and the webhook can be retried or repaired, with the reproduction steps confirming delivery to Dokploy.

Written by the indexing model from the issue text.

Assessment

Tech stack
docker, typescript
Domain
backend, devops
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.