My build is failing with the error:
getaddrinfo ENOTFOUND login.windows.net login.windows.net:443
The agent is installed and there is a proxy configured for the server.
I can reach the URL login.windows.net from the browsers, and other connections to internet (ie Nuget) are working fine.
Looking the source code, the error is being raised from the file azurerestutility.js when it is trying to send a POST request to get the access token.
httpObj.send('POST', authorityUrl, requestData, requestHeader, (error, response, body) => {
if (error) {
deferred.reject(error);
}
else if (response.statusCode == 200) {
deferred.resolve(JSON.parse(body).access_token);
}
else {
deferred.reject(tl.loc('CouldnotfetchacccesstokenforAzureStatusCode', response.statusCode, response.statusMessage));
}
});
Is there any way to force the usage of proxy in this task? Maybe some argument that I could use to setup the build definition.
Can you please refer to this doc.
Hello Vincent,
I tested this, then I could even see the proxy being set for the agent as
expected:
2019-08-06T18:06:58.3711949Z Current agent version: '2.141.1'
2019-08-06T18:06:58.3712092Z Agent is running behind proxy server: '
http://myproxy:8080'
2019-08-06T18:06:58.3799334Z ##[debug]Primary repository: testproxy.
repository type: Git
2019-08-06T18:06:58.3867604Z Prepare build directory.
Then when it reaches the same part was I mentioned already, I got still the
same error:
[image: image.png]
2019-08-06T18:07:15.1266253Z ##[debug]8919bc50-809a-436e-9ce0-de05e283e38c=
https://management.azure.com/
2019-08-06T18:07:15.1266414Z ##[debug]Requesting for Auth Token:
https://login.windows.net/*/oauth2/token/
2019-08-06T18:07:15.1445939Z ##[debug]task result: Failed
2019-08-06T18:07:15.1593381Z ##[error]Error: getaddrinfo ENOTFOUND
login.windows.net login.windows.net:443
2019-08-06T18:07:15.1593735Z ##[debug]Processed: ##vso[task.issue
type=error;]Error: getaddrinfo ENOTFOUND login.windows.net
login.windows.net:443
2019-08-06T18:07:15.1606803Z ##[debug]Processed: ##vso[task.complete
result=Failed;]Error: getaddrinfo ENOTFOUND login.windows.net
login.windows.net:443
2019-08-06T18:07:15.1770289Z ##[section]Finishing: Azure App Service
Deploy: azurewebtestdeploy
Same as before unfortunately.
On Tue, Aug 6, 2019 at 7:32 AM Vincent A (vinca) notifications@github.com
wrote:
Can you please refer to this doc
https://docs.microsoft.com/en-us/azure/devops/pipelines/agents/proxy?view=azure-devops&tabs=windows
.—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
https://github.com/microsoft/azure-pipelines-tasks/issues/11061?email_source=notifications&email_token=ABGNA6ZQZZ73LFFSOFMPKZLQDEEILA5CNFSM4II7Q262YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOD3T46XQ#issuecomment-518508382,
or mute the thread
https://github.com/notifications/unsubscribe-auth/ABGNA6YGPG6HISIMWR6TQUTQDEEILANCNFSM4II7Q26Q
.
--
Fabio Stawinski
Any other idea what could I try? For me there is a bug somehow in the proxy, maybe I should use some other parameters to pass it thru.
@SumiranAgg , please look into this issue.
@fabiostawinski Are you still facing this issue?
Yes, still I have that issue... Seems for me some internal limitation in my
company's network. I cannot use my agents onprem to deploy any azure
service.
On Thu, Dec 5, 2019, 06:18 Eavanshi Arora notifications@github.com wrote:
@fabiostawinski https://github.com/fabiostawinski Are you still facing
this issue?—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
https://github.com/microsoft/azure-pipelines-tasks/issues/11061?email_source=notifications&email_token=ABGNA63YZ3G6RMWPCS2LTADQXCFI5A5CNFSM4II7Q262YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEF7QRHA#issuecomment-561973404,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/ABGNA66642FEFGOK3ZP6GLTQXCFI5ANCNFSM4II7Q26Q
.
@fabiostawinski this seems to be very specific to you infra, if you need any help to debug it further please open a support ticket with us or contact us at RM_Customer_Queries[at]microsoft[dot]com. thanks
@chshrikh this week we found the reason that was breaking this.
In the Microsoft docs, it says that to bypass a URL we have to use this notation "github\.com" -> doing this our build breaks like the error above placed.
Once we tried with the full URL, github.com:443 (without the slash) it worked. Seems really a bug (either the doc is wrong, or the bypass is not dealing well with "\" in the URLs.
Most helpful comment
Can you please refer to this doc.