Fixes an issue with the jinja2 snippet which is used to create the node_exporter Systemd unit. More details here: https://github.com/prometheus-community/ansible/issues/13
Jinja2 namespaces are used to ensure the variable `protect_home` can be set in the parent scope of the `for` loop looking through the mounts.
Signed-off-by: Kevin Bowrin <kevinbowrin@cunet.carleton.ca>
If ansible-vaulted password is passed to password_hash filter, it will throw and error:
'secret must be unicode or bytes, not ansible.parsing.yaml.objects.AnsibleVaultEncryptedUnicode'
Handling the vaulted password with string filter first will avoid the problem.
Signed-off-by: Ilari Iso-Junno <iisojunn@users.noreply.github.com>
Correct the quotation around the collector option flags and values
in the node_exporter role systemd unit config file template so that
regex values get parsed correctly.
Refs: #68
Signed-off-by: Andrew Kingston <andrew.kingston@framestore.com>
Remove the quotation around the collector option flags and values
in the node_exporter role systemd unit config file template so that
regex values get parsed correctly.
Refs: #68
Signed-off-by: Andrew Kingston <andrew.kingston@framestore.com>
Correct the quotation around the collector option flags and values
in the node_exporter role systemd unit config file template so that
regex values get parsed correctly.
Refs: #68
Signed-off-by: Andrew Kingston <andrew.kingston@framestore.com>
Set systemd's ProtectHome to 'read-only' instead of
'yes' if there exists filesystems which are mounted
at or under '/home', instead of at '/home' exclusively.
Fixes#13.
Signed-off-by: Kevin Bowrin <kevinbowrin@cunet.carleton.ca>