New Organization - confused about plans and scans

I have had several repos in my SonarCloud which until now resided in my personal GitHub account.

I have now created 2 organisations in GitHub to which I assigned several of my repositories.

I noticed that in my sonar cloud the existing repos which had been analysed in past, do not seem to get data from the repo since I moved them to the specific orgs in GitHub.

So I tried to add a new org in sonar cloud (import from GitHub) but at that point, it asks me what plan to choose. I do have a Paid plan (10usd), but what is not clear to me is if I need to pay for each new org?
Or does it just take in account my actual paid plan when I select “Paid” for the new org?

On the other hand, how can I continue analysing my project, even if it is not anymore in my personal GitHub?
It can’t be that just because I moved it to an org on Github (which belongs solely to me), I have to pay for a new plan? (That repo is still private even though on a new org in Github)

Thank you for any clarifications!

This is relatively urgent for me - being it a financial issue, perhaps I posted it in the wrong place?

Hey there.

Billing is done at an organization-level, not an account-level. If that private repository now exists in your personal organization, you will need a subscription for your personal organization.

1 Like

Thanks @Colin

I have published the private repo in that new org, so I do not need the paid plan on that new org yet.

Now, I have had the repo previously in my private GitHub and have it added to my SonarCloud (but in the other project which is on the paid plan)

I moved the repo to my new Org on Github. The SonarCloud now obviously does not scan that code anymore. How can I move the current existing project in SonarCloud to the new Org?
(I do not want to lose history if possible. If it is not possible I will just delete the project and set it up again in the new org in Sonar)

Thanks

UPDATE
I notice that all my projects I had moved from my personal GitHub repo to the orgs is not anymore scanned with Sonarcloud.
I cannot find a place where to edit those Sonarcloud “GitHub repo links”
Do I have to delete them all?

Hey there.

Unfortunately, i’s not possible to move a project between organizations – you will need to delete the project from your old organization and recreate it in your new organization.

1 Like

I am sorry to reopen this @Colin - there are more issues on this

See, I initially created a GitHub Account with my personal user but called it {Org name}.
I then created a sonar cloud “org” and called it {Org name}.

So now I have a sonar account that in fact looks like my {Org name} but it is not
When I try to import the real org from Github it tries to give it a name as in {Org name-1}

What I need is:

  1. Keep both my real GitHub orgs in the sonar cloud
  2. Best case, keep my personal account and keep the paid plan on it so I can, if necessary, also analzyse private repos - it is fine if I have to run those private repos on my personal GitHub account instead of one of the orgs. I understand you cannot move/extend the paid account to other “instances”.

But right now I am in a mess because none of my repos are analysed (since they all have been ported to the orgs on GitHub and are not anymore on my personal GitHub account) and I cannot create a proper new org on sonar with the proper name since it exists already :(, however that existing org is not the org that exists on Github!

(I created a new org on GitHub, after changing my own personal account name, which previously was {Org name}. This way, I was able to keep my personal account and create a new org with that name. Hope it makes sense)

And yet!
In sonar, the existing org says it is bound to the org on GitHub, but it clearly is not, because it lets me import it again!

I think what happens here is that sonar cloud does not recognise that the TukuToi (previously a personal github) is now a real org on GitHub…

@Colin - sorry to nag here, it is kind of stuck in my business right now due to the mess I made.

Can we fix this somehow?

Thank you for your time.

I have a problem with my paid subscription, as elaborated here:

I cannot seem to get a hold of an answer, probably because that thread was closed by me mistakenly as solved and then reopened.

I would need to resolve that, otherwise I will have to cancel the subscription as it doesn’t allow me to add the new organization from GitHub, since it has the same name as current existing personal SonarCloud org.

Hi @smileBeda,

I’ve consolidated your new post with the old since they’re really the same topic. Sorry for delay in responding. The team is investigating.

 
Ann

Hello @ganncamp - I am really sorry to nag, but is there some news as of how I could proceed?

All my projects are currently failing scans due to this, it is not a minor amount thereof.

I mean, to make it simple maybe I should just delete the current account and set it up again, but then agin, I would have to cancel the subscription to do so…

Hello @smileBeda !

I’m investigating this issue and I would like to understand better what’s the problem to see if I’m able to duplicate it. I will start by trying to summarize the latest information about what I understand your issue is.

I understand that you (please feel free to correct me if I’m wrong):

  • Have two Github accounts: personal and sonarcloud
  • Both accounts have the same organization name at Github level
  • You moved repos that were in your personal account org to this other new org in Github
  • You created a new org on Github, after changing your own personal account name, so you were able to keep both your personal account and the new org with the required name.

Current issues → All your project are currently failing scans and you have two organizations in SonarCloud with names not corresponding to the Github organizations.

I have a question for you, when changing the organization key did you also make the same change to the sonar.organization setting of every project in the organization that is configured for CI-based analysis? [1]

If you could provide me a screenshot or provide me more info about the errors shown in the projects failing scans that would be great for me to continue investigating.

Ref:
[1] Managing your Organization | SonarCloud Docs

Hello @aura

Let me explain this with the history behind it.

  1. I initially had a GitHub account (personal) but used the name tukutoi for it instead of my personal name.
  2. I created a sonar account and created an organization in sonar, by importing my GitHub - that automatically created the sonar org as well with the handle tukutoi
  3. Later I changed my GitHub personal to smilebeda and created a GitHub org with tukutoi
  4. I moved several repos from the smilebeda to tukutoi
  5. On sonar, this change did not change the name of the sonar org. It is still tukutoi. But in fact… it should be smilebeda, since that is now the name of the original GitHub it was connected to.
  6. All scans fail because obviously the repos are not anymore on the original GitHub. They are now on the org in GitHub with name tukutoi, instead of the personal which now has name smilebeda and formerly was tukutoi
  7. Sonar now offers me to add a new org and import from GitHub… the tukutoi GitHub org.
  8. If I want to complete that import, it tells me that… sonar is already having an org with that name (since that is what I created in the very begin)

So now when I want to import Github tukutoi org on sonar, it shows me this. Note the -1

One of the repos that was before in my personal account, and scanned by sonar, and now is moved to the GitHub org, will not be scanned anymore, it is “stuck” on the last release made back when it was in my personal account, see

That is just an example, it happens for all those repos that moved.

What I “want”:

  • have a sonar account with 2 orgs: tukutoi and uhlelox
  • both orgs are also actual GitHub orgs
  • a “personal” sonar (best would be with name === GitHub name so that means smilebeda) so I can also scan my personal GitHub repos, of which some are private (so for this I need the paid subscription)

I already am aware that I most likely will have to delete and recreate the sonar projects, which is suboptimal because I will lose the “history” but I am ready to deal with that
The real problem is, that right now I cannot import my new GitHub org (tukutoi) because sonar is already set up as an “organization” with that name due to my step 1 and 2 above

I already tried to delete the current sonar tukutoi, but it tells me that the subscription will be lost, since it is bound to that sonar org with handle tukutoi

I hope this makes sense. I think the simplest solution probably is to erase my sonar instance and recreate everything inclusive the account, but… not sure, I’ll let you expert advice lead my next actions before I do more mess.

1 Like

Hello @smileBeda !

Thank you so much for the detailed explanation.

I believe that the problem is related to your organization’s keys in SonarCloud. Could you please modify the organization name and key originally created for your Github personal account to smilebeda (or any other key) and then try to import the new tukutoi Github organization to SonarCloud? You can modify the organization name and key under Administration > Organization settings [1].

At the moment, SonarCloud doesn’t recognize changes related to the GitHub organization’s name modifications, and having SonarCloud make the changes automatically could potentially impact the other settings related to CI-based analysis. Therefore, it’s up to the user to keep the changes in sync.

About losing the history of the projects, that’s true since organizations can’t be re-bound [2].

Please do let me know if the suggestion above solves the issue. Having modified the key from tukutoi in SonarCloud will make the key available but let me know if it’s not the case.

Refs (please note both are different links to our documentation sections):
[1] Managing your Organization | SonarCloud Docs
[2] Managing your Organization | SonarCloud Docs

1 Like

Ok, that seems to have done the trick.

You know what is confusing? That I have to create an organization in SonarCloud - even thou, actually “I” am not an organization.

Like - my 2 GitHub ORGs are indeed organisations, but my personal GitHub is not. Yet in SonarCloud that is considered an org.
I think otherwise I would have figured this out as well sooner or later :stuck_out_tongue:

PS:
I had to delete all projects from my personal SonarCloud and then I was able to import them into the new orgnization

All good, thanks!

1 Like

AAAARGH no it is not solved.

Now both my personal SonarCloud with new Key and my new SonarCloud org with key tukutoi are bound to the Github tukutoi
But my personal Sonar should not be bound to that repo, instead, it should be bound to my personal GitHub

Any way I can change that?

Thank you

OK, was able to figure this one out on my own - deleted the app in the GitHub settings, and re-bound it.

3 Likes

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.