Describe in one or two lines what your page is about.
Setting up matrix-appservice-irc on debian
matrix-appservice-irc have not been packaged for debian use, so here goes a guide explaining how to set it up on current Debian GNU/Linux.
matrix-appservice-irc is written in Node.js and uses npm for installation. npm's integration into Debian is not really good, so we will need to make some extra action to make it fit.
$ sudo apt-get install git npm postgresql
Then we will need to create a user that would run bridge service
$ sudo adduser --system matrix-bridge-irc
Please notice that we do not set --no-create-home option here, as npm will need this user home dir for installation process.
Then you will need to precreate path that where matrix-appservice-irc will be installed, and change it's owner to matrix-bridge-irc user
$ sudo mkdir -p /usr/local/lib/node_modules/matrix-appservice-irc/bin/matrix-appservice-irc $ sudo ln -s /usr/local/lib/node_modules/matrix-appservice-irc/bin/matrix-appservice-irc /usr/local/bin/matrix-appservice-irc $ chown -R matrix-bridge-irc: /usr/local/lib/node_modules/
Then switch to matrix-bridge-irc user and run installation process
$ sudo su matrix-bridge-irc $ npm install matrix-appservice-irc --global $ cd /usr/local/lib/node_modules/matrix-appservice-irc $ npm install $ npm test # make sure these pass!
If you have good karma, you might get it installed well.
Then you will need to create an empty database that will be used by matrix-appservice-irc
$ sudo su postgres $ createuser --pwprompt irc_bridge_db_user $ psql
and in the psql console type
CREATE DATABASE irc_bridge_db ENCODING 'UTF8' LC_COLLATE='C' LC_CTYPE='C' template=template0 OWNER irc_bridge_db_user;
This will create a database for you.
For bridge configuring please follow upstream instruction at https://github.com/matrix-org/matrix-appservice-irc/blob/master/HOWTO.md Do not forget to change database connection options in the end of config file
Running as a systemd service
When you make sure you can run this daemon manually, it is good time to make it run automatically. To do it we will need to create a systemd service file:
$ sudo editor /etc/systemd/system/matrix-appservice-irc.service
And add following content to the file
[Unit] Description=Matrix AppService IRC [Service] WorkingDirectory=/usr/local/lib/node_modules/matrix-appservice-irc ExecStart=node app.js -c config.yaml -f my_registration_file.yaml -p 9999 User=matrix-bridge-irc [Install] WantedBy=multi-user.target
Start a service, you've just created
$ sudo systemctl start matrix-appservice-irc
Make sure it is up and running
$ sudo systemctl status matrix-appservice-irc
And then enable service autostart
sudo systemctl enable matrix-appservice-irc
Reboot, if you can, make sure it still works. And have a nice IRC<->Matrix chat!