Answer the question
In order to leave comments, you need to log in
How to permanently sync a file with a remote server via ssh?
I often debug programs on remote pieces of iron. As a rule, they cannot be debugged on the local computer. But I develop locally, in an IDE and with a local git client. I want a tool that keeps a remote directory up to date on a linux system based on the local directory on my macos laptop.
I need automatic synchronization for any changes in files in directories of any nesting level (not by timer), using ssh as a channel. Ideally, if there is a gui for MacOS
No need:
1) Additional software, except for ssh on the target server
2) Incremental copying
3) Manual start or start by timer
Is there anything similar?
Answer the question
In order to leave comments, you need to log in
use syncthing, the transmission channel is encrypted with TLS 1.2 or higher.
think of it as the next evolution of rsync .
the demon, listens to inotify and immediately forwards the changes to the remote.
there is also resilio, the source code is closed, commerce, but there is a free version for 10 distributions (emnip).
- synchronize the local directory with the contents of the directory on the remote server:
rsync -aqxP --progress [email protected]:/tmp/test/ /home/user/test/
- synchronize the directory on the remote server with the contents of the local directory:
rsync -aqxP --progress /home/user/test/ [email protected]:/tmp/test/
- sync on a non-standard port via SSH:
rsync -e='ssh -p 44444' -aqxP /project /webelement/ hoster.ru:/project/webelement/
You can also use the switches -vz
-v- display detailed information about the copy process
-z- compress files before transfer
Full documentation on Rsync in Russian can be found on the site: wiki.opennet .ru/Rsync
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question