0

My agent is installed in C:/azagent, as it was by default after running the powershell script created for me when creating a new deployment group.

My build artifact "drop" gets placed in C:\azagent\A1\_work\r2\a\_TransactionImportTurkey-Test\drop

It is here i run into issues. I want to copy the files over to V:\Program\TransactionImportTurkey\TransactionImportApp but get this error:

enter image description here

I have no issues copying the files when i use a filepath within C:/ root directory.

This is the YAML-file :

enter image description here

How can I make a release to another root directory than C:/ ?

Evandro Pomatti
  • 13,341
  • 16
  • 97
  • 165
Erik
  • 13
  • 3
  • Is `V:` a mapped drive, or a physical drive on the machine? – WaitingForGuacamole Dec 02 '21 at 13:39
  • It would seem it is a mapped drive (?). It looks like this https://imgur.com/6j16b6K – Erik Dec 02 '21 at 13:50
  • Hi Erik, and welcome to stack overflow. Can I make a suggestion? Your question would be improved if you paste in the relevant part of your yaml code, and the error message, both in text format. It helps readability and indexability and so on, better than screenshots. – Vince Bowdren Dec 02 '21 at 21:55

1 Answers1

0

I would do four things here:

First, ensure that your Azure Pipelines Agent is running under a domain account and not a local one.

Second, ensure that the target folder grants write privileges to that account.

Third, run net use to get the target mapping for V:

Fourth, change the target path for your copy to reference the path by the UNC mapping for V:, so instead of V:\Program\TransactionImportTurkey\TransactionImportApp, it would be \\TargetServerNameOrIP\PathToTargetShare\Program\TransactionImportTurkey\TransactionImportApp

WaitingForGuacamole
  • 3,744
  • 1
  • 8
  • 22
  • Thank you for your response. I have done the steps and replaced the filepath with the UNC mapping return from command net use in CMD, for the V:/ directory. I now get the error: " ##[error]The network path was not found. : '\\xxx\xxx\Data\Program\TransactionImportTurkey\TransactionImportAppTestingRelease' " Replaced the "real" path with "xxx" due to security concerns. Do you have any idea what might cause this? – Erik Dec 02 '21 at 15:15
  • Is your agent actually on the same network as the file share? (or is this a Microsoft-hosted agent?) – WaitingForGuacamole Dec 02 '21 at 15:18
  • I'm not too familiar with agents and how they work, nor with networks, so I'm not entirely sure. The agent is installed in the C:/ directory on the virtual machine. I installed it via a powershell script I was given from Azure Devops when creating a deployment group. – Erik Dec 02 '21 at 15:25
  • Maybe the C:/ drive isnt part of the network? – Erik Dec 02 '21 at 15:26
  • is `\\xxx` on your premises network? is the agent in an Azure virtual machine, or on premises as well? – WaitingForGuacamole Dec 02 '21 at 15:31
  • This is how it looks https://i.imgur.com/q92gva4.png The agent is, of my understand, not in an azure virtual machine, but on premises. – Erik Dec 02 '21 at 15:44