mirror of
https://github.com/brufdev/many-notes.git
synced 2026-01-26 12:58:51 -06:00
Add instructions on how to backup and restore the database
This commit is contained in:
22
README.md
22
README.md
@@ -23,7 +23,7 @@ Vaults are simply storage containers for your files, and Many Notes provides you
|
||||
- Light/dark theme (automatically selected by your OS setting)
|
||||
- Mobile friendly
|
||||
|
||||
## Installation guide (Docker)
|
||||
## Installation (Docker)
|
||||
|
||||
Create a new directory called `many-notes`. Inside this directory, create a file named `compose.yaml` and paste the following content:
|
||||
|
||||
@@ -116,6 +116,26 @@ Configure an email service to send registration and password reset emails by add
|
||||
- MAIL_FROM_NAME="Many Notes"
|
||||
```
|
||||
|
||||
## Backup and restore
|
||||
|
||||
All your non-note files are saved in the `storage-private` volume, while your notes are stored in the database.
|
||||
|
||||
#### Backup database
|
||||
|
||||
To back up your database, run:
|
||||
|
||||
```shell
|
||||
docker exec many-notes-mariadb-1 mariadb-dump --all-databases -uroot -p"$MARIADB_ROOT_PASSWORD" > ./backup-many-notes-`date +%Y-%m-%d`.sql
|
||||
```
|
||||
|
||||
#### Restore database
|
||||
|
||||
To restore your database from a backup, run:
|
||||
|
||||
```shell
|
||||
docker exec -i many-notes-mariadb-1 sh -c 'exec mariadb -uroot -p"$MARIADB_ROOT_PASSWORD"' < ./$BACKUP_FILE_NAME.sql
|
||||
```
|
||||
|
||||
## License
|
||||
|
||||
This project is licensed under the MIT License. See the [LICENSE](LICENSE) file for the full license text.
|
||||
|
||||
Reference in New Issue
Block a user