Showing with 8 additions and 2 deletions.
  1. +6 −0 CHANGELOG.md
  2. +1 −1 metadata.json
  3. +1 −1 templates/tidy_cron.epp
6 changes: 6 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
# Z Release 4.2.2

## Bug Fixes:
- Tidy cron jobs would only delete metric files exactly retention_days away
- [PR #33](https://github.com/npwalker/pe_metric_curl_cron_jobs/pull/33)

# Z Release 4.2.1

## Bug Fixes:
Expand Down
2 changes: 1 addition & 1 deletion metadata.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "npwalker/pe_metric_curl_cron_jobs",
"version": "4.2.1",
"version": "4.2.2",
"author": "npwalker",
"summary": "A Puppet module for gathering metrics from PE components",
"license": "Apache-2.0",
Expand Down
2 changes: 1 addition & 1 deletion templates/tidy_cron.epp
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ METRICS_TYPE='<%= $metrics_type %>';
RETENTION_DAYS=<%= $retention_days %>;

#delete files past retention days
find "$DIR" -type f -mtime $RETENTION_DAYS -delete
find "$DIR" -type f -ctime +$RETENTION_DAYS -delete

#compress files
cd "$DIR"
Expand Down