User Tools

  • Logged in as: anonymous (anonymous)
  • Log Out

Site Tools


Server Setup and Operations Corner

Cron jobs

  • Asynchronous e-mails sending (/etc/cron.d/mantis-emails)
    the send_emails.php script is executed every 5 minutes
  • MantisBT manuals build (cron.hourly/mantis-docbook)
    The MantisBT documentation build script is executed every hour; it processes both the 1.2.x and master branches (if there have been changes to them since the last build), and the resulting manuals are then published to http://mantisbt/docs/
  • MantisBT nightly builds (cron.daily/nightly-builds)
    tarballs for the 1.2.x and master branches are built every night, the 2 most recent ones are kept. A logfile is generated in /var/log/nightly-builds.log



Custom log rotations are defined in /etc/logrotate.d/mantis

  • /var/log/nightly-builds.log: monthly rotation, keep 3
  • /var/log/mantis-docbook.log: daily rotation, keep 5
  • /var/log/irclogs.log: daily rotation, keep 5




The DokuWiki update check has been disabled on 10-Aug-2015, because we can't upgrade to newer versions for the time being due to PHP version requirements with the old server.


To cope with an outdated PHP version preventing nightly builds to complete on master branch following the introduction of composer dependencies, phpenv has been setup on the server, in /srv/phpenv.

PHP version 7.0.17 has been compiled, and the nightly builds script modified to switch to use that. If another version is needed for any reason, refer to installation steps 4 and 5 below.


If you need to use a specific PHP version with phpenv, e.g. for a manual operation, the following commands need to be executed to initialize the environment:

export PHPENV_ROOT=/srv/phpenv
eval "$(phpenv init -)"

Run phpenv help for a list of available commands.

Note that to switch the global PHP version, the phpenv global command must be run as root since the configuration file is saved in /srv/phpenv.

Installation notes

Generally following the instructions in phpenv's README file.

  1. Pre-requisites
    To allow additional packages to be installed, the APT sources must be updated because the Ubuntu 10.10 packages have been moved to the old-releases archive.
    • Create backup of sources list in sources.list.backup_20170413
    • Edit /etc/apt/sources.list and replace all occurences of and by
    • Run
      sudo apt-get update
  2. Install phpenv and php-build
    git clone git:// /srv/phpenv
    git clone /srv/phpenv/plugins/php-build
  3. Install packages required to compile PHP
    sudo apt-get install libxml2-dev libcurl4-gnutls-dev libjpeg-dev libpng-dev libmcrypt-dev libreadline-dev libtidy-dev libxslt-dev
  4. Install and compile PHP 7.0.17 (this takes a while)
    phpenv install 7.0.17
  5. Update phpenv shims
    phpenv rehash
mantisbt/server_setup.txt · Last modified: 2017/04/13 09:58 by dregad