Upload vendor (or any other) files using SFTP or SCP commands in ubuntu
Jun 4, 2021
Step 1: SCP Command to Securely Transfer Files
scp [filename].zip username@host:/path/to/destination
example: scp vendor.zip username@host:/path/to/destination
output
root@host password:
filename.txt 100% 0 0.0KB/s 00:00
example:vendor.zip 100% 0 0.0KB/s 00:00
Setp 2: Login to your server with ssh
ssh username@host
root@host password:
Setp 3: Go where you upload the file
root@hardware-512mb-sgp1-01:~# cd path/to/destination
Setp 4: Rename the existing file
mv filename newfilename
example: mv vendor oldvendor
Setp 5:Unzip the uploaded file
unzip filename.zip
example:unzip vendor.zip
Setp 6: Delete the zip file form server
rm filename.zip
example: rm vendor.zip
Setp 7: Delete the old file after you unzip the new file in serve
rm -r old file name
example:rm -r oldvendor