lita-salt is the old adapter for Lita that allows your bot to interact with your saltstack installation via salt-api.
Add lita-salt to your Lita instance's Gemfile:
gem "lita-salt"
url
(String) – The location of the running salt-api service.username
(String) – The username used to authenticate with salt-api.password
(String) – The password used to authenticate with salt-api.
returner
(String) – A Saltstack returner you'd like to use. (uses default if unset)
Lita.configure do |config|
config.handlers.salt.url = "https://api.example.com"
config.handlers.salt.username = ENV["SALT_USERNAME"]
config.handlers.salt.password = ENV["SALT_PASSWORD"]
end
Commands are called in the with the salt
prefix what can be optionally with the s
abbreviation.
salt minion service.restart nginx
s minion schedule.run_job apt
salt up
executes the manage.up
runner and returns a list of up minions.