How can I associate a subscription with a new tenant in Azure? - azure

I have a Visual Studio Pro subscription through my work, and when I log into the Azure portal I can see a directory representing my work under my account name in the top corner.
As far as I can tell "directory" and "tenant" are used interchangeably in the Azure documentation. So I wanted to create a new tenant as a playpen to allow me to experiment with Azure. I was able to do that but now when I try to log in to that tenant via Azure CLI I get an error "No subscriptions found.". This despite when I log into my work tenant it tells me I have a Visual Studio Professional Subscription.
Is it possible to set up a different tenant/directory for the same account, to use as a playpen, and somehow connect it with my VS Pro subscription? If so, how?

I guess the simplest thing you could do is invite a user from your playpen directory by assigning them a suitable RBAC role in your VS Pro Subscription. That way when you login using your playpen directory account and try to list subscriptions, you will find your VS Pro subscription there.
Other option would be to associate your Azure Subscription to your playpen directory. Please see this link for more details: https://learn.microsoft.com/en-us/azure/active-directory/fundamentals/active-directory-how-subscriptions-associated-directory.
Not sure if you want to do this but you can transfer your Azure Subscription to your playpen directory. Please see this link for more details if that's what you want to do: https://learn.microsoft.com/en-us/azure/role-based-access-control/transfer-subscription

Related

VS Code does not find my Azure subscription

I have followed the instructions found here https://learn.microsoft.com/en-us/azure/azure-functions/create-first-function-vs-code-python?pivots=python-mode-configuration but after I login VS Code cannot find my subscription. I do have a pay and go subscription active so why does this not work? I need to be able to create a python function in VS Code and need this to work to be able to move ahead....
This is how I get my azure subscription in VS Code.
Firstly, when I opened VS Code, I could not be able to see my subscription.
Then I logged into my Azure Account in Azure Portal Website in my Browser, then I am able to see the Subscription as below in VS Code.
References:
https://learn.microsoft.com/en-us/answers/questions/382060/azure-vs-code-39no-subscriptions-were-found39.html
"No subscription were found" in VS code while sign in using Azure account

Azure Cloud service deploy under not owner

My customer added my microsoft profile to his subscription as owner.
I logged to Visual Studio with this profile and try to publish cloud service. But I get an error:
why so and how to fix it?
Cloud services are not available in this subscription.
This error is caused because for Azure Service Management (ASM) resources you should be co-admin in order to deploy services.
If you look on the new portal, you can see that you have permission for publishing on this subscription but one thing to keep in mind is that this “Owner” role is only valid for Azure Resource Manager resources. Even though you can manage Cloud Services on the new portal, it is an ASM resource and that’s why this role is not applicable for it. Roles configured on the new portal are RBAC and they are only valid for ARM resources.
So, you should ask for the subscription an Admin to add your user as co-admin on the old portal.
More information about co-admin and owner, please refer to this blog.
Update:
Sorry for my mistake.
For now, we should use new portal to add co-administrator, like this:
More information about add Co-administrator via new portal, please refer to this link.
User should be added as co-administrator, not only as owner. More information about it here:
https://azure.microsoft.com/en-us/documentation/articles/resource-manager-deployment-model/
Ability to add user as co-administrator is already added to new portal (and deprecated on old portal):

MS Azure and publish from VS without subscription credentials?

In our organization, we have an Enterprise Azure Subscription and a few members of our team can use it with their own AD credentials.
For instance, I have the 'owner' role for my account, but don't have the login/pwd of the subscription.
However, in Visual Studio 2015, for a Azure Service, publish Azure application, I need to specify a account an choose the subscription.
And there is no subscription listed for my account.
So what should I do to be able to publish from Visual Studio?
Or what further rights should I ask aside my 'owner' role in Azure?
EDIT: I opened the same topic on MSDN (https://social.msdn.microsoft.com/Forums/en-US/e242ae0a-8da3-49fd-9fff-0460c4e294b8/how-to-use-azure-publish-from-visual-studio-with-entreprise-team-subscription?forum=azureapimgmt)
EDIT: this topic has some interessting info but not directly related since I do NOT have the subscription myself:
Visual Studio not finding my Azure subscriptions
I'm guessing you're working with multiple accounts...
You may not be signed into visual studio with the correct account. The account name dropdown in the upper right hand corner of visual studio and select Account Settings. From here ensure the account associated with your Azure resources is present under All Accounts. MS has some more guidance here:
https://msdn.microsoft.com/en-us/library/dn872465.aspx

What is the relationship between Azure and Visual Studio Team Services

We have a Visual Studio Team Services instance that is used by the company I work for.
The company has an Azure instance. As far as I am aware there is no connection to VSTS.
When I was added to VSTS as a Visual Studio Pro level user some months ago we had to use my Microsoft Account as we couldn't use my work identity because my MSDN subscription is linked to my Microsoft Account as we could not link it to my work identity; apparently this was because we use Office365 in the office.
We now have problems adding Basic Users to VSTS. I enter the users Microsoft Account identity and I am told "No Identities Found".
I looked at VSTS Settings where I can see "This account is backed by the Default Directory Azure Active Directory."
I can also see an "Azure Subscription ID". When I follow the Subscription ID link I end up at my Microsoft Account Azure instance.
I had other users log in to VSTS and they too are seeing my Azure Subscription ID in VSTS Settings.
Why is this happening?
How do Azure instances/accounts relate to VSTS instances/accounts
Can I break the link between Azure and VSTS
You can link your VSTS account to the azure from your azure portal:
Azure - VSTS service
Then, what we do is to add the users to the Azure active directories. As far as I know, these users must be registered in Microsoft.
Once it's done, you can add the users to the VSTS.
Hope it helps you.
The Team Services uses an Azure subscription to bill purchases and can control access with Azure AD.
You can unlink your VSTS account from Azure portal. More information, you can refer to this article: Delete or recover Visual Studio Team Services account
I am an idiot.
Turns out the company VSTS was linking to the company Azure.
I became confused when clicking the Manage button in VSTS | Azure Subscription ID.
That took me to the Sign in to Azure page and displayed my login, which takes me my Azure.
It was only when we checked the Azure Subscription ID in VSTS against my Azure Subscription ID that it became apparent I was following a red herring. The ID matched the companies Azure ID. So I can use that to add users and subsequently add them to VSTS.

Unable to view any tabs in Azure portal

I am unable to view any services in my azure portal. A couple of days back everything was visible.
I think there's some permissions issue. I am logging as Global Admin on the portal.
[UPDATE]: I was trying to publish a web application from visual studio to my azure account and when I select my account, it says "There are no Azure subscriptions associated with this account". Is it that my account is suspended or deactivated or so?
You are signed in to the classic portal with an AAD subscription. These subscriptions don't support using other services. You might be signed in to the wrong directory. Use the "Subscriptions" menu at the top to switch. If you don't have that, you could also be signed in to the wrong account. Some people have used "work/school" (AAD) email addresses to sign up for a "personal" (Microsoft Account) account. If that happens, you'll see a prompt to pick one of the two when you sign in. If you don't see your subscription, it may be assigned to the personal/MSA account. You can grant access to the other one to avoid this.

Resources