eb69ee13e6d57248e27aeafadb1274247d564c17
Gitea Docker
A simple Docker Compose setup for running Gitea with Tailscale networking.
Backup
This project includes a backup runner that uses Gitea's built-in gitea dump command.
Manual Backup
./gitea-dump-backup.sh
Automated Backup (Cron)
The backup runs automatically on the 1st of every month at 2:00 AM.
To install the cron job:
crontab ./gitea-backup.cron
Or append to existing crontab:
crontab -l | cat - ./gitea-backup.cron | crontab -
Configuration
Edit the script variables to customize:
REMOTE_HOST: Remote backup server (default:workstation)REMOTE_PATH: Remote backup path (default:/mnt/data/git-backups)KEEP_LOCAL: Number of local backups to keep (default: 3)
Requirements
- SSH access to the remote backup server
rsyncinstalled locally- Backup directory must exist on remote server
Quick Start
-
Create the remote backup directory:
ssh workstation "mkdir -p /mnt/data/git-backups" -
Start Gitea:
docker compose -f docker-compose.gitea.yml up -d
Description
Languages
Shell
88.1%
Dockerfile
11.9%