0

Tips & Tricks : Migrating Mozilla Thunderbird settings between computers

-

If you have to move Mozilla Thunderbird data from one computer to another, you can do it by simply copying files between computer.

Folder with Thunderbird profiles is located here:

%APPDATA%\Thunderbird\Profiles\

There will be at least one or more sub-folders with profile data.

What you need to copy is content of Thunderbird profile you want to migrate to new computer.

On destination computer install Thunderbird and in same folder there will be sub-folder with default profile.

Copy all file from source profile to destination and that’s it.

In case you want to create Thunderbird profile in different folder start Thunderbird with following command:

thunderbird -p

That will allow you to define location of the new profile.

How that helps with migrating Thunderbird between folders/drives or computers.

0

Tips & Tricks : MediaWiki 1.25.1 and VisualEditor

-

In case you want to deploy MediaWiki 1.25.1 with VisualEditor use following components:

Configuration details for LocalSettings.php for these components can be found here:

When you download VisualEditor from Git repository installation with MediaWiki 1.25.1 is more likely to fail.

0

How-To : Autostart Parsoid on openSUSE 13.1

-

Once Parsoid is installed on openSUSE it might be handy to have is started automatically once system is restarted.

First we have to create startup script.

/etc/init.d/parsoid

#!/bin/sh

#
# description: Node.js /srv/parsoid/api/server.js
#

. /etc/rc.status

USER="root"

DAEMON="/usr/bin/node"
ROOT_DIR="/srv/parsoid/api"
LOG_ROOT="/var/log/nodejs"

SERVER="$ROOT_DIR/server.js"
LOG_FILE="$LOG_ROOT/parsoid.log"

LOCK_FILE="/var/lock/subsys/node-server"

WORKERS_NUMBER=8

do_start()
{
if [ ! -f "$LOCK_FILE" ] ; then
echo -n $"Starting $SERVER: "
runuser -l "$USER" -c "$DAEMON $SERVER -n $WORKERS_NUMBER >> $LOG_FILE &" && echo || echo
RETVAL=$?
echo
[ $RETVAL -eq 0 ] && touch $LOCK_FILE
else
echo "$SERVER is locked."
RETVAL=1
fi
}
do_stop()
{
echo -n $"Stopping $SERVER: "
pid=`ps -aefw | grep "$DAEMON $SERVER" | grep -v " grep " | awk '{print $2}'`
kill -9 $pid > /dev/null 2>&1 && echo || echo
RETVAL=$?
echo
[ $RETVAL -eq 0 ] && rm -f $LOCK_FILE
}

case "$1" in
start)
do_start
;;
stop)
do_stop
;;
restart)
do_stop
do_start
;;
*)
echo "Usage: $0 {start|stop|restart}"
RETVAL=1
esac

exit $RETVAL
Remember to adjust all paths and number of worker processes accordingly to your installation.

Once startup script is in place we have to enable Parsoid to be automatically started:

chkconfig parsoid on

From now on Parsoid will be automatically started after each restart.

0

How-To : Deploy VisualEditor extension for MediaWiki 1.24.2 on openSUSE 13.1 x64

-

In previous article I described how-to Deploy Parsoid on openSUSE 13.1 (which turns out to be quite a challenging task). Parsoid is component required for VisualEditor. Now it’s time for VisualEditor deployment.

Downloading VisualEditor

At the moment, when I’m doing deployment, stable version of MediaWiki is 1.24.2. VisualEditor is an extension written for certain version of MediaWiki, hence we can’t just download latest version and use it. It has to be specific release for specific MediaWiki version.

So, first we download VisualEditor for MediaWiki 1.24.2:

git clone -b REL1_24 https://github.com/wikimedia/mediawiki-extensions-VisualEditor.git
cd mediawiki-extensions-VisualEditor/
git submodule update --init

Once it’s done we need to place content of mediawiki-extensions-VisualEditor in extensions/VisualEditor folder under MediaWiki folder structure.

Finally, once we have all files in proper places it’s time to inform MediaWiki about VisualEditor.

Changes to LocalSettings.php

Changes which have to be applied to LocalSettings.php:

# VISUAL Editor
require_once("$IP/extensions/VisualEditor/VisualEditor.php");
$wgDefaultUserOptions['visualeditor-enable'] = 1;
$wgHiddenPrefs[] = 'visualeditor-enable';
$wgVisualEditorParsoidURL = 'http://localhost:8000';
$wgVisualEditorParsoidPrefix = 'localhost';
Remember to adjust Parsoid URL and Prefix accordingly to setup of your Parsoid service.

From now on you can enjoy VisualEditor until you decide to upgrade to newer version of MediaWiki.
Prior to that I would suggest to check if there is VisualEditor available for new release and test it prior to live deployments.

1

How-To : Deploy Parsoid for MediaWiki on openSUSE 13.1 x64

-

I took a challenge of running MediaWiki with Visual Editor extension on openSUSE 13.1 x64. Task sounds maybe easy, but turned out to be little madness, so once I got this working I think it might be nice to share my steps.

Operating system has been deployed from ISO image: openSUSE-13.1-NET-x86_64.iso.

Installing Node.js

Basically Node.js package which is included in distro doesn’t work properly. For that reason first step is to add new repository for Node.js:

sudo zypper ar http://download.opensuse.org/repositories/devel:/languages:/nodejs/openSUSE_13.1/ Node.js
sudo zypper in nodejs nodejs-devel
yast -i nodejs

 

Updating NPM

Once Node.js is installed it’s not quite fully working yet and any attempt of using npm fails. Some symlinks are missing, so to fix it we can just update npm:

curl -L https://npmjs.org/install.sh | sudo sh

 

Parsoid deployment

Now we can download Parsoid and make it work:

cd /srv
git clone https://gerrit.wikimedia.org/r/p/mediawiki/services/parsoid
cd parsoid
npm install
npm test
npm start
Parsoid will be located in /srv/parsoid folder. Do not forget to modify /srv/parsoid/api/localsettings.js for your system.

This is quite brief description, however saves lot of time and fight with Node.js and npm on openSUSE.

 

 

0

Tips & Tricks : Configure Apache on Debian 7 for RT4

-

Once Request Tracker 4 is installed on Debian 7, there is one more thing to do.

Small change in Apache configuration to make RT4 website to work.

First edit Apache configuration file:

root@hostname:~# vi /etc/apache2/sites-available/default

Then add to that file (at the end):

Include /etc/request-tracker4/apache2-modperl2.conf
RedirectMatch ^/$ /rt
</VirtualHost>