Forum Discussion
sujith2150
Jan 25, 2023Copper Contributor
Getting 404 Not found Error when running in Devops Pipeline
Hi Team, we are using Azure Devops and we have configure to use self hosted agent. The reason we need to talk to our internal Network I have a script like below $URL= 'https://pamtst-ccp...
sujith2150
Jan 26, 2023Copper Contributor
varunmittal Thanks for replying.
Checked the url and not using any environment variables.
I Want to understand when you say server is not accessible from the pipeline.
My understanding is like when i create the self hosted agent the pipeline is running on that server not on the devops. So if my scripts from self hosted agent server it should also run from pipeline right?
Pleas correct my understanding.
varunmittal
Jan 26, 2023Copper Contributor
Yes, your understanding is mostly correct. When you use a self-hosted agent, the pipeline runs on the same machine as the agent, which means that the pipeline has access to the same resources and environment as the agent.
However, there can be some differences between the pipeline and the agent, for example, the pipeline may be running in a different context or environment, or the pipeline may be running with different permissions or credentials.
Also, there could be some network/firewall restrictions that only allow the self-hosted agent to access the server but not the pipeline.
In your case, since the script works when you run it from the self-hosted agent, but it doesn't work when you run it from the pipeline, it's likely that the pipeline is running in a different context or environment and is unable to access the server, or that the pipeline is running with different permissions or credentials.
It's also possible that the script is not running as expected, as there could be some logic or syntax errors in the script that are causing it to fail.
I recommend checking the pipeline's configuration and environment to see if there are any differences between the pipeline and the agent, and to also check the script again for any errors or logical issues.
However, there can be some differences between the pipeline and the agent, for example, the pipeline may be running in a different context or environment, or the pipeline may be running with different permissions or credentials.
Also, there could be some network/firewall restrictions that only allow the self-hosted agent to access the server but not the pipeline.
In your case, since the script works when you run it from the self-hosted agent, but it doesn't work when you run it from the pipeline, it's likely that the pipeline is running in a different context or environment and is unable to access the server, or that the pipeline is running with different permissions or credentials.
It's also possible that the script is not running as expected, as there could be some logic or syntax errors in the script that are causing it to fail.
I recommend checking the pipeline's configuration and environment to see if there are any differences between the pipeline and the agent, and to also check the script again for any errors or logical issues.
- sujith2150Jan 26, 2023Copper ContributorThanks Varun.
Can you please let me know how can I jeck the pipeline configuration and environment?