To build the extension run:
mkdir build
cd build
cmake -D PostgreSQL_TYPE_INCLUDE_DIR=<postgres include directory> ..
make
sudo make install
in the pg directory. You can also add optional variables in cmake:
- MMSEQ_HOSTNAME - "localhost" by default
- MMSEQ_PORT - 8080 by default
- MMSEQ_TIMEOUT - timeout in milliseconds, 30000 by default (30 seconds)
For example:
cmake -D PostgreSQL_TYPE_INCLUDE_DIR=/usr/include/postgresql/14/server/ -D MMSEQ_TIMEOUT=60000 ..
Then run CREATE EXTENSION mmseq2;
in a PostgreSQL database.
To build the MMSeqs2 computational service run:
mkdir build
cd build
cmake -D PostgreSQL_TYPE_INCLUDE_DIR=<postgres include directory> ..
make
in the mmseq2 directory. You can also optionally set the following environment variables:
- PG_HOST - "localhost" by default
- PG_PORT - 5432 by default
- PG_DBNAME - "bioseqdb" by default
- PG_USER - "postgres" by default
- PG_PASSWORD - "password" by default
to specify for MMSeqs2 from what database to fetch the data such as the target sequences and the indexes.
Then you can run MMSeqs2 by executing the command:
echo <MMSeqs2 port> | ./mmseq2
Another way to build the project is to use the ops/bin/up.sh
shell script
which creates two docker containers - one for the PostgreSQL database
and one for the MMSeqs2 computational service.