I am setting up a new Azure DevOps pipeline for my webapp. I can see that the build artifacts are saved in a path called $Build.ArtifactStagingDirectory
. Where this path variable is pointing to and how long I can access my artifact?
Also, Does Azure DevOps versions(keep track of all the artifacts built over a time) the artifacts built? If no, how to version my build artifacts?
In the agent there are 3 folders: a
, b
and s
. The variable $(Build.ArtifactStagingDirectory)
point to folder a
(artifacts), so the path is c:\agent\_work\1\a
(if the agent location is c:\agent
, the 1
can be another number also, according to how many builds there are, this number is incremental).
The artifacts not saved there! when you build the code all the code and the artifacts exist on folder s
(sources), the best practice is to copy only the artifacts to folder a
and then use the task "Publish build artifacts", in this task you take the artifacts from folder a
and put them on Azure DevOps storage or in your file share (if you use self-hosted agent).
From the Azure DevOps storage / file share the artifacts exist according to your retention policy.
If you save the artifacts in Azure DevOps you can access your artifacts from the build summary page or create a release pipeline. if you save them in a file share you can just access them there or in the release pipeline.
Collected from the Internet
Please contact [email protected] to delete if infringement.
Comments