Backup files cleaner.
User can add multiple cleanup rules
Begin) and (now + cleanup_range End), cleanup will stop.X_n) and (now + duration Y_n), 1 backup will be kept for each (duration Z_n).| Name | Default | Description |
|---|---|---|
| DRY_RUN | false | Dry run. |
| CLEANUP_DIR | /data | Bakcup files folder. |
| CLEANUP_FILE_PATTERN | .+ | Filename pattern of backup files to manage. |
| CLEANUP_RANGE | 1hour,-500years | Map cleanup range to Begin,End. |
| CLEANUP_STRATEGY | -1hour,-1day,1hour;-1day,-1week,1day;-1week,-1month,1week;-1month,-1year,1month | Map each cleanup rule to string X_n,Y_n,Z_n, then join strings with ;. |
| GET_CREATED_AT | (filename) => fs.statSync(path.join(CLEANUP_DIR, filename)).birthtime | Function to get file creation time. |
Supported time inverval units are year(s), month(s), week(s), day(s), hour(s), minute(s), second(s), and millisecond(s).
Content type
Image
Digest
sha256:110f5978c…
Size
341.1 MB
Last updated
over 3 years ago
docker pull cookding/lysosome:2.0.0