/awaybot

slackbot that announces when people are away

Primary LanguageRuby

Running it on Heroku

  1. Login to heroku (FreshBooks employees ask IT for heroku access via OKTA)
  2. Follow this link Deploy
  3. Add a slack incoming webhook
  4. Copy the Webhook URL into the Heroku config SLACK_HOOK_URL
  5. Copy the Bamboo icalendar feed url into the Heroku config FEED_URL
  6. Copy the names of the people on your team exactly as they appear in Bamboo into the Heroku config NAMES field separated by semicolons
  7. Click Deploy for Free
  8. Once it's done deploying click Manage App
  9. Click the Edit button beside Add-ons
  10. Search for add and save Heroku Scheduler
  11. Go to the (Heroku Scheduler)[https://scheduler.heroku.com/dashboard]
  12. Configure the Heroku Scheduler to run ruby bin/awaybot.rb major daily at 13:00 UTC

Optionally Connect the Application to Github

  1. Requires that you have access to the Github repository (FreshBooks employees as in #dev)
  2. From the application Deploy->GitHub page click Connect to GitHub
  3. Grant the heroku app access to freshbooks/awaybot
  4. Click on Enable Automatic Deploys

Running it locally

  export FEED_URL='https://freshbooks.bamboohr.com/feeds/feed.php?id=SNIP'
  export SLACK_HOOK_URL='https://hooks.slack.com/services/T024K32LX/B060UFKPE/SNIP'
  export NAMES='Sen Nordstrom;Jason Shaw;Jonathan Yee'
  ruby bin/awaybot.rb major