Search Unity

How to change Unity Cloud build SSH key?

Discussion in 'Unity Cloud Build' started by jim00, Apr 21, 2017.

  1. jim00

    jim00

    Joined:
    Feb 1, 2015
    Posts:
    41
    I'm using Bitbucket git to connect to Unit Cloud Build, but when Unity ask me to enter the SSH key into Bitbucket. Bitbucket give me an error of "Someone has already registered that SSH key"

    How do I get a new SSH key from Unit Cloud Build?

    Thanks.
     
  2. SophiaC

    SophiaC

    Unity Technologies

    Joined:
    Sep 6, 2016
    Posts:
    236
    Hello,

    If you have added the SSH key to a repo previously, you will need to remove it from there first before you can add it to the BitBucket repo.

    If you're unsure where your key is being used, follow the instructions detailed here: https://help.github.com/articles/error-key-already-in-use/

    We provide the public key, which means you can configure as many hosts as you want with access to that public key. The restriction about adding a key more than once is something enforced by Bitbucket, GitHub, etc- not by us. The SSH key is shared across the organization, so is there any chance that someone could have already added it?

    - Sophia
     
  3. Gamegineer

    Gamegineer

    Joined:
    Jan 5, 2013
    Posts:
    5
    From the document you linked to:
    I no longer have permission to remove the key from the bitbucket account it was attached to so I need a new key pair created on the Cloud Build side.
     
    yoshida_nurve likes this.
  4. ross_unity

    ross_unity

    Joined:
    Oct 19, 2017
    Posts:
    7
    So, if a team member deletes a git repo containing your deploy key before it's removed then you're SOL?

    ...great design Unity team.
     
  5. Iamdain

    Iamdain

    Joined:
    Feb 3, 2010
    Posts:
    90
  6. ollieblanks

    ollieblanks

    Unity Technologies

    Joined:
    Aug 21, 2017
    Posts:
    174
    If the SSH key is already in use, you no longer have access to remove it from the repository and you need to regenerate a new one, you can do so using the Cloud Build API
     
  7. rafaelloopix

    rafaelloopix

    Joined:
    Oct 5, 2018
    Posts:
    2
    I'm with the same problem and I'm trying to generate a new SSH, but I can't find the "Organization Identifier" as requested by the API.

    First time trying Cloud Build and I don't know why says that the SSH is already in use.
     
  8. victorw

    victorw

    Unity Technologies

    Joined:
    Sep 14, 2016
    Posts:
    143
    If you go to your Organizations page (https://id.unity.com/organizations) it will list all of your organization names - typically the identifier is just the name but if it is not then you will be able to find it by looking for whatever comes immediately after the
    /orgs/
    in the path for one of your projects.