How to Distribute Files in Remote Execution
Send files from your computer to multiple remote computers without user interaction.
What's the difference between 'copying' and 'distributing' files?
The main difference is the source of the files, in other words from where you want to copy files. When you need to copy files from your own computer to target computers, you can distribute files. When you want to copy files on the target computer from one folder to another, you can copy files.
Authentication is required only once when you run a Remote Execution step.
- On the Remote Execution page, select Create new job.
Result: The Create job page is displayed.
- Choose the platform where you want to run automation steps.
- Add the File distribution step to the list on the left.
- Click Upload to select the file(s) you want to distribute.
Note: You can reference the file(s) from the script. You can upload up to three files per job with a maximum size of 1GB each. Any file can be used.
- Set the Destination Folder.
- Under Overwrite existing files, choose whether to overwrite files that already exist on remote computers.
- Click Next.
- From the list of Devices define the devices or a group of devices that will receive the script.
You can organize your devices by selecting a grouping option from the top of the list.
- Click Next.
- Name the job in a way that is easy to remember later on.
Optionally, you can schedule jobs up to seven days in advance. To do so, toggle Schedule this job and set the time and date for the job to run.
- Click Run.
Note: A preset timeout pertains to both the job and the step.
A timeout for every step is set to two hours, meaning that GoTo Resolve waits two hours for the script to finish on the remote computer. When the script finishes, GoTo Resolve starts the next step and waits another two hours for that step to finish. If a step does not finish on a remote computer in two hours, then it times out and the whole job fails.
When you reference a file from the script, you only have to enter its name. Once the step ends, the file is deleted from the remote computer, unless it is copied somewhere else with the script.
You upload 'a.txt' file for the job and you would like to copy it into a folder (also known as file distribution). Your script should look something like this:
Copy-Item a.txt C:\Destination