Skip to content

DazWorrall/mcollective-python

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

19 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

mcollective-python

This is an example Python binding for Marionette Collective RPC.

API Documentation

The main class is Message, and you create an instance of this to initiate some RPC. It takes a dictionary which contains the actual request (following the MCollective RPC documentation) and a stomp.Client instance for future use.

You can then .sign() a request, with your private key, .subscribe_to_replies(), manually .send() and then .collect_results() - or just do a .send_and_await_results() after signing to receive an array of STOMP messages back.

Requirements

  • M2Crypto - seems to be the most comprehensive OpenSSL binding, though I needed to read the source.

  • stompy - make Python speak STOMP.

And it also requires you to have particular MCollective setup:

securityprovider = ssl
plugin.ssl_serializer = yaml

The Quick Start

# Run the test client
$ python test.py localhost username password aaron-private.pem aaron-public uptime

License

Copyright (c) 2011, Aaron Brady, Interactive Web Solutions Ltd.

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

About

Python library for using Marionette Collective's RPC

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages