Updated gitea markdown documentation to include updated path
This commit is contained in:
1 parent
bad58cef49
commit
d70ce193d8
1 file changed
+11
-4
+11
-4
@@ -16,15 +16,22 @@ Run the automated backup script to trigger the dump, copy the archive to the bac
|
|||||||
sudo /srv/docker/gitea/gitea_backup.sh
|
sudo /srv/docker/gitea/gitea_backup.sh
|
||||||
```
|
```
|
||||||
|
|
||||||
|
### Script Overview
|
||||||
|
* **Database & Repository Snapshot**: Executes `docker exec -u git -w /tmp gitea bash -c 'mkdir -p /data/gitea/tmp && /usr/local/bin/gitea dump -c /data/gitea/conf/app.ini -f /data/gitea/tmp/gitea-dump.zip'` inside the container.
|
||||||
|
* **Storage Path**: Creates full backup folders at `/mnt/5TB-Disk1/backup/services/gitea/backup_YYYY-MM-DD_HHMMSS`.
|
||||||
|
* **Pointer File**: Updates `/mnt/5TB-Disk1/backup/services/gitea/latest.txt` with the path to the most recent backup directory.
|
||||||
|
* **Retention**: Automatically deletes backup directories older than 30 days.
|
||||||
|
* **Notifications**: Sends success and failure alerts to `ntfy.speerfam.net`.
|
||||||
|
|
||||||
## Manual Backup
|
## Manual Backup
|
||||||
|
|
||||||
If you need to perform a manual backup without running the script:
|
If you need to perform a manual backup without running the script:
|
||||||
|
|
||||||
### 1. Generate Dump File
|
### 1. Generate Dump File
|
||||||
Run the internal `gitea dump` command inside the container:
|
Run the internal `gitea dump` command inside the container into the `git`-owned `/data/gitea/tmp` directory:
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
sudo docker exec -u git -w /tmp gitea bash -c '/usr/local/bin/gitea dump -c /data/gitea/conf/app.ini -f /data/gitea-dump.zip'
|
sudo docker exec -u git -w /tmp gitea bash -c 'mkdir -p /data/gitea/tmp && /usr/local/bin/gitea dump -c /data/gitea/conf/app.ini -f /data/gitea/tmp/gitea-dump.zip'
|
||||||
```
|
```
|
||||||
|
|
||||||
### 2. Copy Archive to Backup Destination
|
### 2. Copy Archive to Backup Destination
|
||||||
@@ -36,10 +43,10 @@ TARGET_DIR="/mnt/5TB-Disk1/backup/services/gitea/manual_$(date +%Y-%m-%d)"
|
|||||||
mkdir -p "$TARGET_DIR"
|
mkdir -p "$TARGET_DIR"
|
||||||
|
|
||||||
# Rsync zip archive to backup location
|
# Rsync zip archive to backup location
|
||||||
sudo rsync -av --no-owner --no-group /srv/docker/gitea/data/gitea-dump.zip "$TARGET_DIR/gitea-dump.zip"
|
sudo rsync -av --no-owner --no-group /srv/docker/gitea/gitea/tmp/gitea-dump.zip "$TARGET_DIR/gitea-dump.zip"
|
||||||
|
|
||||||
# Clean up temporary staging archive on host source
|
# Clean up temporary staging archive on host source
|
||||||
sudo rm -f /srv/docker/gitea/data/gitea-dump.zip
|
sudo rm -f /srv/docker/gitea/gitea/tmp/gitea-dump.zip
|
||||||
```
|
```
|
||||||
|
|
||||||
---
|
---
|
||||||
|
|||||||
Reference in new issue
Block a user