• Icon: Story Story
    • Resolution: Fixed
    • Icon: Blocker Blocker
    • blueocean-plugin
    • None
    • tethys, Blue Ocean 1.2-beta2, Blue Ocean 1.2-beta3, Blue Ocean 1.2-beta4, Blue Ocean 1.2

      Improvement on roadmap

      This improvement is on the Blue Ocean project roadmap. Check the roadmap page for updates.

      Story
      Developer can create a pipeline using a Bitbucket Server repository. Branches are automatically discovered and built. If the branch does not contain a Jenkinsfile the developer can use the pipeline editor to create their first Pipeline. The pipeline can be edited and saved at any time.

      Requirements

      • Only username and password credentials are supported
      • Use Bitbucket Server content API
        • If we can't do this then we are blocked
      • Keep one credential per user and per Bitbucket URL to avoid the user having to enter their username/password multiple times
        • Handle domain like the Github Enterprise implementation

      Running Bitbucket server
      Run Bitbucket server using docker

          [JENKINS-41295] Support Bitbucket Server in Blue Ocean

          Vivek Pandey added a comment -

          Instructions here works:

          https://bitbucket.org/atlassian/docker-atlassian-bitbucket-server

          Tried locally on Mac, brings up bitbucket just fine:

          docker run -v bitbucketVolume:/var/atlassian/application-data/bitbucket --name="bitbucket" -d -p 7990:7990 -p 7999:7999  atlassian/bitbucket-server:5.0 
          

          Vivek Pandey added a comment - Instructions here works: https: //bitbucket.org/atlassian/docker-atlassian-bitbucket-server Tried locally on Mac, brings up bitbucket just fine: docker run -v bitbucketVolume:/ var /atlassian/application-data/bitbucket --name= "bitbucket" -d -p 7990:7990 -p 7999:7999 atlassian/bitbucket-server:5.0

          Cliff Meyers added a comment -

          michaelneale Any thoughts on how we could support this environment in CI?

          Cliff Meyers added a comment - michaelneale Any thoughts on how we could support this environment in CI?

          James Dumay added a comment -

          cliffmeyers I was discussing it with vivek this morning. We might try creating a JUnitRule to spin up a docker container with Bitbucket Enterprise on it for end to end ATH. vivek is working on the backend implementation JENKINS-44666 and that will be unit tested using a mocked server.

          James Dumay added a comment - cliffmeyers I was discussing it with vivek this morning. We might try creating a JUnitRule to spin up a docker container with Bitbucket Enterprise on it for end to end ATH. vivek is working on the backend implementation JENKINS-44666 and that will be unit tested using a mocked server.

          Vivek Pandey added a comment -

          jamesdumay Bitbucket supports different repo types, git and hg. We support both out of the box? it affects bundled dependency (on hg) and testing etc.

          Vivek Pandey added a comment - jamesdumay Bitbucket supports different repo types, git and hg. We support both out of the box? it affects bundled dependency (on hg) and testing etc.

          James Dumay added a comment - - edited

          vivek lets disable support for mercurial for the time being. Usage stats these days are very low. Lets ensure that if you try to create a repo with it that you get error early on in creation saying that it is unsupported

          BTW, Bitbucket Enterprise does not support mercurial. Bitbucket Cloud has mercurial support for largely historical reasons (it used to be the "Github for Mercurial").

          James Dumay added a comment - - edited vivek lets disable support for mercurial for the time being. Usage stats these days are very low. Lets ensure that if you try to create a repo with it that you get error early on in creation saying that it is unsupported BTW, Bitbucket Enterprise does not support mercurial. Bitbucket Cloud has mercurial support for largely historical reasons (it used to be the "Github for Mercurial").

          Vivek Pandey added a comment -

          jamesdumay Ok. Didn't realize their server product doesn't support mercurial. So I tried creating new repo, only git repo is possible.  

          Their APIs, which are generic where list of repos could be git and hg, there is repoType field. To be correct, its very easy to filter by repo type, basically, we can return only the list of 'git' repos, this way  users only see their git repos and there is no need to flag error. 

          Vivek Pandey added a comment - jamesdumay  Ok. Didn't realize their server product doesn't support mercurial. So I tried creating new repo, only git repo is possible.   Their APIs, which are generic where list of repos could be git and hg, there is repoType field. To be correct, its very easy to filter by repo type, basically, we can return only the list of 'git' repos, this way  users only see their git repos and there is no need to flag error. 

          James Dumay added a comment -

          I'd rather we were explicit and showed them an error when selecting a Mercurial repository. It's strange that we would show them the filtered list and them not see their repository (then we get bugs asking why)

          James Dumay added a comment - I'd rather we were explicit and showed them an error when selecting a Mercurial repository. It's strange that we would show them the filtered list and them not see their repository (then we get bugs asking why)

          James Dumay added a comment -

          I'd Atlassian come along and implement Mercurial in server then we want to handle that case (show an error)

          James Dumay added a comment - I'd Atlassian come along and implement Mercurial in server then we want to handle that case (show an error)

          Vivek Pandey added a comment -

          Sounds good to me.

          Vivek Pandey added a comment - Sounds good to me.

          James Dumay added a comment -

          Maybe we should build in "type" to all of the branch sources? Then the error could be generic

          James Dumay added a comment - Maybe we should build in "type" to all of the branch sources? Then the error could be generic

            vivek Vivek Pandey
            jamesdumay James Dumay
            Votes:
            0 Vote for this issue
            Watchers:
            6 Start watching this issue

              Created:
              Updated:
              Resolved: