An open API service indexing awesome lists of open source software.

https://github.com/xigang/file-sync

Real-time watch file changes and sync files to remote server.
https://github.com/xigang/file-sync

files scp ssh sync

Last synced: 7 months ago
JSON representation

Real-time watch file changes and sync files to remote server.

Awesome Lists containing this project

README

          

## Overview
file-sync is a real-time watch file changes and sync files to remote server.

## Installation

Make sure you have a working Go environment. Go version 1.2+ is supported. [See the install instructions for Go.](https://golang.org/doc/install)

```
$ go get github.com/xigang/file-sync
$ go build -o file-sync
```
Move file-sync binary to your `PATH`

## WARN

Need to generate a secret key on the source host and put the public key on the target host before executing the program.

```
STEP 1:
#ssh-keygen -t rsa

STEP 2:
# scp /root/.ssh/id_rsa.pub root@remote_server_adress:/root/.ssh/authorized_keys
```

## Example

```
$ file-sync -username= \
-ssh-key= \
-hostname= \
-filename= \
-remote-path=
```

## License

- [Apache License](LICENSE)