| 1 | { |
| 2 | "_comment": "DigitalOcean Spaces lifecycle (S3-compatible). Apply with `s3cmd setlifecycle lifecycle.json s3://shithub-backups`. Two prefixes: WAL segments (cheaper to keep, archive sooner) and daily logical dumps (kept longer, primary recovery path).", |
| 3 | "Rules": [ |
| 4 | { |
| 5 | "ID": "wal-30day-retention", |
| 6 | "Status": "Enabled", |
| 7 | "Filter": {"Prefix": ""}, |
| 8 | "Expiration": {"Days": 30} |
| 9 | }, |
| 10 | { |
| 11 | "ID": "daily-90day-retention", |
| 12 | "Status": "Enabled", |
| 13 | "Filter": {"Prefix": "daily/"}, |
| 14 | "Expiration": {"Days": 90} |
| 15 | }, |
| 16 | { |
| 17 | "ID": "abort-stale-multipart", |
| 18 | "Status": "Enabled", |
| 19 | "Filter": {"Prefix": ""}, |
| 20 | "AbortIncompleteMultipartUpload": {"DaysAfterInitiation": 2} |
| 21 | } |
| 22 | ] |
| 23 | } |