curl https://gist.githubusercontent.com/matsubo/764666d00d25f2a53b505292c9a7c501/raw/ec20fbb26a966c0b101aa44b82c96e1ebbdb06b7/ups.py > ups.py
chmod 755 ups.py
sudo mv ups.py /usr/local/bin/
Add folloing setting on /etc/mackerel-agent/mackerel-agent.conf
[plugin.metrics.ups]
command = ["python3", "/usr/local/bin/ups.py"]
Then restart mackerel agent daemon.
sudo systemctl restart mackerel-agent.service