Install Wekan on your server

4 minute read

Wekan is a Trello like board that lets you organize your projects using the Kanban principles. In this post we will assume that you own the domain and that you want to host your Wekan board under the subdomain using Apache.


Configure Apache and Let’s Encrypt

First we need to create an apache configuration file. We copy an existing one that will serve as a template:

cd /etc/apache2/sites-available
sudo cp

We modify the file with sudo vim and set the following variables:

  • DocumentRoot: /var/www/
  • ServerName:
  • ServerAlias:

We also add the following to VirtualHost command block, note the trailing slash in the ProxyPass lines:

   ProxyRequests Off
   ProxyPreserveHost On
   ProxyVia Full
   <Proxy *>
      Require all granted

   ProxyPass "/"
   ProxyPassReverse "/"   

Since Wekan uses NodeJS, we need to use a reverse proxy so that Apache can redirect the queries to NodeJS.

Finally we activate Let’s Encrypt (choose Expand)

We enable the site with

sudo a2ensite
sudo service apache2 reload

Install MongoDB

Wekan uses MongoDB to store its information.

We add the MongoDB repository and install MongoDB and its tools:

# MongoDB for Ubuntu 16.04
sudo apt-key adv --keyserver hkp:// --recv EA312927
echo "deb xenial/mongodb-org/3.2 multiverse" | sudo tee /etc/apt/sources.list.d/mongodb-org-3.2.list
sudo apt update
sudo apt install -y mongodb-org mongodb-org-server mongodb-org-shell mongodb-org-mongos mongodb-org-tools

We then activate MongoDB

sudo systemctl start mongod
sudo systemctl enable mongod

Install Meteor

As you might have noticed already, Wekan is built using the Meteor web framework, so we need to install this as well. This can be done easily using their install script (read it if you don’t trust it).

curl | sh

Install and Build Wekan

Before installing Wekan, we need to install NodeJS. Wekan uses a very specific version of NodeJS so we need to carefully follow the installation procedure.

Install nodejs

We start by cleaning old modules

sudo rm -rf /usr/local/lib/node_modules
sudo rm -rf ~/.npm

We download Wekan in ~/Git/. We will install it later.

# Download Wekan
git clone
cd wekan
git submodule init
git submodule update
#### OPTIONAL: test pull request
## git checkout -b dwrensha-profile-bugfix devel
## git pull profile-bugfix

We install Node.js 4.8.1

sudo apt install build-essential g++ capnproto nodejs nodejs-legacy npm git curl
sudo npm -g install n
## if the previous fails (and asks you to run as sudo) just rm /home/<username>/node_modules and retry
sudo n 4.8.1
sudo npm -g install npm@latest
sudo npm -g install node-gyp
sudo npm -g install node-pre-gyp
sudo npm -g install fibers

And we finish by installing Wekan npm dependencies

sudo chown -R $USER:$(id -gn $USER) /home/sammy/.config
npm install


In ~/Git/wekan, we build the project:

rm -rf .build
meteor build .build --directory
cp fix-download-unicode/cfs_access-point.txt .build/bundle/programs/server/packages/cfs_access-point.js
sed -i "s|build\/Release\/bson|browser_build\/bson|g" .build/bundle/programs/server/npm/node_modules/meteor/cfs_gridfs/node_modules/mongodb/node_modules/bson/ext/index.js
cd .build/bundle/programs/server/npm/node_modules/meteor/npm-bcrypt
rm -rf node_modules/bcrypt
npm install bcrypt
cd .build/bundle/programs/server
npm install

Install in /var/www/

As stated earlier, we install Wekan in /var/www/

sudo mkdir /var/www/
sudo cp -r ~/Git/wekan/.build/bundle/* /var/www/
sudo chown -R $USER:$USER /var/www/

Start Wekan

Wekan uses NodeJS. However since our IP address is already tied to our Apache server, we need to have a reverse proxy so that when a user goes to, Apache redirects the user to NodeJS.

To do this we install pm2 with npm

## Install PM2
sudo npm install -g pm2

Then we create a script ~/scripts/ and we place the following content in it:

cd /var/www/
export MONGO_URL='mongodb://'
export ROOT_URL=''
export MAIL_URL='smtp://myusername:mypass@smtpserver:465/'
# This is local port where Wekan Node.js runs.
export PORT=8080
pm2 start main.js
pm2 startup systemd

Note that since we use Let’s Encrypt and redirect all http traffic to https, we must use https in the ROOT_URL.

We make the script executable and run it to start Wekan:

chmod +x ~/scripts/

The variable MAIL_URL contains the smtp configuration. I personally own a SMTP server at OVH and configured it like this smtp://

The smtp server is very important. It will allow users to share boards and recover their passwords.

Configure Wekan

Now you can connect to Wekan, create your first user and first boards.

It is advised to disable the signup in the administation panel. You can always invite people to Wekan if they want to create a user.

Note that you can change your smtp configuration in admin panel > Settings > Email:

Here is my current configuration:

SMTP Host :
SMTP Port : 465
Username :
Password : myPassword
TLS support : enabled
From : sammy <>