Skip to content

Get-AzNetworkServiceTag does not return IP ranges for Azure DevOps MS-Hosted Agents #12312

Open
@theonesuperdave

Description

@theonesuperdave

Description

I'm using Get-AzNetworkServiceTag to get the list of well-known IP ranges for Azure DevOps agents rather than downloading the "weekly file" manually. The module is full of valid content, but is missing the IP addresses coming from Azure DevOps MS-Hosted agents. I have tried several times, but each time the address is not from one retrieved from Get-AzNetworkServiceTag.

IP at the time of this writing

AzDO Agent Public IP Address: 168.61.181.147

Previously observed IP Addresses

23.101.122.52
23.99.201.43
40.77.107.72
23.99.183.158
52.173.141.223

Steps to reproduce

(Get-AzNetworkServiceTag -Location northcentralus).Values).Properties.AddressPrefixes

Environment data

Name                           Value
----                           -----
PSVersion                      5.1.14393.3471
PSEdition                      Desktop
PSCompatibleVersions           {1.0, 2.0, 3.0, 4.0...}
BuildVersion                   10.0.14393.3471
CLRVersion                     4.0.30319.42000
WSManStackVersion              3.0
PSRemotingProtocolVersion      2.3
SerializationVersion           1.1.0.1

Module versions

Script     3.0.0      Az.Network                          {Add-AzApplicationGatewayAuthenticationCertificate, Get-AzApplicationGatewayAuthenticationCertificat...

Debug output

Very Large Data set. No relevant details observed.

DEBUG: AzureQoSEvent: CommandName - Get-AzNetworkServiceTag; IsSuccess - True; Duration - 00:00:03.4133132;
DEBUG: Finish sending metric.
DEBUG: 12:59:14 PM - GetAzureNetworkServiceTagCommand end processing.

Error output

Message        : Unable to load one or more of the requested types. Retrieve the LoaderExceptions property for more information.
StackTrace     :    at System.Reflection.RuntimeModule.GetTypes(RuntimeModule module)
                    at System.Reflection.Assembly.GetTypes()
                    at Microsoft.PowerShell.Commands.AddTypeCommand.LoadAssemblyFromPathOrName(List`1 generatedTypes)
                    at Microsoft.PowerShell.Commands.AddTypeCommand.EndProcessing()
                    at System.Management.Automation.CommandProcessorBase.Complete()
Exception      : System.Reflection.ReflectionTypeLoadException
InvocationInfo : {Add-Type}
Line           :                 Add-Type -Path $_.FullName -ErrorAction Ignore | Out-Null

Position       : At C:\Program Files\WindowsPowerShell\Modules\Az.Accounts\1.8.0\Az.Accounts.psm1:68 char:17
                 + ...                Add-Type -Path $_.FullName -ErrorAction Ignore | Out-N ...
                 +                    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
HistoryId      : 1

Message        : Unable to load one or more of the requested types. Retrieve the LoaderExceptions property for more information.
StackTrace     :    at System.Reflection.RuntimeModule.GetTypes(RuntimeModule module)
                    at System.Reflection.Assembly.GetTypes()
                    at Microsoft.PowerShell.Commands.AddTypeCommand.LoadAssemblyFromPathOrName(List`1 generatedTypes)
                    at Microsoft.PowerShell.Commands.AddTypeCommand.EndProcessing()
                    at System.Management.Automation.CommandProcessorBase.Complete()
Exception      : System.Reflection.ReflectionTypeLoadException
InvocationInfo : {Add-Type}
Line           :                 Add-Type -Path $_.FullName -ErrorAction Ignore | Out-Null

Position       : At C:\Program Files\WindowsPowerShell\Modules\Az.Accounts\1.8.0\Az.Accounts.psm1:68 char:17
                 + ...                Add-Type -Path $_.FullName -ErrorAction Ignore | Out-N ...
                 +                    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
HistoryId      : 1

Message        : Unable to load one or more of the requested types. Retrieve the LoaderExceptions property for more information.
StackTrace     :    at System.Reflection.RuntimeModule.GetTypes(RuntimeModule module)
                    at System.Reflection.Assembly.GetTypes()
                    at Microsoft.PowerShell.Commands.AddTypeCommand.LoadAssemblyFromPathOrName(List`1 generatedTypes)
                    at Microsoft.PowerShell.Commands.AddTypeCommand.EndProcessing()
                    at System.Management.Automation.CommandProcessorBase.Complete()
Exception      : System.Reflection.ReflectionTypeLoadException
InvocationInfo : {Add-Type}
Line           :                 Add-Type -Path $_.FullName -ErrorAction Ignore | Out-Null

Position       : At C:\Program Files\WindowsPowerShell\Modules\Az.Accounts\1.8.0\Az.Accounts.psm1:68 char:17
                 + ...                Add-Type -Path $_.FullName -ErrorAction Ignore | Out-N ...
                 +                    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
HistoryId      : 1


The Azure PowerShell team is listening, please let us know how we are doing: https://aka.ms/azpssurvey?Q_CHL=ERROR.

DEBUG: AzureQoSEvent: CommandName - Resolve-AzError; IsSuccess - True; Duration - 00:00:00.1761527;
DEBUG: Finish sending metric.
DEBUG: 1:01:15 PM - ResolveError end processing.

Metadata

Metadata

Labels

Network - Virtual NetworkService AttentionThis issue is responsible by Azure service team.customer-reportedquestionThe issue doesn't require a change to the product in order to be resolved. Most issues start as that

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions