mirror of
https://github.com/vimagick/dockerfiles.git
synced 2024-12-21 01:27:01 +02:00
update rslsync
This commit is contained in:
parent
51bc16f6e2
commit
a2566fc9a7
@ -12,11 +12,11 @@ RUN set -xe \
|
||||
&& apt-get purge -y --auto-remove curl \
|
||||
&& rm -rf /var/lib/apt/lists/*
|
||||
|
||||
ENV CONFIG_FILE /etc/rslsync.conf
|
||||
ENV STORAGE_PATH /data/.syncsystem
|
||||
ENV DIRECTORY_ROOT /data/syncaod
|
||||
ENV CONFIG_FILE /etc/rslsync.json
|
||||
ENV STORAGE_PATH /data/system
|
||||
ENV DIRECTORY_ROOT /data/user
|
||||
|
||||
COPY rslsync.conf $CONFIG_FILE
|
||||
COPY rslsync.json $CONFIG_FILE
|
||||
VOLUME /data
|
||||
EXPOSE 8888 55555
|
||||
|
||||
|
@ -13,33 +13,38 @@ rslsync:
|
||||
- "55555:55555"
|
||||
volumes:
|
||||
- ./data:/data
|
||||
- ./rslsync.conf:/etc/rslsync.conf
|
||||
- ./rslsync.json:/etc/rslsync.json
|
||||
restart: always
|
||||
```
|
||||
|
||||
## rslsync.conf
|
||||
## rslsync.json
|
||||
|
||||
```json
|
||||
{
|
||||
"device_name": "My Sync Device",
|
||||
"device_name": "Resilio Sync Server",
|
||||
"listening_port": 55555,
|
||||
"storage_path": "/data/.syncsystem",
|
||||
"storage_path": "/data/system",
|
||||
"pid_file": "/var/run/rslsync.pid",
|
||||
"use_upnp": false,
|
||||
"download_limit": 0,
|
||||
"upload_limit": 0,
|
||||
"directory_root": "/data/syncaod",
|
||||
"directory_root": "/data/user",
|
||||
"directory_root_policy": "all",
|
||||
"webui": {
|
||||
"listen": "0.0.0.0:8888"
|
||||
"listen": "0.0.0.0:8888",
|
||||
"login": "admin",
|
||||
"password": "admin"
|
||||
}
|
||||
}
|
||||
```
|
||||
|
||||
> Please change the default login/password.
|
||||
|
||||
## up and running
|
||||
|
||||
```bash
|
||||
$ docker-compose run --rm rslsync --dump-sample-config > rslsync.conf
|
||||
$ docker-compose run --rm rslsync rslsync --dump-sample-config > rslsync.json
|
||||
$ vi rslsync.json
|
||||
$ docker-compose up -d
|
||||
```
|
||||
|
||||
|
@ -1,14 +0,0 @@
|
||||
{
|
||||
"device_name": "My Sync Device",
|
||||
"listening_port": 55555,
|
||||
"storage_path": "/data/.syncsystem",
|
||||
"pid_file": "/var/run/rslsync.pid",
|
||||
"use_upnp": false,
|
||||
"download_limit": 0,
|
||||
"upload_limit": 0,
|
||||
"directory_root": "/data/syncaod",
|
||||
"directory_root_policy": "all",
|
||||
"webui": {
|
||||
"listen": "0.0.0.0:8888"
|
||||
}
|
||||
}
|
16
rslsync/rslsync.json
Normal file
16
rslsync/rslsync.json
Normal file
@ -0,0 +1,16 @@
|
||||
{
|
||||
"device_name": "Resilio Sync Server",
|
||||
"listening_port": 55555,
|
||||
"storage_path": "/data/system",
|
||||
"pid_file": "/var/run/rslsync.pid",
|
||||
"use_upnp": false,
|
||||
"download_limit": 0,
|
||||
"upload_limit": 0,
|
||||
"directory_root": "/data/user",
|
||||
"directory_root_policy": "all",
|
||||
"webui": {
|
||||
"listen": "0.0.0.0:8888",
|
||||
"login": "admin",
|
||||
"password": "admin"
|
||||
}
|
||||
}
|
@ -1,14 +0,0 @@
|
||||
[Unit]
|
||||
Description=Resilio Sync Daemon
|
||||
After=network.target
|
||||
AssertPathExists=/etc/rslsync.conf
|
||||
AssertPathIsDirectory=/data/.syncsystem
|
||||
AssertPathIsDirectory=/data/syncaod
|
||||
|
||||
[Service]
|
||||
ExecStart=/usr/bin/rslsync --nodaemon --config /etc/rslsync.conf
|
||||
Restart=always
|
||||
RestartSec=10
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
Loading…
Reference in New Issue
Block a user