gancio/docs/install/backup.md

23 lines
864 B
Markdown
Raw Normal View History

2021-06-04 15:34:40 +02:00
---
layout: default
title: Backup
2021-06-04 15:52:35 +02:00
permalink: /install/backup
2021-06-04 15:34:40 +02:00
nav_order: 5
parent: Install
---
## Backup
The following commands should be valid for every setup (docker/debian/sqlite/postgres) but check your installation directory first.
2021-06-04 15:52:35 +02:00
This includes database, configuration, custom user locales, logs, images and thumbnails.
2021-06-04 15:34:40 +02:00
```bash
cd /opt/gancio/ # or /home/gancio or where your installation is
tar -czf gancio-$(date +%Y-%m-%d-%H%M%S)-backup.tgz \
$(ls -d config.json uploads user_locale db.sqlite postgres data logs 2> /dev/null)
```
> warning "Permission denied"
2021-06-24 16:00:15 +02:00
> `postgres` directory could have different permission or owner, in this case you need to be root or use `sudo` instead.
2021-06-04 15:34:40 +02:00
> info "Automatic backup"
> To periodically backup your data you should probably use something like [restic](https://restic.net) or [borg](https://www.borgbackup.org/)