How to bulk change the "Repository Location" of the Fisheye/Crucible repositories

Still need help?

The Atlassian Community is here for you.

Ask the community


This page covers the steps required to change a significant amount of repository location in your Fisheye/Crucible instance.

In particular, it provides a faster alternative to performing the update via the user interface and upload the keys one by one. The following approach required that the same key is used for all repositories.


The main use case is to bulk change the "Repository Location" of the Fisheye/Crucible repositories from http to ssh.

This solution is based on a repository hosted in Bitbucket Server. Please note that the recommended approach is to configure the repositories using the "Bitbucket Server repositories" instead of the "Native repository access" tab.

(info) These changes will not trigger a reindex of the repositories

The first steps are required to create a template repository to be used as a blueprint for the bulk changes and to generate a valid key:

  1. In Fisheye, configure a repository using 
    1. ssh as "Repository Location"
    2. select "Generate key pair for ssh" as "Authentication style"
    3. hit the "Generate" button and add the key
  2. In Bitbucket Server add the generated key to the repository
  3. From Fisheye verify that the connection is successful
  4. Add the generated key to all repositories in Bitbucket Server

Apply the changes to other repositories

  1. Stop Fisheye
  2. Locate the config.xml file in the FISHEYE_INST directory.
  3. Create a backup copy of the config.xml file.

  4. Edit config.xml by applying the following changes

    1. location is the url to be used

    2. remove the password-auth tag and replace it with the ssh-auth, the key-name is the same key available in the template repository just created

      Repository configured via http
      <git location="http://<username>@<ip>:7990/scm/<project_slug>/<repository_key>.git" renames="none">
      	<password-auth password="<password>"/>
      Repository configured via ssh
      <git location="ssh://git@<ip>/<project_slug>/<repository_key>.git" renames="none">
      	<ssh-auth key-name="<key_name_from_the_blueprint_repository"/>
  5. Restart Fisheye
  6. Remove the template repository

Other use cases

The same procedure can be used in similar use cases.

Use case #1 - update the ip / hostname of the Git server

The same steps as above can be followed. The <ip> part in the location attribute will need to be updated accordingly.

Last modified on Jul 31, 2018

Was this helpful?

Provide feedback about this article
Powered by Confluence and Scroll Viewport.