summaryrefslogtreecommitdiff
path: root/files/munin/ejabberd_registrations.cron
blob: fc9de3e1e8a0a00d986e2137fb340f837a9f5684 (plain)
1
2
3
4
5
6
7
8
#!/bin/bash

for host in `cat /etc/munin/plugin-conf.d/ejabberd_registrations.conf  | grep env.vhosts | sed 's/env.vhosts //'`; do
  stat_file="/var/lib/munin/plugin-state/ejabberd_registrations_${host}"
  ejabberdctl registered-users $host > $stat_file
  chgrp munin $stat_file
  chmod o-rwx $stat_file
done