Update deploy seafile with docker.md

This commit is contained in:
lian 2021-01-13 13:47:07 +08:00 committed by GitHub
parent 559c1680ad
commit 31057aa8d5
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -168,7 +168,6 @@ Steps:
Backup Order: Database First or Data Directory First
* backing up Database:
```bash
# It's recommended to backup the database to a separate file each time. Don't overwrite older database backups for at least a week.
cd /opt/seafile-backup/databases
@ -180,7 +179,6 @@ Backup Order: Database First or Data Directory First
* Backing up Seafile library data:
* To directly copy the whole data directory
```bash
cp -R /opt/seafile-data/seafile /opt/seafile-backup/data/
cd /opt/seafile-backup/data && rm -rf ccnet
@ -188,7 +186,6 @@ Backup Order: Database First or Data Directory First
```
* Use rsync to do incremental backup
```bash
rsync -az /opt/seafile-data/seafile /opt/seafile-backup/data/
cd /opt/seafile-backup/data && rm -rf ccnet
@ -198,7 +195,6 @@ Backup Order: Database First or Data Directory First
### Recovery
* Restore the databases:
```bash
docker cp /opt/seafile-backup/databases/ccnet_db.sql seafile-mysql:/tmp/ccnet_db.sql
docker cp /opt/seafile-backup/databases/seafile_db.sql seafile-mysql:/tmp/seafile_db.sql
@ -211,7 +207,6 @@ Backup Order: Database First or Data Directory First
```
* Restore the seafile data:
```bash
cp -R /opt/seafile-backup/data/* /opt/seafile-data/seafile/
@ -231,5 +226,3 @@ You can run docker commands like "docker exec" to find errors.
docker exec -it seafile /bin/bash
```