Add-AzureRmEnvironment
Adds endpoints and metadata for an instance of Azure Resource Manager.
Warning
The AzureRM PowerShell module has been officially deprecated as of February 29, 2024. Users are advised to migrate from AzureRM to the Az PowerShell module to ensure continued support and updates.
Although the AzureRM module may still function, it's no longer maintained or supported, placing any continued use at the user's discretion and risk. Please refer to our migration resources for guidance on transitioning to the Az module.
Syntax
Add-AzureRmEnvironment
[-Name] <String>
[[-PublishSettingsFileUrl] <String>]
[[-ServiceEndpoint] <String>]
[[-ManagementPortalUrl] <String>]
[[-StorageEndpoint] <String>]
[[-ActiveDirectoryEndpoint] <String>]
[[-ResourceManagerEndpoint] <String>]
[[-GalleryEndpoint] <String>]
[[-ActiveDirectoryServiceEndpointResourceId] <String>]
[[-GraphEndpoint] <String>]
[[-AzureKeyVaultDnsSuffix] <String>]
[[-AzureKeyVaultServiceEndpointResourceId] <String>]
[[-TrafficManagerDnsSuffix] <String>]
[[-SqlDatabaseDnsSuffix] <String>]
[[-AzureDataLakeStoreFileSystemEndpointSuffix] <String>]
[[-AzureDataLakeAnalyticsCatalogAndJobEndpointSuffix] <String>]
[-EnableAdfsAuthentication]
[[-AdTenant] <String>]
[[-GraphAudience] <String>]
[[-DataLakeAudience] <String>]
[[-BatchEndpointResourceId] <String>]
[[-AzureOperationalInsightsEndpointResourceId] <String>]
[[-AzureOperationalInsightsEndpoint] <String>]
[-AzureAnalysisServicesEndpointSuffix <String>]
[-Scope <ContextModificationScope>]
[-DefaultProfile <IAzureContextContainer>]
[-WhatIf]
[-Confirm]
[<CommonParameters>]
Add-AzureRmEnvironment
[-Name] <String>
[[-StorageEndpoint] <String>]
[-ARMEndpoint] <String>
[[-AzureKeyVaultDnsSuffix] <String>]
[[-AzureKeyVaultServiceEndpointResourceId] <String>]
[[-DataLakeAudience] <String>]
[[-BatchEndpointResourceId] <String>]
[[-AzureOperationalInsightsEndpointResourceId] <String>]
[[-AzureOperationalInsightsEndpoint] <String>]
[-Scope <ContextModificationScope>]
[-DefaultProfile <IAzureContextContainer>]
[-WhatIf]
[-Confirm]
[<CommonParameters>]
Description
The Add-AzureRmEnvironment cmdlet adds endpoints and metadata to enable Azure Resource Manager cmdlets to connect with a new instance of Azure Resource Manager. The built-in environments AzureCloud and AzureChinaCloud target existing public instances of Azure Resource Manager.
Examples
Example 1: Creating and modifying a new environment
PS C:\> Add-AzureRmEnvironment -Name TestEnvironment `
-ActiveDirectoryEndpoint TestADEndpoint `
-ActiveDirectoryServiceEndpointResourceId TestADApplicationId `
-ResourceManagerEndpoint TestRMEndpoint `
-GalleryEndpoint TestGalleryEndpoint `
-GraphEndpoint TestGraphEndpoint
Name Resource Manager Url ActiveDirectory Authority
---- -------------------- -------------------------
TestEnvironment TestRMEndpoint TestADEndpoint/
PS C:\> Set-AzureRmEnvironment -Name TestEnvironment `
-ActiveDirectoryEndpoint NewTestADEndpoint `
-GraphEndpoint NewTestGraphEndpoint | Format-List
Name : TestEnvironment
EnableAdfsAuthentication : False
OnPremise : False
ActiveDirectoryServiceEndpointResourceId : TestADApplicationId
AdTenant :
GalleryUrl : TestGalleryEndpoint
ManagementPortalUrl :
ServiceManagementUrl :
PublishSettingsFileUrl :
ResourceManagerUrl : TestRMEndpoint
SqlDatabaseDnsSuffix :
StorageEndpointSuffix :
ActiveDirectoryAuthority : NewTestADEndpoint
GraphUrl : NewTestGraphEndpoint
GraphEndpointResourceId :
TrafficManagerDnsSuffix :
AzureKeyVaultDnsSuffix :
DataLakeEndpointResourceId :
AzureDataLakeStoreFileSystemEndpointSuffix :
AzureDataLakeAnalyticsCatalogAndJobEndpointSuffix :
AzureKeyVaultServiceEndpointResourceId :
AzureOperationalInsightsEndpointResourceId :
AzureOperationalInsightsEndpoint :
AzureAnalysisServicesEndpointSuffix :
VersionProfiles : {}
ExtendedProperties : {}
BatchEndpointResourceId :
In this example we are creating a new Azure environment with sample endpoints using Add-AzureRmEnvironment, and then we are changing the value of the ActiveDirectoryEndpoint and GraphEndpoint attributes of the created environment using the cmdlet Set-AzureRmEnvironment.
Parameters
-ActiveDirectoryEndpoint
Specifies the base authority for Microsoft Entra authentication.
Type: | String |
Aliases: | AdEndpointUrl, ActiveDirectory, ActiveDirectoryAuthority |
Position: | 5 |
Default value: | None |
Required: | False |
Accept pipeline input: | True |
Accept wildcard characters: | False |
-ActiveDirectoryServiceEndpointResourceId
Specifies the audience for tokens that authenticate requests to Azure Resource Manager or Service Management (RDFE) endpoints.
Type: | String |
Position: | 8 |
Default value: | None |
Required: | False |
Accept pipeline input: | True |
Accept wildcard characters: | False |
-AdTenant
Specifies the default Active Directory tenant.
Type: | String |
Position: | 17 |
Default value: | None |
Required: | False |
Accept pipeline input: | True |
Accept wildcard characters: | False |
-ARMEndpoint
The Azure Resource Manager endpoint
Type: | String |
Aliases: | ArmUrl |
Position: | 1 |
Default value: | None |
Required: | True |
Accept pipeline input: | True |
Accept wildcard characters: | False |
-AzureAnalysisServicesEndpointSuffix
Dns Suffix of Azure Analysis Services service endpoints
Type: | String |
Position: | 15 |
Default value: | None |
Required: | False |
Accept pipeline input: | True |
Accept wildcard characters: | False |
-AzureDataLakeAnalyticsCatalogAndJobEndpointSuffix
Dns Suffix of Azure Data Lake Analytics job and catalog services
Type: | String |
Position: | 15 |
Default value: | None |
Required: | False |
Accept pipeline input: | True |
Accept wildcard characters: | False |
-AzureDataLakeStoreFileSystemEndpointSuffix
Dns Suffix of Azure Data Lake Store FileSystem. Example: azuredatalake.net
Type: | String |
Position: | 14 |
Default value: | None |
Required: | False |
Accept pipeline input: | True |
Accept wildcard characters: | False |
-AzureKeyVaultDnsSuffix
Specifies the domain name suffix for Key Vault services.
Type: | String |
Position: | 10 |
Default value: | None |
Required: | False |
Accept pipeline input: | True |
Accept wildcard characters: | False |
-AzureKeyVaultServiceEndpointResourceId
Specifies the audience for access tokens that authorize requests for Key Vault services.
Type: | String |
Position: | 11 |
Default value: | None |
Required: | False |
Accept pipeline input: | True |
Accept wildcard characters: | False |
-AzureOperationalInsightsEndpoint
Specifies the endpoint for the Operational Insights query access.
Type: | String |
Position: | 22 |
Default value: | None |
Required: | False |
Accept pipeline input: | True |
Accept wildcard characters: | False |
-AzureOperationalInsightsEndpointResourceId
Specifies the audience for access tokens that authorize requests for Operational Insights services.
Type: | String |
Position: | 21 |
Default value: | None |
Required: | False |
Accept pipeline input: | True |
Accept wildcard characters: | False |
-BatchEndpointResourceId
The resource identifier of the Azure Batch service that is the recipient of the requested token
Type: | String |
Aliases: | BatchResourceId, BatchAudience |
Position: | 20 |
Default value: | None |
Required: | False |
Accept pipeline input: | True |
Accept wildcard characters: | False |
-Confirm
Prompts you for confirmation before running the cmdlet.
Type: | SwitchParameter |
Aliases: | cf |
Position: | Named |
Default value: | False |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-DataLakeAudience
The audience for tokens authenticating with the AD Data Lake services Endpoint.
Type: | String |
Aliases: | DataLakeEndpointResourceId, DataLakeResourceId |
Position: | 19 |
Default value: | None |
Required: | False |
Accept pipeline input: | True |
Accept wildcard characters: | False |
-DefaultProfile
The credeetnails, tenant and subscription used for communication with azure
Type: | IAzureContextContainer |
Aliases: | AzureRmContext, AzureCredential |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-EnableAdfsAuthentication
Indicates that Active Directory Federation Services (ADFS) on-premise authentication is allowed.
Type: | SwitchParameter |
Aliases: | OnPremise |
Position: | 16 |
Default value: | None |
Required: | False |
Accept pipeline input: | True |
Accept wildcard characters: | False |
-GalleryEndpoint
Specifies the endpoint for the Azure Resource Manager gallery of deployment templates.
Type: | String |
Aliases: | Gallery, GalleryUrl |
Position: | 7 |
Default value: | None |
Required: | False |
Accept pipeline input: | True |
Accept wildcard characters: | False |
-GraphAudience
The audience for tokens authenticating with the AD Graph Endpoint.
Type: | String |
Aliases: | GraphEndpointResourceId, GraphResourceId |
Position: | 18 |
Default value: | None |
Required: | False |
Accept pipeline input: | True |
Accept wildcard characters: | False |
-GraphEndpoint
Specifies the URL for Graph (Active Directory metadata) requests.
Type: | String |
Aliases: | Graph, GraphUrl |
Position: | 9 |
Default value: | None |
Required: | False |
Accept pipeline input: | True |
Accept wildcard characters: | False |
-ManagementPortalUrl
Specifies the URL for the Management Portal.
Type: | String |
Position: | 3 |
Default value: | None |
Required: | False |
Accept pipeline input: | True |
Accept wildcard characters: | False |
-Name
Specifies the name of the environment to add.
Type: | String |
Position: | 0 |
Default value: | None |
Required: | True |
Accept pipeline input: | True |
Accept wildcard characters: | False |
-PublishSettingsFileUrl
Specifies the URL from which .publishsettings files can be downloaded.
Type: | String |
Position: | 1 |
Default value: | None |
Required: | False |
Accept pipeline input: | True |
Accept wildcard characters: | False |
-ResourceManagerEndpoint
Specifies the URL for Azure Resource Manager requests.
Type: | String |
Aliases: | ResourceManager, ResourceManagerUrl |
Position: | 6 |
Default value: | None |
Required: | False |
Accept pipeline input: | True |
Accept wildcard characters: | False |
-Scope
Determines the scope of context changes, for example, whether changes apply only to the current process, or to all sessions started by this user.
Type: | ContextModificationScope |
Accepted values: | Process, CurrentUser |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-ServiceEndpoint
Specifies the endpoint for Service Management (RDFE) requests.
Type: | String |
Aliases: | ServiceManagement, ServiceManagementUrl |
Position: | 2 |
Default value: | None |
Required: | False |
Accept pipeline input: | True |
Accept wildcard characters: | False |
-SqlDatabaseDnsSuffix
Specifies the domain-name suffix for Azure SQL Database servers.
Type: | String |
Position: | 13 |
Default value: | None |
Required: | False |
Accept pipeline input: | True |
Accept wildcard characters: | False |
-StorageEndpoint
Specifies the endpoint for storage (blob, table, queue, and file) access.
Type: | String |
Aliases: | StorageEndpointSuffix |
Position: | 4 |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-TrafficManagerDnsSuffix
Specifies the domain-name suffix for Azure Traffic Manager services.
Type: | String |
Position: | 12 |
Default value: | None |
Required: | False |
Accept pipeline input: | True |
Accept wildcard characters: | False |
-WhatIf
Shows what would happen if the cmdlet runs. The cmdlet is not run.
Type: | SwitchParameter |
Aliases: | wi |
Position: | Named |
Default value: | False |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |