Support Center

Downloading Files with JumpCloud Commands

As a JumpCloud Administrator, you may find a situation that you will need to call upon a file during a script execution with the Commands tab.  While there is a file attachment feature that is further discussed in the Using the Commands Tab article, this currently has a 1MB limit for the attachment.

In scenarios where a file larger than 1MB is required, it is suggested to host the file onto a web server, such as Amazon S3, which may then be called upon through the Commands tab.  Below, you can find command examples for both Bash (Mac and Linux) and PowerShell (Windows) to download the file to the target system:

Mac & Linux:
 
curl -o /tmp/YOUR_FILE.EXTENSION "WEB_SERVER_DOWNLOAD_PATH"
 
Windows (PowerShell):

 

(New-Object System.Net.WebClient).DownloadFile("WEB_SERVER_DOWNLOAD_PATH", "$env:TEMP/YOUR_FILE.EXTENSION")


Note: In both examples above the file download path is the temporary directory for the respective operating system.


To see a further example of this download command function, you may evaluate our Downloading JumpCloud Agent from the Command-Line article which also uses these command structures.

 

Last Updated: Dec 16, 2016 09:50AM MST

Related Articles
desk-forwarding@jumpcloud.com
http://assets3.desk.com/
false
desk
Loading
seconds ago
a minute ago
minutes ago
an hour ago
hours ago
a day ago
days ago
about
false
Invalid characters found
/customer/en/portal/articles/autocomplete