{"id":18462,"date":"2016-01-26T14:34:11","date_gmt":"2016-01-26T20:34:11","guid":{"rendered":"https:\/\/www.rosehosting.com\/blog\/?p=18462"},"modified":"2022-06-03T03:43:51","modified_gmt":"2022-06-03T08:43:51","slug":"install-wekan-on-an-ubuntu-14-04-vps","status":"publish","type":"post","link":"https:\/\/www.rosehosting.com\/blog\/install-wekan-on-an-ubuntu-14-04-vps\/","title":{"rendered":"How to install Wekan on Ubuntu 14.04"},"content":{"rendered":"
In this blog post we will show you how to install Wekan on an Ubuntu 14.04 VPS<\/strong> with the latest version of Nginx as a reverse proxy. Wekan is an open-source Trello-like kanban board application which runs on Node.js and MongoDB. This guide should work on other Linux VPS<\/a> systems as well, but was tested and written for Ubuntu 14.04 VPS<\/a>.<\/p>\n <\/p>\n We will install the nodejs version 0.10.40 using the nvm (Node Version Manager) script<\/p>\n To install the latest MongoDB package from the official MongoDB repository run the following commands:<\/p>\n Create a root directory for your Wekan instance and download the latest release from github using the following commands:<\/p>\n In case you never heard of Forever, it is a tool which ensures that a given script runs forever.<\/p>\n Do not forget to change username with your actual username.<\/p>\n You can now start your Wekan service with :<\/p>\n The latest version of Nginx 1.8 is not available via the default Ubuntu repositories, so we will add the “nginx\/stable” PPA, update the system and install the nginx package.<\/p>\n Create a new Nginx server block with the following content<\/p>\n Activate the server block by creating a symbolic link :<\/p>\n Test the Nginx configuration and restart the server<\/p>\n That’s it. You can now open your browser, type the address of your Wekan instance and register your first user.<\/p>\n For more information about how manage your Wekan application, please refer to the Wekan<\/a> website.<\/p>\n Of course you don\u2019t have to do any of this if you use one of our Linux VPS Hosting<\/a> services, in which case you can simply ask our expert Linux admins to setup this for you. They are available 24×7 and will take care of your request immediately.<\/p>\n PS<\/span><\/strong>. If you liked this post please share it with your friends on the social networks using the buttons on the left or simply leave a reply below. Thanks.<\/p>\n","protected":false},"excerpt":{"rendered":" In this blog post we will show you how to install Wekan on an Ubuntu 14.04 VPS with the latest … <\/p>\nLog in to your VPS via SSH<\/h4>\n
ssh user@vps_IP<\/pre>\n
Update the system and install necessary packages<\/h4>\n
[user]$ sudo apt-get update && sudo apt-get -y upgrade\r\n[user]$ sudo apt-get install software-properties-common libssl-dev curl build-essential nano<\/pre>\n
Install Node.js<\/h4>\n
[user]$ curl -o- https:\/\/raw.githubusercontent.com\/creationix\/nvm\/v0.30.1\/install.sh | bash\r\n[user]$ source ~\/.nvm\/nvm.sh\r\n[user]$ nvm install v0.10.40\r\n[user]$ nvm use v0.10.40\r\n[user]$ nvm alias default v0.10.40<\/pre>\n
Install MongoDB<\/h4>\n
[user]$ sudo apt-key adv --keyserver keyserver.ubuntu.com --recv 7F0CEB10\r\n[user]$ echo 'deb http:\/\/downloads-distro.mongodb.org\/repo\/ubuntu-upstart dist 10gen' | sudo tee \/etc\/apt\/sources.list.d\/mongodb.list\r\n[user]$ sudo apt-get update\r\n[user]$ sudo apt-get install -y mongodb-org<\/pre>\n
Download and install Wekan<\/h4>\n
[user]$ mkdir -p ~\/wekan\r\n[user]$ curl -LOk https:\/\/github.com\/wekan\/wekan\/releases\/download\/v0.10.1\/wekan-0.10.1.tar.gz\r\n[user]$ tar xzvf wekan-0.10.1.tar.gz -C ~\/wekan\r\n[user]$ cd ~\/wekan\/bundle\/programs\/server\r\n[user]$ npm install \r\n<\/pre>\n
[user]$ npm install forever -g<\/pre>\n
Create an Upstart script<\/h4>\n
[user]$ sudo nano \/etc\/init\/wekan.conf<\/pre>\n
#!upstart\r\n\r\ndescription \"Wekan Upstart Script\"\r\n \r\nstart on startup\r\nstop on shutdown\r\n \r\nexpect fork\r\n\r\nenv NAME=\"Wekan\"\r\nenv NODE_PATH=\"\/home\/username\/.nvm\/v0.10.40\/bin\"\r\nenv APPLICATION_PATH=\"\/home\/username\/wekan\/bundle\/main.js\"\r\nenv PIDFILE=\/var\/run\/wekan.pid\r\nenv LOGFILE=\/var\/log\/wekan.log\r\nenv MONGO_URL=\"mongodb:\/\/127.0.0.1:27017\/wekan\"\r\nenv ROOT_URL=\"http:\/\/127.0.0.1\"\r\nenv MAIL_URL='smtp:\/\/user:pass@mailserver.example.com:25\/'\r\nenv PORT=\"8080\"\r\n\r\nscript\r\n PATH=$NODE_PATH:$PATH\r\n\r\n exec forever \\\r\n --pidFile $PIDFILE \\\r\n -a \\\r\n -l $LOGFILE \\\r\n --minUptime 5000 \\\r\n --spinSleepTime 2000 \\\r\n start $APPLICATION_PATH\r\n\r\nend script\r\n \r\npre-stop script\r\n PATH=$NODE_PATH:$PATH\r\n\r\n exec forever stop $APPLICATION_PATH\r\nend script\r\n<\/pre>\n
[user]$ sudo service wekan start<\/pre>\n
Install and Configure Nginx<\/h4>\n
[user]$ sudo add-apt-repository ppa:nginx\/stable\r\n[user]$ sudo apt-get update\r\n[user]$ sudo apt-get install nginx<\/pre>\n
[user]$ sudo nano \/etc\/nginx\/sites-available\/wekan<\/pre>\n
server {\r\n server_name my_wekan_domain;\r\n listen 80;\r\n\r\n access_log \/var\/log\/nginx\/wekan-access.log;\r\n error_log \/var\/log\/nginx\/wekan-error.log;\r\n\r\n location \/ {\r\n proxy_set_header X-Real-IP $remote_addr;\r\n proxy_set_header Host $host;\r\n proxy_http_version 1.1;\r\n proxy_set_header Upgrade $http_upgrade;\r\n proxy_set_header Connection 'upgrade';\r\n proxy_cache_bypass $http_upgrade;\r\n proxy_pass http:\/\/127.0.0.1:8080;\r\n }\r\n \r\n}\r\n<\/pre>\n
[user]$ sudo ln -s \/etc\/nginx\/sites-available\/wekan \/etc\/nginx\/sites-enabled\/wekan<\/pre>\n
[user]$ sudo nginx -t\r\n[user]$ sudo service nginx restart<\/pre>\n
\n