- for f in /etc/prometheus-{,export-}htpasswd; do
- if [[ -e $f ]]; then
- s chmod 640 $f
- if getent passwd www-data &>/dev/null; then
- s chown root:www-data $f
- fi
- fi
- done
- f=/etc/prometheus-pass
- if [[ -e $f ]]; then
- # note: this is duplicative of the file's own permissions
- s chmod 640 $f /etc/prometheus-pass