Installing Etherpad on Debian
March 10, 2010 — Admin Adminecho "deb http://ftp.de.debian.org/debian sid main non-free" >> /etc/apt/sources.list apt-get update apt-get install sun-java6-jdk
If the above fails then do not continue. The output of
java -version
Should read..
java version "1.6.0_17" Java(TM) SE Runtime Environment (build 1.6.0_17-b04) Java HotSpot(TM) Client VM (build 14.3-b01, mixed mode, sharing)
apt-get install scala mysql-server libmysql-java mercurial
Paste the below to /etc/profile
export PATH export JAVA_HOME="/usr/lib/jvm/java-6-sun" export SCALA_HOME="/usr/share/java" export JAVA="/usr/bin/java" export SCALA="/usr/bin/scala" export PATH="/usr/bin:/usr/bin:/usr/local/mysql/bin:$PATH" export MYSQL_CONNECTOR_JAR="/usr/share/java/mysql-connector-java-5.1.10.jar" export JAVA_HOME SCALA_HOME JAVA SCALA MYSQL_CONNECTOR_JAR PATH umask 022
Download the etherpad source to /usr/local/etherpad
hg clone https://etherpad.googlecode.com/hg/ /usr/local/etherpad
Set the environment variables
export JAVA_HOME="/usr/lib/jvm/java-6-sun" export SCALA_HOME="/usr/share/java" export JAVA="/usr/bin/java" export SCALA="/usr/bin/scala" export PATH="/usr/bin:/usr/bin:/usr/local/mysql/bin:$PATH" export MYSQL_CONNECTOR_JAR="/usr/share/java/mysql-connector-java-5.1.10.jar"
Add your domain to the superdomain section
nano /usr/local/etherpad/trunk/etherpad/src/etherpad/globals.js
Search for etherpad.com and replace it with your domain (confused? You will figure it out)
Create the etherpad mysql db and privelidges
mysql -u root -p
Enter your password when prompted
create database etherpad; grant all privileges on etherpad.* to 'etherpad'@'localhost' identified by 'password'; quit
cd /usr/local/etherpad/trunk/etherpad/ ln -s /usr/share/java /usr/share/java/lib bin/rebuildjar.sh bin/run-local.sh
Wait quite a while while it builds.
<allow-access-from domain="yourdomain.com" to-ports="*"/> <allow-access-from domain="*.yourdomain.com" to-ports="*"/>
Replace
var fromDomain = 'etherpad.com';
var fromDomain = 'yourdomain.com';
Note: Originally published on the 19th of Dec 2009, Revised on the 10th of March 2010



