mirror of
https://github.com/yanhao98/docker-example.git
synced 2025-07-13 16:20:50 +08:00
更新 README.md,修改 syncthing Docker 命令中的挂载方式,并修正文件夹路径说明
This commit is contained in:
@ -11,7 +11,7 @@ SOURCE1=/path/to/backup1
|
|||||||
|
|
||||||
docker run -d --restart unless-stopped --name syncthing \
|
docker run -d --restart unless-stopped --name syncthing \
|
||||||
-h $HOSTNAME \
|
-h $HOSTNAME \
|
||||||
-v $SOURCE1:/host$SOURCE1 \
|
--mount type=bind,source=$SOURCE1,target="/host$SOURCE1" \
|
||||||
--mount type=volume,source=st-sync-cfg,target=/var/syncthing/config \
|
--mount type=volume,source=st-sync-cfg,target=/var/syncthing/config \
|
||||||
-e PUID=0 -e PGID=0 \
|
-e PUID=0 -e PGID=0 \
|
||||||
-e TZ=Asia/Shanghai \
|
-e TZ=Asia/Shanghai \
|
||||||
@ -21,7 +21,7 @@ docker run -d --restart unless-stopped --name syncthing \
|
|||||||
|
|
||||||
- 访问`https://服务器ip:28198`
|
- 访问`https://服务器ip:28198`
|
||||||
- 设置用户名密码
|
- 设置用户名密码
|
||||||
- 添加文件夹: 文件夹路径固定填`/host`
|
- 添加文件夹: 文件夹路径固定填`/host$SOURCE1`
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
docker exec -it syncthing find /host -maxdepth 3
|
docker exec -it syncthing find /host -maxdepth 3
|
||||||
|
Reference in New Issue
Block a user