-
Notifications
You must be signed in to change notification settings - Fork 155
New issue
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
How to setup multiple channels within one team #12
Comments
I think it was possible to use one outgoing integration for all channels without a trigger word previously (I might be wrong). It's not possible now at least, like you're saying, so I've rewritten the tool to use Slack's bot users instead. The functionality is mostly up and working, just need to update the tests too: https://github.com/ekmartin/slack-irc/compare/slackbot - will probably be done tomorrow. This means you won't have to have any outgoing/incoming integrations, only one bot user and one token. It also uses Slack's RTM API to receive messages over websockets, which means the server won't have to listen for post requests like it used to. |
Thats great to hear! Thank you! |
While you're at it, would it be possible to configure the token either via the config file or via an environment-variable? |
I've just given it a try and I can confirm that it works! But: There seems to be an issue in binding to a port. On my local machine in terminal I just see When I deploy the app to heroku, I get a timeout error after 60 seconds as heroku can't find that it binds to the port after those 60 seconds and therefore assumes that the startup of the app failed. I looked into the code (I have no node-experience up to now) and the only thing I found was that in the master-branch there is a call to |
Everything used to be configurable with environment variables, as I used to deploy it to Heroku (see 83d8a20#diff-04c6e90faac2675aa89e2176d2eec7d8). However, Heroku restarts dynos at least every 24 hours, which is kind of bad for an IRC bot (join/quit-spam). It also requires you to ping the bot every 5th minute or so to keep it alive. The problem you're seeing with the slackbot branch is that it's not actually listening on any port at all. It receives all messages over websockets, so it doesn't need to listen for POST requests from Slack anymore. I haven't used Heroku that much, but I think it would be more suitable to deploy it to a worker dyno, as it doesn't need to receive HTTP traffic through a router (only through an already made websocket connection). In regards to configuring through environment variables, the main problem is the channel mapping. As you can have one slack-irc bot connected to multiple Slacks you need to provide one token per Slack, like in the example config here. This could be solved by just having one environment variable that takes the whole config as JSON, but that's kind of hacky. Another solution would be to only allow environment variable configuration if you connect to one Slack, and give the channel mapping directly as JSON, like here. Neither of the solutions are quite good, and taking into consideration the things I mentioned earlier about Heroku restarting dynos every 24 hours and the pinging I'm not sure if it's worth it to deploy to Heroku. |
Thanks for the clarification! And I didn't think of the multiple site issue there! I will check what other ways I can find for the deployment as your reasons against heroku are definitely worth considering! Thanks! 👍 |
This should be fixed with #14. |
First of all: Great tool!
I have an issue with setting up multiple channels ithin one team.
I can talk from IRC to slack on multiple channels without issue, but so far I only managed to talk on one channel from slack to IRC.
I've created an outgoing webhook for every channel I want to export. But every webhook has it's own token. And as far as I see it only one token can be added to the team-configuration. The channel I configured the token for is the one I can talk from slack to IRC. When I change the token, the channel changes.
How can I talk from slack to IRC on multiple channels?
The text was updated successfully, but these errors were encountered: