i’m running Drone server on version 1.9.1 and it is working like a charm.
I’ve tried to update our setup to 1.10.1 and 2.0.1 and when i upgrade the server and the users are sync again from bitbucket server write permissions are not fetched properly from bitbucket causing users with write permissions not able to restart builds, configure secrets etc.
IE:
while running 1.9.1 if i check the api for a test user i created, i can see for both projects that the user has write permissions.
After digging into the code of go-scm library i’ve found that you changed the request to fetch the repositories with write permissions while calculating the permissions.
But this query, at least in our bitbucket server 7.6.0, it does not work.
ie: /rest/api/1.0/repos?size=1000&permission=REPO_WRITE&name=flux-releases&projectname=CP
But if I run the previous request /rest/api/1.0/repos?size=1000&permission=REPO_WRITE&name=flux-releases&project=CP then i get a nice
{"size":1,"limit":25,"isLastPage":true,"values":[{"slug":"flux-releases","id":901,"name":"flux-releases","hierarchyId":"b92d25b5e263aefe386d","scmId":"git","state":"AVAILABLE","statusMessage":"Available","forkable":true,"project":{"key":"CP","id":289,"name":"Container Platform","description":"This project is used to build the container platform infrastructure","public":false,"type":"NORMAL","links":{"self":[{"href":"https://bitbucket.voiceworks.com/projects/CP"}]}},"public":false,"links":{"clone":[{"href":"https://bitbucket.voiceworks.com/scm/cp/flux-releases.git","name":"http"},{"href":"ssh://git@bitbucket.voiceworks.com/cp/flux-releases.git","name":"ssh"}],"self":[{"href":"https://bitbucket.voiceworks.com/projects/CP/repos/flux-releases/browse"}]}}],"start":0}
Could you please verify it? this is preventing us to upgrade drone from 1.9.1 where it was working fine