0.0
No commit activity in last 3 years
No release in over 3 years
Stackstorm handler for lita 4+
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
 Dependencies

Development

Runtime

>= 4.4
 Project Readme

lita-stackstorm Gem Version

lita-stackstorm is an handler for Lita that allows your bot to interact with your stackstorm installation via st2api.

Installation

Add lita-stackstorm to your Lita instance's Gemfile:

gem "lita-stackstorm"

Configuration

Required

  • url (String) – The location of the running st2api service.
  • username (String) – The username used to authenticate with st2api.
  • password (String) – The password used to authenticate with st2api.

Optional

  • auth_port (Integer) – Port used for Authentication. Defaults to 9101.
  • execution_port (Integer) – Port for executions. Defaults to 9100.
  • emoji_icon (String) – Emoji used when bot injests event stream. Defaults to :panda:.

Example

Lita.configure do |config|
    config.handlers.stackstorm.url = "https://st2.example.com"
    config.handlers.stackstorm.username = ENV["ST2_USERNAME"]
    config.handlers.stackstorm.password = ENV["ST2_PASSWORD"]
end

Usage

st2 list - lists all chatops aliases from registered packs.

Executing Actions

Action Aliases require the ! prefix. For example, in order to run the packs.info action when investigating the linux pack, you'll run:

!pack info linux

This handler also provide support for partial commands. For example, suppose you type:

!pack deploy

The handler will return the closest likely matches:

possible matches:
    pack deploy {{pack}}
    pack deploy {{pack}} from {{repo}}