Access to the Path is denied while running PowerShell script from Octopus

I am trying to deploy appsettings.yaml file onto the Azure VM via Octopus. I am getting below attached error.

It seems like Octopus is not able to resolve the extracted path onto the Azure VM. Ideally the values.csv file should be copied to the path C:\Octopus\Work\20210706212256-11379-134\values on VM.

XXXXX is the user that octopus is using to connect/deploy to Azure VM. I believe there should be access/privileges either on the octopus user XXXXX or on the C:\Octopus\Work\20210706212256-11379-134\values.

Could someone please take a look? Please let me know if you need any more details.

Hi abommara,

Firstly I wanted to welcome you to the Octopus Deploy community and thanks for reaching out!

From the information you’ve provided it looks as though the user that’s running the Tentacle service doesn’t have the correct permissions for what the script is attempting to perform. Are you able to confirm this?

Looking forward to hearing from you.
Kindest regards,
Lauren