aboutsummaryrefslogtreecommitdiff
path: root/text_collector_examples
diff options
context:
space:
mode:
authorBen Kochie <superq@gmail.com>2018-02-27 19:46:01 +0100
committerGitHub <noreply@github.com>2018-02-27 19:46:01 +0100
commit483f59d1102cd83a1547d59d997cf6571801e196 (patch)
tree1727ec3ec2d52bf7acaff62eee1d4f642f452731 /text_collector_examples
parent864a6ee93578f22843d276d008d83a2c82af5f1d (diff)
downloadprometheus_node_collector-483f59d1102cd83a1547d59d997cf6571801e196.tar.bz2
prometheus_node_collector-483f59d1102cd83a1547d59d997cf6571801e196.tar.xz
prometheus_node_collector-483f59d1102cd83a1547d59d997cf6571801e196.zip
Document use of atomic wrapper (#781)
Document how to use `sponge` to atomic update textfiles.
Diffstat (limited to 'text_collector_examples')
-rw-r--r--text_collector_examples/README.md8
1 files changed, 8 insertions, 0 deletions
diff --git a/text_collector_examples/README.md b/text_collector_examples/README.md
index 540c3dd..f47b37d 100644
--- a/text_collector_examples/README.md
+++ b/text_collector_examples/README.md
@@ -3,5 +3,13 @@
3These scripts are examples to be used with the Node Exporter Textfile 3These scripts are examples to be used with the Node Exporter Textfile
4Collector. 4Collector.
5 5
6To use these scripts, we recommend using a `sponge` to atomically write the output.
7
8 <collector_script> | sponge <output_file>
9
10Sponge comes from [moreutils](https://joeyh.name/code/moreutils/)
11* [brew install moreutils](http://brewformulas.org/Moreutil)
12* [apt install moreutils](https://packages.debian.org/search?keywords=moreutils)
13
6For more information see: 14For more information see:
7https://github.com/prometheus/node_exporter#textfile-collector 15https://github.com/prometheus/node_exporter#textfile-collector