Logstash doesn't recognize zeep-python

Hi , I have a python Script and I receive a SOAP web service data. in my logstash I call the python script with an exec input and then I send the data to Elasticsearch.

When I run logstash manually the data is send it to Elasticsearch without any problem.
But when I run logstash as a service I got an error from logstash with zeep.

the config file :

input {
exec {
command => "/usr/bin/python2.7 /home/operador/ELK/wsstates.py"
interval => 60
codec => "json"
tags => state
output {
if "state" in [tags]
elasticsearch {
ssl => true
ssl_certificate_verification => false
hosts => ["https://xx.xx.xx.xx:9200"]
index => "state"
user => "user"
password => "password"
stdout { codec => rubydebug } }

This is the error that I got.

jul 09 16:37:00 logstash logstash[23142]: File "/home/operador/ELK/wsestadocruces.py", line 3, in
jul 09 16:37:00 logstash logstash[23142]: from zeep import Client
jul 09 16:37:00 logstash logstash[23142]: ImportError: No module named zeep

This is my python script

if name=="main":

from zeep import Client
import time
wsdl = 'http://xxx.xx.xx.xx/webservice/service.asmx?wsdl'
client = Client(wsdl=wsdl)

I don't know wich could be the problem.

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.