Bitbucket Server webhook is not providing git URL is response payload.


Platform notice: Server and Data Center only. This article only applies to Atlassian products on the Server and Data Center platforms.

Support for Server* products ended on February 15th 2024. If you are running a Server product, you can visit the Atlassian Server end of support announcement to review your migration options.

*Except Fisheye and Crucible

Summary

Bitbucket Server Webhook is only providing either SSL or HTTP/HTTPS URL in response and not providing git URL (git://host.xz/path/to/repo.git) in the response payload.

Environment

7.15.1

Cause

Bitbucket Server or Data Center does not support git protocol and due to this reason - no git protocol URL (git://host.xz/path/to/repo.git) is present in the Webhook Response payload.

One of the common reasons for this is - As we know Git can use four distinct protocols to transfer data: Local, HTTP, Secure Shell (SSH) and Git. Out of these, the GIT protocol provides a service similar to the SSH protocol, but with absolutely no authentication. In order for a repository to be served over the Git protocol, you must create a git-daemon-export-ok file — the daemon won’t serve a repository without that file in it — but, other than that, there is no security. Either the Git repository is available for everyone to clone, or it isn’t. This means that there is generally no pushing over this protocol. You can enable push access but, given the lack of authentication, anyone on the internet who finds your project’s URL could push to that project.

Solution

This is the expected behaviour of the Bitbucket Server or Data Center that does not support git protocol.

Last modified on Mar 24, 2022

Was this helpful?

Yes
No
Provide feedback about this article
Powered by Confluence and Scroll Viewport.