jenkinsci/bitbucket-branch-source-plugin

Could not find: owner

Z9n2JktHlZDmlhSvqc9X2MmL3BwQG7tk opened this issue · 7 comments

Jenkins and plugins versions report

Environment
Jenkins - 2.332.2 (official docker image jenkins/jenkins:lts-alpine)
Plugin version - 762.v969cfe087fc0

What Operating System are you using (both controller, and any agents involved in the problem)?

Ubuntu Linux 18.04, Docker 20.10.12

Reproduction steps

Edit existing job configuration

Expected Results

See correct repository name in drop down list.

Actual Results

See "Could not find: my_bitbucket_user" message.

Anything else?

Problem is similar to #295 and https://issues.jenkins.io/browse/JENKINS-64157. I am using Username/Password credentials, which successfully worked before.

Is this with Bitbucket Cloud, Server, or Data Center?

Bitbucket Cloud (bitbucket.org)

May be, how to know exactly ? I do not know how plugin works within. And in any case I don't understand what to do with Jenkins jobs - how to create/edit them, because Bitbucket Branch Source plugin does not allow to use ssh key credential for authentication when we set job repository, it allows Username/Password credential only.

It would be very nice to remove repositories list request during job setup and allow just to specify repo URL (or owner + repo name) in simple text input.

I don't use Bitbucket Cloud myself, but I believe you'll need to edit the username-and-password credential in Jenkins and make sure the username matches your Bitbucket Cloud username (not email address) and the password matches the app password that you created in Bitbucket Cloud. These changes will then affect all the Jenkins jobs that have been configured to use this credential.

I don't think it would be a good idea to change the plugin to allow typing in a repository slug without having a valid credential to the REST API of Bitbucket Cloud. AFAIK, if the plugin does not have such a credential, it cannot report build statuses or discover pull requests.

Yes, you are right ! Tried to create app password for Jenkins and all began to work.
Ticket can be closed, thanks !

I don't have the authority to close issues here…