Skip to content

Instantly share code, notes, and snippets.

@yn-misaki
Last active October 17, 2016 08:03
Show Gist options
  • Save yn-misaki/63157b8000280e1f27f33c7700ce6ce7 to your computer and use it in GitHub Desktop.
Save yn-misaki/63157b8000280e1f27f33c7700ce6ce7 to your computer and use it in GitHub Desktop.
Mackerel(マカレル)を使って自分のMacを監視して、アラートが発生したらslackに通知させてみる ref: http://qiita.com/yn-misaki/items/8730797531b57fbad5fc
$ brew tap mackerelio/mackerel-agent
$ brew install mackerel-agent
# LaunchAgentsにシンボリックリンクを張る
$ ln -sfv /usr/local/opt/mackerel-agent/*.plist ~/Library/LaunchAgents
# 設定ファイルを読み込む
$ launchctl load ~/Library/LaunchAgents/homebrew.mxcl.mackerel-agent.plist
# jobを開始
$ launchctl start homebrew.mxcl.mackerel-agent
$ echo 'apikey="<API-KEY>"' >> /usr/local/etc/mackerel-agent.conf
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment