Set-AzEnvironment
Sets properties for an Azure environment.
Syntax
Name (Default)
Set-AzEnvironment
[-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>]
[[-AdTenant] <String>]
[[-GraphAudience] <String>]
[[-DataLakeAudience] <String>]
[[-BatchEndpointResourceId] <String>]
[[-AzureOperationalInsightsEndpointResourceId] <String>]
[[-AzureOperationalInsightsEndpoint] <String>]
[-EnableAdfsAuthentication]
[-AzureAnalysisServicesEndpointSuffix <String>]
[-AzureAnalysisServicesEndpointResourceId <String>]
[-AzureAttestationServiceEndpointSuffix <String>]
[-AzureAttestationServiceEndpointResourceId <String>]
[-AzureSynapseAnalyticsEndpointSuffix <String>]
[-ContainerRegistryEndpointSuffix <String>]
[-AzureSynapseAnalyticsEndpointResourceId <String>]
[-MicrosoftGraphEndpointResourceId <String>]
[-MicrosoftGraphUrl <String>]
[-SshAuthScope <String>]
[-Scope <ContextModificationScope>]
[-DefaultProfile <IAzureContextContainer>]
[-WhatIf]
[-Confirm]
[<CommonParameters>]
ARMEndpoint
Set-AzEnvironment
[-Name] <String>
[[-StorageEndpoint] <String>]
[-ARMEndpoint] <String>
[[-AzureKeyVaultDnsSuffix] <String>]
[[-AzureKeyVaultServiceEndpointResourceId] <String>]
[[-DataLakeAudience] <String>]
[[-BatchEndpointResourceId] <String>]
[[-AzureOperationalInsightsEndpointResourceId] <String>]
[[-AzureOperationalInsightsEndpoint] <String>]
[-AzureAnalysisServicesEndpointSuffix <String>]
[-AzureAnalysisServicesEndpointResourceId <String>]
[-AzureAttestationServiceEndpointSuffix <String>]
[-AzureAttestationServiceEndpointResourceId <String>]
[-AzureSynapseAnalyticsEndpointSuffix <String>]
[-ContainerRegistryEndpointSuffix <String>]
[-AzureSynapseAnalyticsEndpointResourceId <String>]
[-Scope <ContextModificationScope>]
[-DefaultProfile <IAzureContextContainer>]
[-WhatIf]
[-Confirm]
[<CommonParameters>]
Description
The Set-AzEnvironment cmdlet sets endpoints and metadata for connecting to an instance of Azure.
Examples
Example 1: Creating and modifying a new environment
Add-AzEnvironment -Name TestEnvironment `
-ActiveDirectoryEndpoint TestADEndpoint `
-ActiveDirectoryServiceEndpointResourceId TestADApplicationId `
-ResourceManagerEndpoint TestRMEndpoint `
-GalleryEndpoint TestGalleryEndpoint `
-GraphEndpoint TestGraphEndpoint
Name Resource Manager Url ActiveDirectory Authority
---- -------------------- -------------------------
TestEnvironment TestRMEndpoint TestADEndpoint/
Set-AzEnvironment -Name TestEnvironment `
-ActiveDirectoryEndpoint NewTestADEndpoint `
-GraphEndpoint NewTestGraphEndpoint | Format-List
Name : TestEnvironment
EnableAdfsAuthentication : False
ActiveDirectoryServiceEndpointResourceId : TestADApplicationId
AdTenant :
GalleryUrl : TestGalleryEndpoint
ManagementPortalUrl :
ServiceManagementUrl :
PublishSettingsFileUrl :
ResourceManagerUrl : TestRMEndpoint
SqlDatabaseDnsSuffix :
StorageEndpointSuffix :
ActiveDirectoryAuthority : NewTestADEndpoint
GraphUrl : NewTestGraphEndpoint
GraphEndpointResourceId :
TrafficManagerDnsSuffix :
AzureKeyVaultDnsSuffix :
AzureDataLakeStoreFileSystemEndpointSuffix :
AzureDataLakeAnalyticsCatalogAndJobEndpointSuffix :
AzureKeyVaultServiceEndpointResourceId :
BatchEndpointResourceId :
AzureOperationalInsightsEndpoint :
AzureOperationalInsightsEndpointResourceId :
AzureAttestationServiceEndpointSuffix :
AzureAttestationServiceEndpointResourceId :
AzureSynapseAnalyticsEndpointSuffix :
AzureSynapseAnalyticsEndpointResourceId :
In this example we are creating a new Azure environment with sample endpoints using Add-AzEnvironment, and then we are changing the value of the ActiveDirectoryEndpoint and GraphEndpoint attributes of the created environment using the cmdlet Set-AzEnvironment.
Parameters
-ActiveDirectoryEndpoint
Specifies the base authority for Azure Active Directory authentication.
Parameter properties
Type: String
Default value: None
Supports wildcards: False
DontShow: False
Aliases: AdEndpointUrl, ActiveDirectory, ActiveDirectoryAuthority
Parameter sets
Name
Position: 5
Mandatory: False
Value from pipeline: False
Value from pipeline by property name: True
Value from remaining arguments: False
-ActiveDirectoryServiceEndpointResourceId
Specifies the audience for tokens that authenticate requests to Azure Resource Manager or Service Management (RDFE) endpoints.
Parameter properties
Type: String
Default value: None
Supports wildcards: False
DontShow: False
Parameter sets
Name
Position: 8
Mandatory: False
Value from pipeline: False
Value from pipeline by property name: True
Value from remaining arguments: False
-AdTenant
Specifies the default Active Directory tenant.
Parameter properties
Type: String
Default value: None
Supports wildcards: False
DontShow: False
Parameter sets
Name
Position: 17
Mandatory: False
Value from pipeline: False
Value from pipeline by property name: True
Value from remaining arguments: False
-ARMEndpoint
The Azure Resource Manager endpoint.
Parameter properties
Type: String
Default value: None
Supports wildcards: False
DontShow: False
Aliases: ArmUrl
Parameter sets
ARMEndpoint
Position: 1
Mandatory: True
Value from pipeline: False
Value from pipeline by property name: True
Value from remaining arguments: False
-AzureAnalysisServicesEndpointResourceId
The resource identifier of the Azure Analysis Services resource.
Parameter properties
Type: String
Default value: None
Supports wildcards: False
DontShow: False
Parameter sets
(All)
Position: Named
Mandatory: False
Value from pipeline: False
Value from pipeline by property name: False
Value from remaining arguments: False
-AzureAnalysisServicesEndpointSuffix
The endpoint to use when communicating with the Azure Log Analytics API.
Parameter properties
Type: String
Default value: None
Supports wildcards: False
DontShow: False
Parameter sets
(All)
Position: Named
Mandatory: False
Value from pipeline: False
Value from pipeline by property name: False
Value from remaining arguments: False
-AzureAttestationServiceEndpointResourceId
The The resource identifier of the Azure Attestation service that is the recipient of the requested token.
Parameter properties
Type: String
Default value: None
Supports wildcards: False
DontShow: False
Parameter sets
(All)
Position: Named
Mandatory: False
Value from pipeline: False
Value from pipeline by property name: True
Value from remaining arguments: False
-AzureAttestationServiceEndpointSuffix
Dns suffix of Azure Attestation service.
Parameter properties
Type: String
Default value: None
Supports wildcards: False
DontShow: False
Parameter sets
(All)
Position: Named
Mandatory: False
Value from pipeline: False
Value from pipeline by property name: True
Value from remaining arguments: False
-AzureDataLakeAnalyticsCatalogAndJobEndpointSuffix
Dns Suffix of Azure Data Lake Analytics job and catalog services
Parameter properties
Type: String
Default value: None
Supports wildcards: False
DontShow: False
Parameter sets
Name
Position: 15
Mandatory: False
Value from pipeline: False
Value from pipeline by property name: True
Value from remaining arguments: False
-AzureDataLakeStoreFileSystemEndpointSuffix
Dns Suffix of Azure Data Lake Store FileSystem. Example: azuredatalake.net
Parameter properties
Type: String
Default value: None
Supports wildcards: False
DontShow: False
Parameter sets
Name
Position: 14
Mandatory: False
Value from pipeline: False
Value from pipeline by property name: True
Value from remaining arguments: False
-AzureKeyVaultDnsSuffix
Dns suffix of Azure Key Vault service. Example is vault-int.azure-int.net
Parameter properties
Type: String
Default value: None
Supports wildcards: False
DontShow: False
Parameter sets
(All)
Position: 10
Mandatory: False
Value from pipeline: False
Value from pipeline by property name: True
Value from remaining arguments: False
-AzureKeyVaultServiceEndpointResourceId
Resource identifier of Azure Key Vault data service that is the recipient of the requested token.
Parameter properties
Type: String
Default value: None
Supports wildcards: False
DontShow: False
Parameter sets
(All)
Position: 11
Mandatory: False
Value from pipeline: False
Value from pipeline by property name: True
Value from remaining arguments: False
-AzureOperationalInsightsEndpoint
The endpoint to use when communicating with the Azure Log Analytics API.
Parameter properties
Type: String
Default value: None
Supports wildcards: False
DontShow: False
Parameter sets
(All)
Position: 22
Mandatory: False
Value from pipeline: False
Value from pipeline by property name: True
Value from remaining arguments: False
-AzureOperationalInsightsEndpointResourceId
The audience for tokens authenticating with the Azure Log Analytics API.
Parameter properties
Type: String
Default value: None
Supports wildcards: False
DontShow: False
Parameter sets
(All)
Position: 21
Mandatory: False
Value from pipeline: False
Value from pipeline by property name: True
Value from remaining arguments: False
-AzureSynapseAnalyticsEndpointResourceId
The The resource identifier of the Azure Synapse Analytics that is the recipient of the requested token.
Parameter properties
Type: String
Default value: None
Supports wildcards: False
DontShow: False
Parameter sets
(All)
Position: Named
Mandatory: False
Value from pipeline: False
Value from pipeline by property name: True
Value from remaining arguments: False
-AzureSynapseAnalyticsEndpointSuffix
Dns suffix of Azure Synapse Analytics.
Parameter properties
Type: String
Default value: None
Supports wildcards: False
DontShow: False
Parameter sets
(All)
Position: Named
Mandatory: False
Value from pipeline: False
Value from pipeline by property name: True
Value from remaining arguments: False
-BatchEndpointResourceId
The resource identifier of the Azure Batch service that is the recipient of the requested token
Parameter properties
Type: String
Default value: None
Supports wildcards: False
DontShow: False
Aliases: BatchResourceId, BatchAudience
Parameter sets
(All)
Position: 20
Mandatory: False
Value from pipeline: False
Value from pipeline by property name: True
Value from remaining arguments: False
-Confirm
Prompts you for confirmation before running the cmdlet.
Parameter properties
Type: SwitchParameter
Default value: False
Supports wildcards: False
DontShow: False
Aliases: cf
Parameter sets
(All)
Position: Named
Mandatory: False
Value from pipeline: False
Value from pipeline by property name: False
Value from remaining arguments: False
-ContainerRegistryEndpointSuffix
Suffix of Azure Container Registry.
Parameter properties
Type: String
Default value: None
Supports wildcards: False
DontShow: False
Parameter sets
(All)
Position: Named
Mandatory: False
Value from pipeline: False
Value from pipeline by property name: True
Value from remaining arguments: False
-DataLakeAudience
The audience for tokens authenticating with the AD Data Lake services Endpoint.
Parameter properties
Type: String
Default value: None
Supports wildcards: False
DontShow: False
Aliases: DataLakeEndpointResourceId, DataLakeResourceId
Parameter sets
(All)
Position: 19
Mandatory: False
Value from pipeline: False
Value from pipeline by property name: True
Value from remaining arguments: False
-DefaultProfile
The credentials, account, tenant and subscription used for communication with azure.
Parameter properties
Type: IAzureContextContainer
Default value: None
Supports wildcards: False
DontShow: False
Aliases: AzContext, AzureRmContext, AzureCredential
Parameter sets
(All)
Position: Named
Mandatory: False
Value from pipeline: False
Value from pipeline by property name: False
Value from remaining arguments: False
-EnableAdfsAuthentication
Indicates that Active Directory Federation Services (ADFS) on-premise authentication is allowed.
Parameter properties
Type: SwitchParameter
Default value: None
Supports wildcards: False
DontShow: False
Aliases: OnPremise
Parameter sets
Name
Position: 16
Mandatory: False
Value from pipeline: False
Value from pipeline by property name: True
Value from remaining arguments: False
-GalleryEndpoint
Specifies the endpoint for the Azure Resource Manager gallery of deployment templates.
The parameter is to set the value to GalleryUrl
of PSAzureEnvironment
. As GalleryUrl
is removed from ArmMetadata, Azure PowerShell will no longer provide for the value and so it is not recommended to set GalleryEndpoint
anymore.
Parameter properties
Type: String
Default value: None
Supports wildcards: False
DontShow: False
Aliases: Gallery, GalleryUrl
Parameter sets
Name
Position: 7
Mandatory: False
Value from pipeline: False
Value from pipeline by property name: True
Value from remaining arguments: False
-GraphAudience
The audience for tokens authenticating with the AD Graph Endpoint.
Parameter properties
Type: String
Default value: None
Supports wildcards: False
DontShow: False
Aliases: GraphEndpointResourceId, GraphResourceId
Parameter sets
Name
Position: 18
Mandatory: False
Value from pipeline: False
Value from pipeline by property name: True
Value from remaining arguments: False
-GraphEndpoint
Specifies the URL for Graph (Active Directory metadata) requests.
Parameter properties
Type: String
Default value: None
Supports wildcards: False
DontShow: False
Aliases: Graph, GraphUrl
Parameter sets
Name
Position: 9
Mandatory: False
Value from pipeline: False
Value from pipeline by property name: True
Value from remaining arguments: False
-ManagementPortalUrl
Specifies the URL for the Management Portal.
Parameter properties
Type: String
Default value: None
Supports wildcards: False
DontShow: False
Parameter sets
Name
Position: 3
Mandatory: False
Value from pipeline: False
Value from pipeline by property name: True
Value from remaining arguments: False
-MicrosoftGraphEndpointResourceId
The resource identifier of Microsoft Graph
Parameter properties
Type: String
Default value: None
Supports wildcards: False
DontShow: False
Parameter sets
Name
Position: Named
Mandatory: False
Value from pipeline: False
Value from pipeline by property name: True
Value from remaining arguments: False
-MicrosoftGraphUrl
Microsoft Graph Url
Parameter properties
Type: String
Default value: None
Supports wildcards: False
DontShow: False
Parameter sets
Name
Position: Named
Mandatory: False
Value from pipeline: False
Value from pipeline by property name: True
Value from remaining arguments: False
-Name
Specifies the name of the environment to modify.
Parameter properties
Type: String
Default value: None
Supports wildcards: False
DontShow: False
Parameter sets
(All)
Position: 0
Mandatory: True
Value from pipeline: False
Value from pipeline by property name: True
Value from remaining arguments: False
-PublishSettingsFileUrl
Specifies the URL from which .publishsettings files can be downloaded.
Parameter properties
Type: String
Default value: None
Supports wildcards: False
DontShow: False
Parameter sets
Name
Position: 1
Mandatory: False
Value from pipeline: False
Value from pipeline by property name: True
Value from remaining arguments: False
-ResourceManagerEndpoint
Specifies the URL for Azure Resource Manager requests.
Parameter properties
Type: String
Default value: None
Supports wildcards: False
DontShow: False
Aliases: ResourceManager, ResourceManagerUrl
Parameter sets
Name
Position: 6
Mandatory: False
Value from pipeline: False
Value from pipeline by property name: True
Value from remaining arguments: 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.
Parameter properties
Type: ContextModificationScope
Default value: None
Accepted values: Process, CurrentUser
Supports wildcards: False
DontShow: False
Parameter sets
(All)
Position: Named
Mandatory: False
Value from pipeline: False
Value from pipeline by property name: False
Value from remaining arguments: False
-ServiceEndpoint
Specifies the endpoint for Service Management (RDFE) requests.
Parameter properties
Type: String
Default value: None
Supports wildcards: False
DontShow: False
Aliases: ServiceManagement, ServiceManagementUrl
Parameter sets
Name
Position: 2
Mandatory: False
Value from pipeline: False
Value from pipeline by property name: True
Value from remaining arguments: False
-SqlDatabaseDnsSuffix
Specifies the domain-name suffix for Azure SQL Database servers.
Parameter properties
Type: String
Default value: None
Supports wildcards: False
DontShow: False
Parameter sets
Name
Position: 13
Mandatory: False
Value from pipeline: False
Value from pipeline by property name: True
Value from remaining arguments: False
-SshAuthScope
The scope for authentication when SSH to an Azure VM.
Parameter properties
Type: String
Default value: None
Supports wildcards: False
DontShow: False
Parameter sets
Name
Position: Named
Mandatory: False
Value from pipeline: False
Value from pipeline by property name: True
Value from remaining arguments: False
-StorageEndpoint
Specifies the endpoint for storage (blob, table, queue, and file) access.
Parameter properties
Type: String
Default value: None
Supports wildcards: False
DontShow: False
Aliases: StorageEndpointSuffix
Parameter sets
(All)
Position: 4
Mandatory: False
Value from pipeline: False
Value from pipeline by property name: False
Value from remaining arguments: False
-TrafficManagerDnsSuffix
Specifies the domain-name suffix for Azure Traffic Manager services.
Parameter properties
Type: String
Default value: None
Supports wildcards: False
DontShow: False
Parameter sets
Name
Position: 12
Mandatory: False
Value from pipeline: False
Value from pipeline by property name: True
Value from remaining arguments: False
-WhatIf
Shows what would happen if the cmdlet runs. The cmdlet is not run.
Parameter properties
Type: SwitchParameter
Default value: False
Supports wildcards: False
DontShow: False
Aliases: wi
Parameter sets
(All)
Position: Named
Mandatory: False
Value from pipeline: False
Value from pipeline by property name: False
Value from remaining arguments: False
CommonParameters
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable,
-InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable,
-ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see
about_CommonParameters .
Outputs