-
Notifications
You must be signed in to change notification settings - Fork 131
To use IMs with mh, you first need to create a user for mh. For the rest of this page, we'll assume that you are using aim, but the basic instructions are valid for other IMs as well.
Set the following variables in your mh.ini or mh.private.ini file:
code format="perl" net_aim_name_send=johnsmith net_aim_name=MyMisterHouseAIMUser net_aim_password=xxxxxxxxx net_aim_buddies=johnsmith, janesmith, thejones net_aim_autoconnect=1 password_allow_im=johnsmith, jamesmith net_aim_buddy_icon=$config_parms{html_dir}/graphics/mh_buddy.jpg code
- **net_aim_name_send** is the default IM user who will receive messages from mh
- **net_aim_name** is the name of your mh IM user
- **net_aim_password** is the password you assigned to the user
- **net_aim_buddies** are the names of the users that you wish to be able to see and send commands to mh (they will need to login if they aren't listed in password_allow_im)
- **net_aim_autoconnect** tells mh to connect on startup
- **password_allow_im** are the users that don't need to login in order to send commands to mh
- **net_aim_buddy_icon** points to a 48x48 JPEG or GIF file to use as your mh buddy icon. This currently only works for AIM and ICQ.
- Add a "hook" that automatically calls aol_disconnected when we lose the connection to AOL
&AOLim_Disconnected_add_hook(\&aol_disconnected);
}
- subroutine that's automatically called when we lose the connection to AOL
print "AOL got disconnected, let's try reconnecting, shall we?\n"; &net_im_signon(undef,undef,'aol');
} code
First of all, if you start setting up a Jabber client from Misterhouse, first try it with your own server (so that you have access to the server logs) or use a known-working service (like Google Talk). I spent quite some time debugging mysterious SASL/Jabber module errors, and in the end it became clear that the server I tried to connect to was causing the problem.
Setting up a standard Google Talk account is easy, fill in the following parameters:
**net_jabber_name_send=**<your_account>@gmail.com</span></your_account> (MH will sent messages to this user)
- net_jabber_name=**misterhouse (Account name that will represent your MH install)
- net_jabber_password=**my_password (Password for the MH account)
- net_jabber_server=**talk.google.com
- net_jabber_resource=**Home (This is optional, but set it anyway)
- net_jabber_tls=**1
- net_jabber_component_name=**gmail.com
- net_jabber_autoconnect=**1 (Optional, will ensure auto-connect and reconnect after a MH restart)
Now, before you are able to send real commands you will need to authenticate using the 'login' command. If you would like to disable that (after all, you are already authenticated to your Google Talk client) you can add the following parameter to the mh.private.ini file:
- password_allow_im**=<your_account></your_account>@gmail.com/resource
- password_allow_im**=<your_account></your_account>@gmail.com/Home,<your_account></your_account>@gmail.com/Work
I took a little while to figure out the right parameters for this arrangement. Firstly, as mentioned above you will want to create another user on the domain that you host with Google through the web interface. Set a password for it. You will then need to login to that account and get through the initial setup. Then configure the MH ini file to use that new account. Here is an example of the parameters...
**net_jabber_name_send=**tom.christian@my_domain.com (Just the default name for MH to send IM to)
- net_jabber_name=**misterhouse (Use the logon name without the domain)
- net_jabber_password=**my_password (password for the logon name above)
- net_jabber_server=**talk.google.com
- net_jabber_resource=**Home (This is optional)
- net_jabber_tls=**1
- net_jabber_component_name=**my_domain.com (This is key -- It should be your domain, not the generic google domain)
- net_jabber_autoconnect=**1 (optional)