Digital Ocean Slack Bot

I had a coach whose favorite quote was “Pain is the best teacher.”  and that was the first thing that popped into my head this morning when I realized that I had left an $80 a month  Digital Ocean Droplet  running for an extra 3 weeks after I got done using it.   To be honest $60 isn’t *that* painful but  it did prod me to write a slackbot that will post all my running droplets to slack once a day:
 

Here is how I set it up:

https://gist.github.com/jgamblin/83f7eb018d7953497e30802ed23e2041

  • Copy this line to your crontab to post a list of running droplets at 0800 everyday:
    00 08 * * * /path/to/dobot.sh
  • Enjoy not wasting money on abandoned cloud servers.

Site Footer