Install Perl, along with the following modules (available from CPAN / metacpan):
Actual mail sending requires the Net::SMTP and Net::Domain Perl modules,
A PostgreSQL database, version 9.2 or newer, must be running.
On a Linux system, you would do one of:
postgres (you can do su - postgres as root to log in to that account on Linux) and run: pg_ctl start
root and run: systemctl start postgresqlXX (XX being the version)
root and run: service postgresql start
A mail (SMTP) server must be running.
On a Linux system with Postfix, you would do one of (as root):
systemctl start postfix
service postfix start
Create the database user to host the application's database.
On PostgreSQL, login to the system as the database user postgres and run:
createuser -P meqaris
Create the application's database.
On PostgreSQL, login to the system as the database user postgres and run:
createdb -O meqaris meqaris
NOTE for older database versions
On PostgreSQL versions older than 13.0, you may need to perform one additional step before running Meqaris - install the btree_gist extension manually in the Meqaris database you've just created. Meqaris cannot do this, because only the database superuser (usually postgres) is allowed to do it.
Substitute the hostname and port number where necessary and run this command to install the extension:
psql -U postgres -h <hostname> -p <port number> -d meqaris -c 'create extension if not exists btree_gist;'
Database access rules must be created within the database server, unless you wish to leave the default rules.
On PostgreSQL, you would do (as the database user postgres or root):
cp /var/lib/pgsql/data/pg_hba.conf /var/lib/pgsql/data/pg_hba.conf-backup
echo local meqaris meqaris scram-sha-256 >> /var/lib/pgsql/data/pg_hba.conf
echo host all all 127.0.0.1/32 scram-sha-256 >> /var/lib/pgsql/data/pg_hba.conf
(Note the double >>- it's CRUCIAL to use double >>, a single > would OVERWRITE the target file).
On older PostgreSQL versions replace scram-sha-256 with md5.
If you'll need to access the database from another computer:
host all all 127.0.0.1/32 scram-sha-256 should be added to pg_hba.conf, containing the correct IP address/etc/hosts.allow file (tcpwrappers) may need to be adjustedAfter changing the access rules for the database server, restart it. On Linux with PostgreSQL, you would do one of:
postgres and run: pg_ctl restart
root and run: systemctl restart postgresqlXX (XX being the version)
root and run: service postgresql restart
To install:
BINDIR - a directory for the Meqaris program (like /usr/bin),CONFDIR - a directory for the Meqaris' configuration (like /etc),DATADIR - a directory for the Meqaris' data files (like /var/lib). The data files will be installed in DATADIR/meqaris,DOCDIR - a directory for the Meqaris' documentation (like /usr/share/doc). The documentation will be installed in DOCDIR/meqaris,MANDIR- a directory for the manual files (like /usr/share/man). The manual page will be installed in MANDIR/man1.bin/meqaris to BINDIRconfig/meqaris.ini to match your directories and database settings (see below)config/meqaris-log4perl.cfg and choose your log file's locationsql directory and the config/meqaris-log4perl.cfg file to DATADIR/meqaris. The DATADIR/meqaris directory must be writable for your mail serverconfig/meqaris.ini to CONFDIRconfig/meqaris.logrotate to a directory expected to contain logrotate configuration files (like CONFDIR/logrotate.d)/usr/share/docAlternatively, if you have the make program and some common Linux utilities, you can run make install, passing the target directories.. Examples:
make install BINDIR=/usr/bin CONFDIR=/etc DATADIR=/var/lib DOCDIR=/usr/share/doc MANDIR=/usr/share/man
make install BINDIR=$HOME/tools/meqaris/bin \
CONFDIR=$HOME/tools/meqaris/etc \
DATADIR=$HOME/tools/meqaris/data \
DOCDIR=$HOME/tools/meqaris/doc \
MANDIR=$HOME/tools/meqaris/man
All the above directories and their parent directories must be reachable by your mail server.
The log file (/var/log/meqaris.log by default) must be created writable for your mail server. Alternatively, the directory which would contain it must be writable by your mail server.
The necessary database structures will be automatically created by the application itself while operating, but to avoid concurrent database upgrades (all of which except one would fail), it is recommended to run the database installation/upgrade scripts manually by calling
meqaris --upgrade-db
See also:
To uninstall, if needed:
meqaris script from the directory you installed it to,meqaris.ini file from the directory you installed it tomeqaris-log4perl.cfg file from the directory you installed it topostgres: dropdb meqaris
postgres: dropuser meqaris
Alternatively, if you have the make program and some common Linux utilities, you can run make uninstall, passing the same directories that were used during installation. Examples:
make uninstall BINDIR=/usr/bin CONFDIR=/etc DATADIR=/var/lib DOCDIR=/usr/share/doc MANDIR=/usr/share/man
make uninstall BINDIR=$HOME/tools/meqaris/bin \
CONFDIR=$HOME/tools/meqaris/etc \
DATADIR=$HOME/tools/meqaris/data \
DOCDIR=$HOME/tools/meqaris/doc \
MANDIR=$HOME/tools/meqaris/man
Wiki: CalDAV configuration
Wiki: Features
Wiki: Home
Wiki: Mail server configuration
Wiki: Meqaris INI file