-
Bug
-
Resolution: Done-Errata
-
Major
-
4.10
-
Moderate
-
None
-
ODC Sprint 242
-
1
-
Rejected
-
Unspecified
-
If docs needed, set a value
==> Description of problem:
"Import from git" functionality with a local Bitbucket instance does not work, due to repository validation that requires to repository to be hosted on Bitbucket Cloud. [1][2]
==> Version-Release number of selected component (if applicable):
Tested in OCP 4.10
==> How reproducible: 100%
==> Steps to Reproduce:
1. Go to: Developer View > Add+ > From Git
2. Fill the "Git Repo URL" field with the BitBucket repo URL (i.e. http://<bitbucket_url>/scm/<project>/<repository>.git)
3. Select BitBucket from the "Git type" dropdowns button
==> Actual results:
"URL is valid but cannot be reached. If this is a private repository, enter a source Secret in advanced Git options"
==> Expected results:
This functionality should work also with hosted Bitbucket
==> Additional info:
To retrieve slug information from hosted BitBucket we can query: http://<bitbucket_url>/rest/api/1.0/projects/<project>/repos/<repository>
An example:
~~~
curl -ks http://bitbucket-server-bitbucket.apps.gmeghnag.lab.cluster/rest/api/1.0/projects/test/repos/test-repo | jq
{
"slug": "test-repo",
"id": 1,
"name": "test-repo",
"hierarchyId": "28fc5c8782050b43e223",
"scmId": "git",
"state": "AVAILABLE",
"statusMessage": "Available",
"forkable": true,
"project": {
"key": "TEST",
"id": 1,
"name": "test",
"public": false,
"type": "NORMAL",
"links": {
"self": [
]
}
},
"public": true,
"archived": false,
"links": {
"clone": [
,
{ "href": "ssh://git@bitbucket-server-bitbucket.apps.gmeghnag.lab.cluster:7999/test/test-repo.git", "name": "ssh" } ],
"self": [
]
}
}
~~~
- links to
-
RHEA-2023:5006 rpm