- Mark as New
- Bookmark Message
- Subscribe to Message
- Mute Message
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content

Hi,
I have created a splunk Addon with input configuration defined by Shell script.
here i refer to a shell script /home/user/Documents/bashscript/sample.sh $username$ $password$ $port$ $index$ $mgmtport$
this bash file receives textbox contents from addon UI and calls a python file which is kept at the system location
/home/user/Documents/projectfolder/receiveandupload.py
This python file receives the inputs from the bash file and starts a server connection to a port 5000 and waits to receive data from switch in raw format send via grpc using protocol buffers. this python file converts the raw format to json and sends to splunk at the index and mgmtport received from the bash file.
I can run it in edit stage with the "TEST" button as well as when I select it from left menu and then creating a input form with the text fields created during the creation of the Addon for username , password,port,index,mgmtport. When i use the enabled form Action drop down it calls the sample.sh script and it gets the input from UI and passes to python script and it also works fine by receiving the data from switch and uploads to splunk.
But when i am trying to package the add on its showing error and not creating the addon.
Is it because the python file and the bash file sample.sh is kept in Documents folder ?
Where do I keep the sample.sh file and the projectfolder containing the (protobuf files,python files, and related files) so that i can package the AddOn for distribution ?
Splunk is also installed in this same machine at location /home/user/Documents/Splunk/splunk
- Mark as New
- Bookmark Message
- Subscribe to Message
- Mute Message
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content


All files related to an app (add-on) must be in the app's directory ($SPLUNK_HOME/etc/apps/ with .sh and .py files in the bin
subdirectory.
If this reply helps you, Karma would be appreciated.
- Mark as New
- Bookmark Message
- Subscribe to Message
- Mute Message
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content


All files related to an app (add-on) must be in the app's directory ($SPLUNK_HOME/etc/apps/ with .sh and .py files in the bin
subdirectory.
If this reply helps you, Karma would be appreciated.
- Mark as New
- Bookmark Message
- Subscribe to Message
- Mute Message
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content

Hi,
Thanks it works.
But while i try to do Validata&Package it shows error "splunk there was a problem connecting to app certification service. the service might not be available at this time or you might need to verify your proxy settings".
Is there anything else I missed?
- Mark as New
- Bookmark Message
- Subscribe to Message
- Mute Message
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content


Splunk no longer certifies apps. Just package your app, don't validate it.
If this reply helps you, Karma would be appreciated.
