0

I think what I am looking to do is fairly simple - I just can't wrap my head around it.

I've got a repo in AzDo. This repo contains configuration files for firewalls. This is how we manage changes in these configurations.

I've got a simple build pipeline that copies the relevant files and creates an artifact.

I have a release pipeline that gets the files onto the on-prem machine in my Deployment Group. The files show up in c:\azagent\r1\_work\<artifact folder>.

As part of this pipeline I am looking to copy the files from c:\azagent\r1\_work\<artifact folder> to e:\shares\<artifact name>. This is the part that I cannot figure out how to make work.

What strategy could I use to put this together? I've looked into the documentation but it seems like this is somewhat of an edge case (not deploying an app or web site, etc). Ideally, I'd love to do this in a multi-stage YAML pipeline - but from what I've read, it appears as if these do not yet support Deployment Groups. So a classic pipeline is fine for now.

halfer
  • 19,824
  • 17
  • 99
  • 186

1 Answers1

0

You can add a copy file task(Click the plus sign(+) on the agent job and search for copy files) in your release pipeline to copy the files to a different place on your local machine.

enter image description here

Then you can specify the source folder(ie. $(System.DefaultWorkingDirectory)), and the contents to copy and the target folder(ie. e:\shares\). In below example all contents in $(System.DefaultWorkingDirectory)(ie. C:\agent\_work\r1\a) will be copied to folder D:\Test\New folder

Please check the prefined variables for more information about its map to the local folders.

enter image description here

Levi Lu-MSFT
  • 27,483
  • 2
  • 31
  • 43