Etherpad is a highly customizable Open Source online editor providing collaborative editing in real-time. Etherpad allows you to edit documents collaboratively in real-time, much like a live multi-player editor that runs in your browser. When you install pad_project module in Odoo, you need to set up Etherpad server first. Installation and Setup of Etherpad is littelbit difficult and tricky. So here we came up with step by step guide to set up Etherpad server in Ubuntu.
We tried to set up Etherpad server inside Ubuntu 14.04 server.
Installation of Etherpad-lite
Create etherpad user.
sudo adduser –system –home=/opt/etherpad –group etherpad
Note : I choose /opt folder for the program location in order to keep things clean. So if you want to change that folder then make sure to alter some of the instructions and configuration files below respectively.
sudo apt-get install gzip git-core curl python libssl-dev build-essential abiword python-software-properties
Install nodejs & npm
curl -sL https://deb.nodesource.com/setup_5.x | sudo -E bash –
sudo apt-get install -y nodejs
Install and run Etherpad Lite
sudo su – etherpad -s /bin/bash
mkdir -p ~/local/etherpad
cd ~/local/etherpad
git clone git://github.com/ether/etherpad-lite.git
cd etherpad-lite
bin/run.sh
Etherpad-lite servcice is started now by running command bin/run.sh. Without closing the terminal you can open your favorite browser and access etherpad by this link http://localhost:9001/ or http://0.0.0.0:9001/
If you are able to see, following screen then it means your etherpad server is working properly.
Note : If you want to change the port for Etherpad server or other necessary changes, you can set them in following file.
/opt/etherpad/local/etherpad/etherpad-lite/settings.json
Now let’s integrate this etherpad with Odoo. Install pad_project module.
After installation, you have to configure PAD server IP and API key in order to integrate Odoo with Etherpad server. To do so, open any company and inside Configuration tab, you will need to set proper values.
Pad Server : http://localhost:9001
Pad Api Key : ( You can get it from /opt/etherpad/local/etherpad/etherpad-lite/APIKEY.txt file. Just open that file, copy that key and paste it over here. )
Note : You can install Etherpad-lite into different server then Odoo server. It is not necessary to keep them both in same server. Just provide the remote IP inside ‘Pad Server‘option inside the configuration in Odoo.
Upon everything properly set up, you will see etherpad available inside any task screen.
You have to start etherpad server manually everytime when you want it to integrate with Odoo. So if you want to create service for etherpad, follow below steps,
sudo mkdir /var/log/etherpad-lite
sudo touch /var/log/etherpad-lite/etherpad-lite.log
sudo chown etherpad.etherpad /var/log/etherpad-lite
sudo chmod -R 777 /var/log/etherpad-lite
Create file etherpad-lite under /etc/init.d folder & Paste the following file content into it.
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
|
#!/bin/sh ### BEGIN INIT INFO # Provides: etherpad-lite # Required-Start: $local_fs $remote_fs $network $syslog # Required-Stop: $local_fs $remote_fs $network $syslog # Default-Start: 2 3 4 5 # Default-Stop: 0 1 6 # Short-Description: starts etherpad lite # Description: starts etherpad lite using start-stop-daemon ### END INIT INFO PATH = "/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin:/opt/node/bin" LOGFILE = "/var/log/etherpad-lite/etherpad-lite.log" EPLITE_DIR = "/opt/etherpad/local/etherpad/etherpad-lite" EPLITE_BIN = "bin/run.sh" USER = "etherpad" GROUP = "etherpad" DESC = "Etherpad Lite" NAME = "etherpad-lite" set - e . / lib / lsb / init - functions start() { echo "Starting $DESC... " start - stop - daemon - - start - - chuid "$USER:$GROUP" - - background - - make - pidfile - - pidfile / var / run / $NAME.pid - - exec $EPLITE_DIR / $EPLITE_BIN - - $LOGFILE || true echo "done" } #We need this function to ensure the whole process tree will be killed killtree() { local _pid = $ 1 local _sig = ${ 2 - TERM} for _child in $(ps - o pid - - no - headers - - ppid ${_pid}); do killtree ${_child} ${_sig} done kill - ${_sig} ${_pid} } stop() { echo "Stopping $DESC... " if test - f / var / run / $NAME.pid; then while test - d / proc / $(cat / var / run / $NAME.pid); do killtree $(cat / var / run / $NAME.pid) 15 sleep 0.5 done rm / var / run / $NAME.pid fi echo "done" } status() { status_of_proc - p / var / run / $NAME.pid " " " etherpad - lite" && exit 0 || exit $? } case "$1" in start) start ;; stop) stop ;; restart) stop start ;; status) status ;; * ) echo "Usage: $NAME {start|stop|restart|status}" >& 2 exit 1 ;; esac exit 0 |
sudo chmod -R 777 /etc/init.d/etherpad-lite
sudo chown -R etherpad.etherpad /etc/init.d/etherpad-lite
Let’s start Etherpad services,
service etherpad-lite start
If you want Etherpad services at startup time then apply following command,
sudo update-rc.d etherpad-lite defaults
That was all about how to set up Etherpad server and integreate it with Odoo. Feel free to send your valuable feedback in Comments area. I will look forward for your queries in case of if above steps are not working.
Being an emerging leader in IT market since 2011, Emipro Technologies Pvt. Ltd. has been providing a wide range of business solutions in Odoo & Magento. We are pleased to have a large pool of contented customers with our meticulous work in the domain of ERP & e-Commerce. A ray of relief & satisfaction to our customers heart by our successful deployment in their organization, purely represents our success in Odoo platform. Hence, we take pride for being an Odoo partner with a vision of expanding our strategic alliances with our customers to offer them high value-added, trustworthy cost effective business solutions & usefull Odoo and Magento Apps. We are just an inch away from you by email info@emiprotechnologies.com or a tweet to @EmiproTech
fuck\fuck\(\)\[\]\\\/\fuck”\\$1″fuck\/script>’)} fuck