Prune old archives
This commit is contained in:
		
							parent
							
								
									36798f9cf4
								
							
						
					
					
						commit
						14ac2d9763
					
				| @ -1,5 +1,5 @@ | |||||||
| Package: tupper | Package: tupper | ||||||
| Version: 0.1 | Version: 0.1.1 | ||||||
| Maintainer: Martin "maride" Dessauer | Maintainer: Martin "maride" Dessauer | ||||||
| Architecture: all | Architecture: all | ||||||
| Depends: cron (>= 3.0), borgbackup (<< 2), sshfs (>= 3) | Depends: cron (>= 3.0), borgbackup (<< 2), sshfs (>= 3) | ||||||
|  | |||||||
| @ -8,6 +8,7 @@ Drops of glue between [SSHFS](https://github.com/libfuse/sshfs), [Borg](https:// | |||||||
| - Encrypted, deduplicated backups thanks to Borg | - Encrypted, deduplicated backups thanks to Borg | ||||||
| - Backup of specified directories to SSHFS | - Backup of specified directories to SSHFS | ||||||
| - Daily cron scheduler | - Daily cron scheduler | ||||||
|  | - Auto-prune old archives | ||||||
| 
 | 
 | ||||||
| ## Usage | ## Usage | ||||||
| 
 | 
 | ||||||
| @ -18,7 +19,7 @@ Then either run `sudo tupper backup` or wait for the daily cron scheduler to kic | |||||||
| 
 | 
 | ||||||
| ## Building | ## Building | ||||||
| 
 | 
 | ||||||
| `dpkg-deb --build . tupper_0.1_all.deb` | `dpkg-deb --build . tupper_0.1.1_all.deb` | ||||||
| 
 | 
 | ||||||
| ## TODO / Known pitfalls | ## TODO / Known pitfalls | ||||||
| 
 | 
 | ||||||
|  | |||||||
| @ -47,6 +47,7 @@ if [ "$ACTION" = "initialize" ]; then | |||||||
| 	borg init --encryption=repokey "$TARGET" | 	borg init --encryption=repokey "$TARGET" | ||||||
| elif [ "$ACTION" = "backup" ]; then | elif [ "$ACTION" = "backup" ]; then | ||||||
| 	borg create --stats "$MOUNTPOINT::"'{now}' "$TARGET" | 	borg create --stats "$MOUNTPOINT::"'{now}' "$TARGET" | ||||||
|  | 	borg prune --list --show-rc --keep-daily 7 --keep-weekly 4 --keep-monthly 3 "$MOUNTPOINT" | ||||||
| 	borg list "$MOUNTPOINT" | 	borg list "$MOUNTPOINT" | ||||||
| fi | fi | ||||||
| 
 | 
 | ||||||
|  | |||||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user