Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-22694

Username / password rejected by https access to private bitbucket repo

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Major Major
    • git-client-plugin
    • None
    • Jenknis 1.544.1 RC, git-client-plugin 1.8.0, git-plugin 2.2.1

      I created a private bitbucket git repository and tried to clone it to each of my Jenkins slave agents using a username/password credential for my bitbucket account.

      The job definition page reports that the repository access is denied.

      If the same job definition, Git url, and credentials are used, but the bitbucket repository is public, then access is allowed and the repository can be cloned and changes can be pushed back to it.

      If the same private repository is used with ssh credentials, then access is allowed and the repository can be cloned, and changes can be pushed back to it.

      When the job ran with the private repository, the slave machines running JNLP popped up a Java authentication dialog asking for the user name and password for bitbucket.org. JNLP agents should not prompt for username and password, and the git-client-plugin should use my valid username and password as entered instead of prompting for authentication.

      Steps I took to show the problem:

      1. Define a domain specific credential for bitbucket.org
      2. Define a credential in that domain for my username and password
      3. Define a job which runs on all my slave agents (I used the elastic-axis plugin to make that easier)
      4. Use git as the source repository for that job
      5. Use my bitbucket repository and credentials for that job (I used https://bitbucket.org/markewaite/git-client-plugin.git)
      6. Run the job, and watch the consoles of those slave computers using JNLP

      So long as the repository is public, the https access method works for read and for write. If the repository is private, the https access method no longer works.

            markewaite Mark Waite
            markewaite Mark Waite
            Votes:
            1 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: