.
This commit is contained in:
@@ -1,35 +1,40 @@
|
||||
# Setup
|
||||
|
||||
## Requirements
|
||||
## Install
|
||||
|
||||
### Requirements
|
||||
|
||||
- Docker
|
||||
|
||||
_Currently hosted on an ubuntu lxc container with docker and portainer [+ information](setup-lxc.md)._
|
||||
|
||||
## /Services (Stacks)
|
||||
### Services (Stacks)
|
||||
|
||||
### Gitea
|
||||
If portainer installed use portainer (default https//host:9000) to setup/manage services
|
||||
|
||||
[Docker Compose](../docker/docker-compose.yaml)
|
||||
#### Gitea
|
||||
|
||||
### Duplicati
|
||||
- Stack Name: gitea
|
||||
_[Docker Compose](../docker/docker-compose.yaml)_
|
||||
|
||||
- [Docker File](https://git.limbosolutions.com/kb/duplicati/docker/sqlclient.dockerfile)
|
||||
- [Docker Compose](../docker/docker-compose.yaml)
|
||||
|
||||
### Restore
|
||||
## Restore
|
||||
|
||||
### Requirements
|
||||
|
||||
- Host setup with docker and portainer ./setup.md
|
||||
|
||||
|
||||
1) Execute Setup process
|
||||
1) Check Every Container is ok and running
|
||||
1) Stop Every Container (including portainer, if restoring portainer is a requirement) except duplicati
|
||||
1) Enter Duplicati
|
||||
1) Import Backjob (if possible, if not possible next steps must be adapted)
|
||||
2) Stop Every Container except duplicati (including portainer, if restoring portainer is a requirement)
|
||||
_note: restore portainer not tested_
|
||||
3) Enter Duplicati
|
||||
4) Import Backup job (if not possible next steps must be adapted)
|
||||
- All Imported jobs schedules must be disabled (or disable write permissions on backup host)
|
||||
1) Restore all files to original location
|
||||
- If database engine is diferent do not restore db_data and check restore database before next steps
|
||||
1) Start Container and check if everything is ok
|
||||
5) Restore all files to original location
|
||||
- If database engine is diferent do not restore db_data and check restore database **before next steps**
|
||||
6) Start Containers and check if everything is ok
|
||||
|
||||
#### Database
|
||||
### Database
|
||||
|
||||
Only required of database data files not recovarable (example: diferent database engine from backup)
|
||||
|
||||
@@ -37,3 +42,29 @@ Only required of database data files not recovarable (example: diferent database
|
||||
2) Start Database container (if stopped in restore process)
|
||||
3) Enter duplicati bash (by using portainer)
|
||||
4) Execute Command
|
||||
|
||||
````bash
|
||||
|
||||
```bash
|
||||
#check last files db-dumps
|
||||
ls /git/db-dumps
|
||||
#pick file to import (maybe the last one :))
|
||||
```
|
||||
|
||||
import file
|
||||
|
||||
```bash
|
||||
DB_FILE=filenametoimport
|
||||
# by default duplicati container dont have de enviroment varible ${DB_ROOT_PASSWORD}
|
||||
DB_ROOT_PASSWORD=youdbrootpassword
|
||||
mysql -uroot -p'${DB_ROOT_PASSWORD}' ${DB_NAME} < /git/db-dumps/$DB_FILE
|
||||
```
|
||||
|
||||
|
||||
|
||||
|
||||
````
|
||||
3) start all stop containers and check everyting is ok
|
||||
4) Execute backup on duplicati
|
||||
5) Check backup is restorable
|
||||
6) Re Enable schedule backups on duplication
|
||||
Reference in New Issue
Block a user