Documentation shows that you can download the build artifacts using the DownloadBuildArtifacts task which allows you to specify the folder where the content is stored.
However, when using the Deployment task the build artifacts are downloaded by default to a directory which does not appear to by specified by a predefined variable.
There appear to be two workarounds, you can use a root variable like $(System.WorkFolder) and hard code the rest of the path or you can duplicate the artifact download process using the DownloadBuildArtifacts task to put the artifacts in a known location.
⚠Do not edit this section. It is required for docs.microsoft.com ➟ GitHub issue linking.
@KSchlobohm Thank you for the feedback, assigning this to the author for review.
For needed predefined variables, consider using Suggest a feature in the Visual Studio community to hear from the product team.
Thanks @msebolt, looks like this is a topic that was already discussed and the solution is to use the $(Agent.BuildDirectory) which solves my problem.
I think it would be helpful to add a note that when using the deployment task you can reference the content with this variable. Another place that would have helped me is if the variable had been called out on the deployment task's documentation.
@KSchlobohm Thank you for your feedback. The updated version will go live shortly.
Most helpful comment
Thanks @msebolt, looks like this is a topic that was already discussed and the solution is to use the
$(Agent.BuildDirectory)which solves my problem.I think it would be helpful to add a note that when using the deployment task you can reference the content with this variable. Another place that would have helped me is if the variable had been called out on the deployment task's documentation.