Feb 02 2023
09:52 AM
- last edited on
Mar 05 2024
02:22 PM
by
TechCommunityAP
Feb 02 2023
09:52 AM
- last edited on
Mar 05 2024
02:22 PM
by
TechCommunityAP
While trying to add a linux VM resource to an Azure Devops pipeline environment, we receive this error.
[2023-02-01 23:02:42Z ERR Terminal] Microsoft.VisualStudio.Services.WebApi.VssServiceResponseException: Invalid Virtual Machine resource name 'example.az.example.com'. A valid name
is less than 128 characters in length and does not contain the following characters: ',', '"', '/', '\', '[', ']', ':', '|', '<', '>', '+', '=', ';', '?', '*', '.'.
---> System.ArgumentException: Invalid Virtual Machine resource name 'example.az.example.com'. A valid name is less than 128 characters in length and does not contain the following
characters: ',', '"', '/', '\', '[', ']', ':', '|', '<', '>', '+', '=', ';', '?', '*', '.'.
--- End of inner exception stack trace --
at Microsoft.VisualStudio.Services.WebApi.VssHttpClientBase.HandleResponseAsync(HttpResponseMessage response, CancellationToken cancellationToken)
at Microsoft.VisualStudio.Services.WebApi.VssHttpClientBase.SendAsync(HttpRequestMessage message, HttpCompletionOption completionOption, Object userState, CancellationToken cancellationTo
ken)
at Microsoft.VisualStudio.Services.WebApi.VssHttpClientBase.SendAsync[T](HttpRequestMessage message, Object userState, CancellationToken cancellationToken)
at Microsoft.VisualStudio.Services.WebApi.VssHttpClientBase.SendAsync[T](HttpMethod method, IEnumerable`1 additionalHeaders, Guid locationId, Object routeValues, ApiResourceVersion versio
n, HttpContent content, IEnumerable`1 queryParameters, Object userState, CancellationToken cancellationToken)
at Microsoft.VisualStudio.Services.Agent.Listener.Configuration.EnvironmentVMResourceConfigProvider.AddAgentAsync(AgentSettings agentSettings, TaskAgent agent, CommandSettings command) in
/home/vsts/work/1/s/src/Agent.Listener/Configuration/ConfigurationProvider.cs:line 482
at Microsoft.VisualStudio.Services.Agent.Listener.Configuration.ConfigurationManager.ConfigureAsync(CommandSettings command) in /home/vsts/work/1/s/src/Agent.Listener/Configuration/Config
urationManager.cs:line 250
Feb 02 2023 10:18 AM
Feb 02 2023 11:38 AM - edited Feb 02 2023 11:55 AM
@rasad4468 Is it possible to circumvent changing the VM name? Our VM name is valid, as our VM is pre-existing. Our hostname is invalid.
Feb 02 2023 12:46 PM