Installation
Server platform
The following instructions refer to an Ubuntu 22.04 server and should be adapted with other package manager commands if a different distribution is chosen.
Notes on tools and versions
Python
CAT is written in Python. At the moment of this deployment Indico officially supports Python versions 3.9 - 3.11, so CAT is based on Python 3.11.
Redis
Redis is used as a communication database for all MEOW tasks. It can be installed in various ways. For simplicity, the official Ubuntu Redis packages are used in MEOW.
Supervisord
supervisord is used to manage the MEOW "service". It takes care of starting the MEOW processes and restart them if needed.
PDF tools
qpdf, pdftk and mupdf are used by MEOW to manipulate the PDFs for final proceedings.
Installing System Packages
apt install dbus-broker systemd-container
apt install htop vim p7zip unzip zip git tig
apt install build-essential python3.11-venv python3.11-minimal
apt install qpdf pdftk mupdf-tools mupdf
apt install redis-server redis-tools
Enabling and starting the Redis Service
systemctl enable redis
systemctl start redis
Setup MEOW code
First, let's create the CAT user and access its working directory
useradd --comment 'CAT system user' --create-home --system --home-dir /opt/cat --shell /usr/bin/bash cat
su - cat
Downloading sources
git clone https://github.com/JACoW-org/MEOW.git
Setting Python Virtual Environment
python3 -m venv venv
. ./venv/bin/activate
./venv/bin/pip install --upgrade pip
./venv/bin/pip install -r requirements.txt
Creating PURR/MEOW Shared Authentication Key
To create a shared authentication key for requests from the PURR client to the MEOW server, you will need an API key. The following command creates an API key for the user purr
on the indico installation at indico.jacow.org
and stores it in Redis. You can create different keys for different PURR installations, Indico events or even for other software that would use MEOW's APIs.
./venv/bin/python -m meow auth -login purr@indico.jacow.org
The output will look like this:
purr indico.jacow.org <api_key>
Please take note of this <api_key>
: it will be needed in the PURR connection to MEOW settings of the Indico event.
Other meow
useful commands
List keys present in the DB:
./venv/bin/python3 -m meow auth -list
Check a key:
./venv/bin/python3 -m meow auth -check <api_key>
purr indico.jacow.org <timestamp>
Remove a key from the DB:
./venv/bin/python3 -m meow auth -logout <api_key>
1
Starting supervisord
./venv/bin/supervisord -n -c ./conf/supervisord.conf
Test that MEOW is up and running
curl http://127.0.0.1:8080/api/ping/<api_key>
{
"method": "ping",
"params": {
"user": "purr",
"host": "indico.jacow.org",
"date": "2023-10-02T13:51:08.737960"
}
}