We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Had problems connecting to Slack API. Did the following changes:
Icinga-bot.ini: Added entry for proxy under [slack] proxy_url = <PROXY SERVER>:<PORT>
proxy_url = <PROXY SERVER>:<PORT>
i2_slack_modules/common.py: Added parser under 'read common section' config_dict["slack.proxy_url"] = config_handler.get(this_section, "proxy_url", fallback="")
config_dict["slack.proxy_url"] = config_handler.get(this_section, "proxy_url", fallback="")
Icinga-bot.py: Added proxy to connection methods: client = slack.WebClient(token=config["slack.bot_token"], ssl=slack_ssl_context, proxy=config["slack.proxy_url"], run_async=True) and rtm_client = slack.RTMClient( token=config["slack.bot_token"], ssl=slack_ssl_context, run_async=True, loop=loop, proxy="http://" + config["slack.proxy_url"] )
client = slack.WebClient(token=config["slack.bot_token"], ssl=slack_ssl_context, proxy=config["slack.proxy_url"], run_async=True)
rtm_client = slack.RTMClient( token=config["slack.bot_token"], ssl=slack_ssl_context, run_async=True, loop=loop, proxy="http://" + config["slack.proxy_url"] )
The last will probably fail splendidly if no proxy is defined :) But since the rim_client demanded 'http://' ...
Probably better ways to do this, but it works.
Thanks for making this bot! R.
The text was updated successfully, but these errors were encountered:
Great idea, will try to add it.
Sorry, something went wrong.
No branches or pull requests
Had problems connecting to Slack API.
Did the following changes:
Icinga-bot.ini:
Added entry for proxy under [slack]
proxy_url = <PROXY SERVER>:<PORT>
i2_slack_modules/common.py:
Added parser under 'read common section'
config_dict["slack.proxy_url"] = config_handler.get(this_section, "proxy_url", fallback="")
Icinga-bot.py:
Added proxy to connection methods:
client = slack.WebClient(token=config["slack.bot_token"], ssl=slack_ssl_context, proxy=config["slack.proxy_url"], run_async=True)
and
rtm_client = slack.RTMClient( token=config["slack.bot_token"], ssl=slack_ssl_context, run_async=True, loop=loop, proxy="http://" + config["slack.proxy_url"] )
The last will probably fail splendidly if no proxy is defined :) But since the rim_client demanded 'http://' ...
Probably better ways to do this, but it works.
Thanks for making this bot!
R.
The text was updated successfully, but these errors were encountered: