- Get Stackato
- Why a Private PaaS?
- Features & Benefits
- Stackato by Language
- Compare Editions
- Stackato & Cloud Foundry
- Developer Tools
- Stackato Training
- Professional Services
- Commercial Support
- Code Recipes
Tara Gibbs, May 23, 2013
Last month, we had a hackathon here at ActiveState. I spent some time creating a collection of modules for Chris Jones' madcow IRC bot that would be useful to our dev and support team members.
You see, we've got this IRC channel on freenode: #stackato
A lot of our customers and folks just kicking Stackato's tires, pop into this channel to ask questions. I'd hear my co-workers ask each other who specific nicks belonged to. This sparked the idea for these modules that improve the customer support experience in the channel.
This module alllows users to be marked as staff members. Only other staff members can mark new staff members.
It also allows anyone, staff member or not, to query the bot for a list of staff nicks.
Company & Real Name Modules
These modules allow staff members to set a company name and a real name for nicks.
Only staff can query this information. These modules were created to help developers and support teams know who they're talking to in the channel.
This module allows staff to add notes to a nick that can be viewed by all staff members.
You can add multiple notes to a nick. Notes are appended with a time stamp and the nick of the user who created it.
This module provides a summary of staff-visible information for a nick.
This module grabs the latest blog post from an RSS feed and posts the title, link, and date to the channel. The feed URL is configurable in madcow's settings.
This module allows staff members to create aliases for commonly posted links.
Non-staff members can see a list of available links and invoke the aliases.
This module sends users a private welcome message when invoked. You can call it on yourself or on other users. The welcome message is configurable in madcow's settings.
All of these modules have been contributed back to the madcow project on Github.
Best of all, madcow runs ever-so-nicely on Stackato!
- Clone the madcow Github repo
- Add a stackato.yml file containing the following configuration:
name: madcow mem: 128M framework: type: standalone runtime: python27 services: data: filesystem command: build/scripts-2.7/madcow -b data ignores: ["~*/", ".git/", "data/db", "data/log"] hooks: post-staging: # create db directory - mkdir -p "$STACKATO_FILESYSTEM"/db # link to data/db folder in the shared filesystem - ln -s "$STACKATO_FILESYSTEM"/db data/db # create db directory - mkdir -p "$STACKATO_FILESYSTEM"/log # link to data/db folder in the shared filesystem - ln -s "$STACKATO_FILESYSTEM"/log data/log - python setup.py build
- Run ./run-standalone-madcow
- Update data/settings.py with your desired configuration. You'll probably want to change the following settings:
PROTOCOL = 'irc' BOTNAME = 'somethingotherthanmadcow' OWNER_NICK = 'username' IRC_HOST = 'authorname.freenode.net' IRC_CHANNELS = ['#yourchannel'] BLOG_RSS_URL = 'http://yoursite.com/rss' WELCOME_MSG = 'a welcome message'
- Once you're done with configuring the bot, run 'stackato push -n' to deploy madcow to Stackato
Pretty Easy, Right?
You can try out Stackato on our Sandbox, boot up a Stackato instance on EC2 or HPCS, or download a Stackato VM to run on your own hardware. Get Stackato!