Closed leandromoreirati closed 5 years ago
Leandro, qual a versão do seu Zabbix?
Boa noite Raul, como vai
Estou usando a versao 4.0.7.
Att.
Leandro, vou subir um lab pra simular com essa versão, e darei um retorno. Como estou em um ambiente legado, uso a versão 2.4.5, mas atualizarei para mais recentes. Creio que o erro pode estar na ordem dos argumentos do script python.
Raul,
Muito obrigado pela atenção, fico no aguardo.
Att.
Em seg, 20 de mai de 2019 15:41, Raul Libório notifications@github.com escreveu:
Leandro, vou subir um lab pra simular com essa versão, e darei um retorno
— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/rauhmaru/rocketchat-zabbix/issues/1?email_source=notifications&email_token=AHK3WLLNZVHGISOYALNPZKLPWLWFNA5CNFSM4HNP4X22YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGODVZW6SQ#issuecomment-494104394, or mute the thread https://github.com/notifications/unsubscribe-auth/AHK3WLM6EOTQ47BY6A7SVETPWLWFNANCNFSM4HNP4X2Q .
I can confirm. Unfortunately, I am getting the same issue without media script parameters in Zabbix 4.0.7.
Traceback (most recent call last):
File "/usr/lib/zabbix/alertscripts/rocketchat.py", line 7, in <module>
url = sys.argv[1]
IndexError: list index out of range
If i add the script parameters for Media type manually:
{ALERT.SENDTO}
{ALERT.SUBJECT}
{ALERT.MESSAGE}
Action has the status "Sent", but I am not getting anything in RocketChat.
Hi, AlKosmos!
I make same test, inclur the variables:
{ALERT.SENDTO} {ALERT.SUBJECT} {ALERT.MESSAGE}
In the media configuration, it return "Send Menssage", but not sending.
At.
good day, same issue on 4.2.3, any fixes?
Hi, sorry for delay.
#!/usr/bin/python
import sys
import requests
import json
url = sys.argv[1]
subject = sys.argv[2]
body = sys.argv[3]
r = requests.post(url, body)
And will works.
I apologize to everyone for their inattention.
thank you, alerts working now, but now i'm not getting images from alerts
No permissions to referred object or it does not exist
As images are brought from zabbix via the link, then, in order to have access, you must be logged in.
Another point is that the rocketchat should be able to reach zabbix so that the images can be viewed.
Can you please describe in more detail how I should make an entry in zabbix, by editing the source python script?
@petqa, I do not understand what you want. You refer a the alertscript in the zabbix? Only the last line in the script was missing, sending the information to the chat.
Dear good afternoon I followed his documentation to integrate zabbix with the rocket chat, but at the time he performs the action he is returning the error below:
Can you please give me a hint how to solve.
Att.