gopherbot

command module
v0.9.0-pre2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 25, 2017 License: MIT Imports: 10 Imported by: 0

README

Gopherbot

A.K.A. SUDO for the Enterprise

Gopherbot is:

  • A chat bot designed for ChatOps originally inspired by Hubot
  • A simple remote script execution agent accessible via Slack(*)
  • An easy means of delegating complex functionality to a user base without writing yet another web application

(*) with a modular interface for writing other protocol connectors in Go

The goal is for Gopherbot to support enough scripting languages and security features to make chat bots useful for doing real work. Examples of work Gopherbot is already doing:

  • Building, backing up, restoring, stopping and starting instances in the AWS cloud
  • Disabling / reenabling user web directories when requested by security engineers
  • Adding users and updating passwords on servers using Ansible

See Design Philosophy

Features

  • Multi-platform with builds for Linux, Windows and Mac
  • Multi-lingual with support for command plugins in Ruby, Python, PowerShell and Bash:
    • Most plugins can be distributed as a single text file
    • Plugins use blocking APIs vs registering callback functions, for easy scripting with a low learning curve
    • Plugin API includes WaitForReply* methods for simple question & answer flows
    • Flexible configuration can be easily overridden by the 'bot administrator
    • Configuration can limit plugins to certain channels and/or users
    • Sample plugins: Ruby, Python, Bash, PowerShell
  • Configurable elevated privilege support for security-sensitive commands
  • Localhost http/json interface for creating plugin APIs for other languages
  • A thread-safe brain for storing state
  • Configurable logging
  • A supply of plugins and commands for viewing the log, reloading configuration, and more
  • Many sample plugins, including knock-knock jokes!

Development Status

Gopherbot is running in production in my environment. Currently lacking:

  • Comprehensive plugin documentation
  • Connectors for protocols other than Slack
  • Brain implementations other than simple local files (e.g. redis)

Documentation

Documentation

The Go Gopher

There is no documentation for this package.

Directories

Path Synopsis
Package bot provides the interfaces for creating a chatops bot.
Package bot provides the interfaces for creating a chatops bot.
brains
file
Package fileBrain is a simple file-based implementation of the bot.SimpleBrain interface, which gives the robot a place to store it's memories.
Package fileBrain is a simple file-based implementation of the bot.SimpleBrain interface, which gives the robot a place to store it's memories.
connectors
slack
Package slack uses Norberto Lopes' slack library to implement the bot.Connector interface.
Package slack uses Norberto Lopes' slack library to implement the bot.Connector interface.
elevators
duo
goplugins
help
The help plugin spits out a helpful message when a user just types "help" in a channel, and also responds when the user addresses the robot but no plugin matched.
The help plugin spits out a helpful message when a user just types "help" in a channel, and also responds when the user addresses the robot but no plugin matched.
knock
Package knock implements a simple demonstrator plugin for using Gopherbot's WaitForReply function to tell knock-knock jokes.
Package knock implements a simple demonstrator plugin for using Gopherbot's WaitForReply function to tell knock-knock jokes.
lists
Package lists implements a lists demonstrator plugin showing how you can use the robot's brain to remember things - like lists of items.
Package lists implements a lists demonstrator plugin showing how you can use the robot's brain to remember things - like lists of items.
meme
The memes plugin is an example of how you can use the robot for fun things like generating Internet meme images.
The memes plugin is an example of how you can use the robot for fun things like generating Internet meme images.
ping
The ping plugin is a simple plugin showing one way plugins can use supplied configuration data from a plugin's yaml config file.
The ping plugin is a simple plugin showing one way plugins can use supplied configuration data from a plugin's yaml config file.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL