ramirojoaquin / vestacp-borg-incremental-backups

A series of bash scripts to perform incremental backups of Vesta Control Panel users and server config, using Borg Backup as backend.
GNU General Public License v3.0
23 stars 15 forks source link

Port != 22 #3

Open vedavrat opened 5 years ago

vedavrat commented 5 years ago

REMOTE_BACKUP_SERVER=ip_address...

But if the Port number is not equal 22, but other number?

REMOTE_BACKUP_SERVER_PORT=22222 have not helped...

What to do? Thank you. Dvanyavada.

ramirojoaquin commented 5 years ago

You can simply put: REMOTE_BACKUP_SERVER="IP:PORT"

Example: REMOTE_BACKUP_SERVER="135.54.557.45:22222"

quacos commented 4 years ago

You can simply put: REMOTE_BACKUP_SERVER="IP:PORT"

Example: REMOTE_BACKUP_SERVER="135.54.557.45:22222"

This is not going to work, as REMOTE_BACKUP_SERVER is used by rsync.

Syntax for rsync over SSH with port != 22 is

rsync -e 'ssh -p PORT'

My solution: create an entry in the file .ssh/config like this

Host YOUR_HOST Port YOUR_PORT