There are a few ways to handle this with your on-prem instance. There are also multiple reasons you would want/need to complete this task.
An example would be uploading images to customize your logo. Or pulling a large log file if you have tailed logs and output them to a txt file.
Upload
A couple of ways to handle this would be using rsync or wget.
rsync:
rsync -rv --progress ~/local/path/to/file sshusername@domain.com:/path/to/destination/
*replacing the "local path to file" - "sshusername" - "domain.com" - "path to destination"
rsync uses your SSH credentials to sync the file(s) up to your server. You can also use the IP address instead of the "domain.com" if this is how you normally SSH.
An example of this can be:
rsync -rv --progress /mnt/drive2/image.png admin@192.168.1.72:/mnt/drive4/incoming/
wget:
To use wget, you would need to first SSH into your server and navigate to the destination directory.
Once you are inside the directory that you would like to download the file/image to, simply run "wget" and the link to the file.
Example:
ssh admin@192.168.1.72
cd /mnt/drive4/incoming/
wget https://assets-global.website-files.com/650d8cb4b59554163db63bab/6567bb4768571a896f128775_Blog_Article_ProductUpdate-p-1080.webp
This would pull the image from the link provided, and save it in the directory that you are currently in.
Download
Using rsync/ssh you can also pull a file from your server to your local computer.
rsync -arvz --progress sshusername@domain.com:/path/to/file/file ~/path/to/local/
Example of this would be:
rsync -arvz --progress admin@192.168.1.72:/home/admin/images-folder/image.png ~/Downloads/images/
Comments
0 comments
Article is closed for comments.