You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: 1-WebApp-OIDC/1-2-AnyOrg/README.md
+2Lines changed: 2 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -191,6 +191,8 @@ cd "1-WebApp-OIDC\1-2-AnyOrg"
191
191
192
192
2. Open your web browser and make a request to the app. Accept the IIS Express SSL certificate if needed. The app immediately attempts to authenticate you via the Microsoft identity platform endpoint. Sign in with your personal account or with work or school account.
193
193
194
+
> A recording of a Microsoft Identity Platform developer session that covered this topic of developing a multi-tenant app with Azure Active Directory is available at [Develop multi-tenant applications with Microsoft identity platform](https://www.youtube.com/watch?v=B416AxHoMJ4).
Copy file name to clipboardExpand all lines: 1-WebApp-OIDC/1-3-AnyOrgOrPersonal/README-1-1-to-1-3.md
+2Lines changed: 2 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -39,5 +39,7 @@ In the **appsettings.json** file, replace the `TenantId` value with `"common"`
39
39
40
40
## Next steps
41
41
42
+
- A recording of a Microsoft Identity Platform developer session that covered this topic of developing a multi-tenant app with Azure Active Directory is available at [Develop multi-tenant applications with Microsoft identity platform](https://www.youtube.com/watch?v=B416AxHoMJ4).
43
+
42
44
- Learn how to enable users from [National clouds](../1-4-Sovereign) to sign-in to your application
43
45
- Learn how to enable your [Web App to call a Web API on behalf of the signed-in user](../../2-WebApp-graph-user)
Copy file name to clipboardExpand all lines: 2-WebApp-graph-user/2-3-Multi-Tenant/README-National-Cloud.md
+2Lines changed: 2 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -44,6 +44,8 @@ In addition to the public cloud, Azure Active Directory is deployed in th
44
44
- Microsoft Cloud Germany
45
45
- Azure and Office 365 operated by 21Vianet in China
46
46
47
+
> A recording of a Microsoft Identity Platform developer session that covered this topic of developing a multi-tenant app with Azure Active Directory is available at [Develop multi-tenant applications with Microsoft identity platform](https://www.youtube.com/watch?v=B416AxHoMJ4).
48
+
47
49
### Overview
48
50
49
51
When it comes to developing apps, developers can choose to configure their app to be either single-tenant or multi-tenant during app registration in the [Azure portal](https://portal.azure.com).
Copy file name to clipboardExpand all lines: 2-WebApp-graph-user/2-3-Multi-Tenant/README.md
+2Lines changed: 2 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -37,6 +37,8 @@ When it comes to developing apps, developers can choose to configure their app t
37
37
38
38
For more information about apps and tenancy, see [Tenancy in Azure Active Directory](https://docs.microsoft.com/azure/active-directory/develop/single-and-multi-tenant-apps)
39
39
40
+
> A recording of a Microsoft Identity Platform developer session that covered this topic of developing a multi-tenant app with Azure Active Directory is available at [Develop multi-tenant applications with Microsoft identity platform](https://www.youtube.com/watch?v=B416AxHoMJ4).
41
+
40
42

Copy file name to clipboardExpand all lines: 5-WebApp-AuthZ/5-2-Groups/AppCreationScripts/AppCreationScripts.md
+22-3Lines changed: 22 additions & 3 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -11,7 +11,7 @@
11
11
```
12
12
1. Run the script to create your Azure AD application and configure the code of the sample application accordingly. (Other ways of running the scripts are described below)
13
13
```PowerShell
14
-
cd .\AppCreationScripts\
14
+
cd .\AppCreationScripts\
15
15
.\Configure.ps1
16
16
```
17
17
1. Open the Visual Studio solution and click start
@@ -27,6 +27,7 @@ The following paragraphs:
27
27
-[Passing credentials](#option-2-non-interactive) to create the app in your home tenant
28
28
-[Interactively in a specific tenant](#option-3-interactive-but-create-apps-in-a-specified-tenant)
29
29
-[Passing credentials in a specific tenant](#option-4-non-interactive-and-create-apps-in-a-specified-tenant)
30
+
-[Passing environment name, for Sovereign clouds](#running-the-script-on-azure-sovereign-clouds)
30
31
31
32
## Goal of the scripts
32
33
@@ -50,7 +51,7 @@ These scripts are:
50
51
51
52
The `Configure.ps1` will stop if it tries to create an Azure AD application which already exists in the tenant. For this, if you are using the script to try/test the sample, or in DevOps scenarios, you might want to run `Cleanup.ps1` just before `Configure.ps1`. This is what is shown in the steps below.
52
53
53
-
## How to use the app creation scripts?
54
+
## How to use the app creation scripts?
54
55
55
56
### Pre-requisites
56
57
@@ -108,7 +109,7 @@ Note that the script will choose the tenant in which to create the applications,
108
109
109
110
#### Option 2 (non-interactive)
110
111
111
-
When you know the indentity and credentials of the user in the name of whom you want to create the applications, you can use the non-interactive approach. It's more adapted to DevOps. Here is an example of script you'd want to run in a PowerShell Window
112
+
When you know the identity and credentials of the user in the name of whom you want to create the applications, you can use the non-interactive approach. It's more adapted to DevOps. Here is an example of script you'd want to run in a PowerShell Window
All the four options listed above, can be used on any Azure Sovereign clouds. By default, the script targets `AzureCloud`, but it can be changed using the parameter `-AzureEnvironmentName`.
Copy file name to clipboardExpand all lines: 5-WebApp-AuthZ/5-2-Groups/AppCreationScripts/Cleanup.ps1
+18-8Lines changed: 18 additions & 8 deletions
Original file line number
Diff line number
Diff line change
@@ -2,9 +2,14 @@
2
2
param(
3
3
[PSCredential] $Credential,
4
4
[Parameter(Mandatory=$False,HelpMessage='Tenant ID (This is a GUID which represents the "Directory ID" of the AzureAD tenant into which you want to create the apps')]
5
-
[string] $tenantId
5
+
[string] $tenantId,
6
+
[Parameter(Mandatory=$False,HelpMessage='Azure environment to use while running the script (it defaults to AzureCloud)')]
7
+
[string] $azureEnvironmentName
6
8
)
7
9
10
+
#Requires -ModulesAzureAD
11
+
12
+
8
13
if ($null-eq (Get-Module-ListAvailable -Name "AzureAD")) {
Copy file name to clipboardExpand all lines: 5-WebApp-AuthZ/5-2-Groups/AppCreationScripts/Configure.ps1
+17-6Lines changed: 17 additions & 6 deletions
Original file line number
Diff line number
Diff line change
@@ -2,9 +2,13 @@
2
2
param(
3
3
[PSCredential] $Credential,
4
4
[Parameter(Mandatory=$False,HelpMessage='Tenant ID (This is a GUID which represents the "Directory ID" of the AzureAD tenant into which you want to create the apps')]
5
-
[string] $tenantId
5
+
[string] $tenantId,
6
+
[Parameter(Mandatory=$False,HelpMessage='Azure environment to use while running the script (it defaults to AzureCloud)')]
7
+
[string] $azureEnvironmentName
6
8
)
7
9
10
+
#Requires -ModulesAzureAD
11
+
8
12
<#
9
13
This script creates the Azure AD applications needed for this sample and updates the configuration files
10
14
for the visual Studio projects from the data in the Azure AD applications.
@@ -147,6 +151,11 @@ Function ConfigureApplications
147
151
so that they are consistent with the Applications parameters
148
152
#>
149
153
$commonendpoint="common"
154
+
155
+
if (!$azureEnvironmentName)
156
+
{
157
+
$azureEnvironmentName="AzureCloud"
158
+
}
150
159
151
160
# $tenantId is the Active Directory Tenant. This is a GUID which represents the "Directory ID" of the AzureAD tenant
152
161
# into which you want to create the apps. Look it up in the Azure portal in the "Properties" of the Azure AD.
@@ -155,17 +164,17 @@ Function ConfigureApplications
155
164
# you'll need to sign-in with creds enabling your to create apps in the tenant)
0 commit comments