Preview deployments not working due to redirect
Preview deployments don't work due to webhook requests responding with 301
{"message":"Branch Not Match"}
. Regular deployments work as intended4 Replies
The base branch is
main
which is the branch normal deployments usePreview deployments inherit the redirects or security from your main application https://docs.dokploy.com/docs/core/applications/preview-deployments#automatic-updates
Preview Deployments | Dokploy
Preview deployments allow you to test and review your application changes in an isolated environment before merging to production.
All events fail except
push
events to the main
branch with the same 301 response body {"message":"Branch Not Match"}

this is consident across projects
Here's my traefik.yml
I host dokploy and all application behind cloudflare for DNS in strict mode for HTTPS using origin certs
My assumption might be that it's redirecting non-http traffic, but all events have that same body in the response,
{"message":"Branch Not Match"}
which makes me suspect it's something to how dokploy configures github webhooks
I found the issue. The problem was using an explicit webhook as opposed to the github application. I had to turn off the webhook ensure the github app was correctly configured. Hope this helps if anyone else stumbles across the same problem!