Merge ~hloeung/influxdb-charm:master into influxdb-charm:master

Proposed by Haw Loeung
Status: Merged
Approved by: Haw Loeung
Approved revision: a9d3468cbd20e573b506ed04020845e8b7fa52f6
Merged at revision: be17bc8cc8963cee1cbfcca7ac2224193031ffe1
Proposed branch: ~hloeung/influxdb-charm:master
Merge into: influxdb-charm:master
Diff against target: 31 lines (+4/-4)
1 file modified
templates/influxdb-backup (+4/-4)
Reviewer Review Type Date Requested Status
Barry Price Approve
Canonical IS Reviewers Pending
Review via email: mp+430063@code.launchpad.net

Commit message

Don't output anything in the influxdb-backup job to reduce cron spam

To post a comment you must log in.
Revision history for this message
🤖 Canonical IS Merge Bot (canonical-is-mergebot) wrote :

This merge proposal is being monitored by mergebot. Change the status to Approved to merge.

Revision history for this message
Barry Price (barryprice) wrote :

+1

review: Approve
Revision history for this message
🤖 Canonical IS Merge Bot (canonical-is-mergebot) wrote :

Change successfully merged at revision be17bc8cc8963cee1cbfcca7ac2224193031ffe1

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1diff --git a/templates/influxdb-backup b/templates/influxdb-backup
2index b253fbc..ab02772 100644
3--- a/templates/influxdb-backup
4+++ b/templates/influxdb-backup
5@@ -33,11 +33,11 @@ esac
6 DATABASES=$(influx ${auth_args} --execute 'show databases' --format=json | jq --raw-output '.results[0].series[0].values[][0]' | grep -ve '^_internal$')
7
8 # back up metadata
9-influxd backup $TODAY_DIR/metdata
10+influxd backup $TODAY_DIR/metdata >/dev/null
11
12 # back up individual databases
13 for d in ${DATABASES}; do
14- influxd backup -database $d $TODAY_DIR/$d
15+ influxd backup -database $d $TODAY_DIR/$d >/dev/null
16 done
17
18 # compress the on-disk backup - gzip will do as the files can be huge, more efficient compressors are too slow/intensive
19@@ -49,10 +49,10 @@ cd $BACKUP_DIR
20
21 # remove any old backup dirs from pre-compression revisions of this script
22 for dir in $(find . -maxdepth 1 -type d | grep -v ^.$ | sort -r | tail -n +$NUM); do
23- rm -rf ./$dir && echo "Removed $dir"
24+ rm -rf ./$dir
25 done
26
27 # remove old compressed backup files
28 for file in $(find . -maxdepth 1 -type f | sort -r | tail -n +$NUM); do
29- rm -rf ./$file && echo "Removed $file"
30+ rm -rf ./$file
31 done

Subscribers

People subscribed via source and target branches

to all changes: