Open daisy1754 opened 10 years ago
Thank you for your issuing, I looked into the log file.
It seems that your program was searching for the XMPP host server but failed. ruboty-slack resolves the host from "#{ENV['SLACK_TEAM']}.xmpp.slack.com"
. Are you using correct SLACK_TEAM env variable? For instance we are using SLACK_TEAM=tqhouse for our https://tqhouse.slack.com organization.
I'm afraid I suspect something wrong with Xrc library (which seems made by you). From irb, I try following code (changed password and roomname), with no luck
require "xrc"
client = Xrc::Client.new(
jid: "kazuki@ourteam.xmpp.slack.com",
password: "My password",
nickname: "kazuki",
room_jid: "general@conference.ourteam.xmpp.slack.com"
)
client.connect
I also try xmpp4r library, and with following code, I could post message
require 'xmpp4r'
require 'xmpp4r/client'
require 'xmpp4r/muc'
include Jabber
jid = JID.new("kazuki@ourteam.xmpp.slack.com")
client.connect
client.auth "My password"
client.send(Presence.new.set_type(:available))
muc = Jabber::MUC::MUCClient.new(client)
muc.join(Jabber::JID::new("general@conference.ourteam.xmpp.slack.com/" + client.jid.node))
message = Message.new(muc.jid, "Test")
muc.send(message)
By the way, I tried to use my own account (with which I already logged in from bunch of browsers) as bot account. This may be cause a problem? I'll try creating new account when I have time.
By the way, I tried to use my own account (with which I already logged in from bunch of browsers) as bot account. This may be cause a problem? I'll try creating new account when I have time.
No, there is no problem to share your account with both normal use and BOT use. I often do that too for debugging :mag_right: :bug:
I'm trying to set ruboty up for our server, but without success.
Here is what I did:
You can find related files here https://gist.github.com/daisy1754/17d0989d4d3556875ab4 (There are error log related to redis, since I initially included ruboty-redis in Gemfile. Now I remove that from gem, still cannot get ruboty to run)
Thanks,