ssh_backup_create
Create compressed database or file backups on a remote server over SSH, with automatic retention cleanup.
Instructions
Creates a database or file backup on the remote server over SSH, writing a compressed archive plus a JSON metadata file into backupDir. Supports mysql, postgresql, mongodb, and files (full is not yet implemented and errors). Database types require database; files requires paths. After writing it prunes backups older than retention days (default 7); compress defaults to true. Runs pre-backup and post-backup hooks.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| server | Yes | Server name | |
| type | Yes | Backup type: mysql, postgresql, mongodb, files, or full | |
| name | Yes | Backup name (e.g., production, app-data) | |
| database | No | Database name (required for db types) | |
| dbUser | No | Database user | |
| dbPassword | No | Database password | |
| dbHost | No | Database host (default: localhost) | |
| dbPort | No | Database port | |
| paths | No | Paths to backup (for files type) | |
| exclude | No | Patterns to exclude from backup | |
| backupDir | No | Backup directory (default: /var/backups/ssh-manager) | |
| retention | No | Retention period in days (default: 7) | |
| compress | No | Compress backup (default: true) |