MateBot Web is a web frontend for MateBot. It is served as single-side application to allow embedding as Matrix Custom Integration.
In order to install MateBot Web, the following packages are required (based on Debian 11):
- git
- build-essential
Go 1.18:
As Debian 11 provides an old version of golang, use the installation instructions from the official site
NodeJS 16 LTS:
curl -fsSL https://deb.nodesource.com/setup_lts.x | bash -
apt-get install -y nodejs
Compile and install the project itself:
git clone https://github.com/hopfenspace/matebot-web.git
cd matebot-web
make
make install
cp /etc/matebot-web/example.config.toml /etc/matebot-web/config.toml
It is recommended to deploy matebot-web behind a reverse proxy. Nginx is used as reference.
Install nginx:
apt-get install nginx
Copy nginx configuration file:
cp matebot-web.nginx /etc/nginx/sites-available/matebot-web.conf
ln -s /etc/nginx/sites-available/matebot-web.conf /etc/nginx/sites-enabled/
Set SERVER_NAME
to the vhost, your server can be accessed by:
sed -i -E 's/SERVER_NAME/your-server-name/' /etc/nginx/sites-available/matebot-web.conf
Set SSL_CERT_PATH
and SSL_CERT_KEY_PATH
to a certificate, that is valid for SERVER_NAME
:
sed -i -E 's/SSL_CERT_PATH/\/path\/to\/cert\.pem/' /etc/nginx/sites-available/matebot-web.conf
sed -i -E 's/SSL_CERT_KEY_PATH/\/path\/to\/key\.pem/' /etc/nginx/sites-available/matebot-web.conf
Finally, start nginx:
systemctl start nginx