The Python code in this App is dual 2.7/3 compatible. This version of the App enforces Python 3 for execution of the modular input script when running on Splunk 8+ in order to satisfy Splunkbase AppInspect requirements. If running this App on Splunk versions prior to 8 , then Python 2.7 will get executed.
This is a Splunk modular input add-on for subscribing to Pubnub channels
Settings -> Data Inputs -> Pubnubto add a new Input stanza via the UI
inputs.conffile should be placed in a
localdirectory under an App or User context.
You require an activation key to use this App. Visit http://www.baboonbones.com/#activation to obtain a non-expiring key
You have to obtain, build and add the pycrypto package yourself :
The simplest way is to build pycrypto and drop the "Crypto" directory in $SPLUNKHOME/etc/apps/pubnubta/bin. I don't recommend installing the pycrypto package to the Splunk Python runtime's site-packages, this could have unforeseen side effects.
I do not bundle the pycrypto module with the core release , because :
So , here are a few instructions for building and installing pycrypto yourself :
Download the pycrypto package from https://pypi.python.org/pypi/pycrypto
Then run these 3 commands (note : you will need to use a System python 2.7 runtime , not the Splunk python runtime)
python setup.py build python setup.py install python setup.py test
browse to where the Crypto module was installed to ie: /usr/local/lib/python2.7/dist-packages/Crypto
Copy the "Crypto" directory to $SPLUNKHOME/etc/apps/pubnubta/bin
You will need a Pubnub account to use this Modular Alert.
You can sign up at pubnub.com
Once your account is setup you will then be able to obtain your Subscribe Key from your profile.
If you require an encrypted credential in your configuration , then you can enter it on the setup page.
Then in your configration stanza refer to it in the format
somekey is any value you choose to enter on the setup page to refer to your credential.
You can provide your own custom Response Handler. This is a Python class that you should add to the rest_ta/bin/responsehandlers.py module.
You can then declare this class name and any parameters in the REST Input setup page.
Modular Input logs will get written to
Setup logs will get written to
These logs are rotated daily with a backup limit of 5.
The Modular Input logging level can be specified in the input stanza you setup. The default level is
You can search for these log sources in the
_internal index or browse to the
Logs menu item on the App's navigation bar.
BaboonBones.com offer commercial support for implementing and any questions pertaining to this App.