Editing RBE10K/Libreplan/Installation

Jump to: navigation, search

Warning: You are not logged in.

Your IP address will be recorded in this page's edit history.
The edit can be undone. Please check the comparison below to verify that this is what you want to do, and then save the changes below to finish undoing the edit.
Latest revision Your text
Line 3: Line 3:
 
== Install dependencies ==
 
== Install dependencies ==
 
<code>
 
<code>
echo "x11-base/xorg-server xvfb" >> /etc/portage/package.use
+
emerge -a commons-dbcp commons-pool tomcat jdbc-postgresql postgresql-server
emerge -a virtual/jdk commons-dbcp commons-pool tomcat jdbc-postgresql postgresql-server cutycapt
+
 
</code>
 
</code>
  
 
== Create Tomcat instance ==
 
== Create Tomcat instance ==
 
<code>
 
<code>
/usr/share/tomcat-7/gentoo/tomcat-instance-manager.bash --create
+
/usr/share/tomcat-7/gentoo/tomcat-instance-manager.bash --create
 
</code>
 
</code>
  
Line 16: Line 15:
 
== Add necessary jars ==
 
== Add necessary jars ==
 
<code>
 
<code>
ln -s /usr/share/jdbc-postgresql/lib/jdbc-postgresql.jar /usr/share/tomcat-7/lib/
+
ln -s /usr/share/jdbc-postgresql/lib/jdbc-postgresql.jar /usr/share/tomcat-7/lib/
ln -s /usr/share/commons-dbcp/lib/commons-dbcp.jar /usr/share/tomcat-7/lib/
+
ln -s /usr/share/commons-dbcp/lib/commons-dbcp.jar /usr/share/tomcat-7/lib/
ln -s /usr/share/commons-pool/lib/commons-pool.jar /usr/share/tomcat-7/lib/
+
ln -s /usr/share/commons-pool/lib/commons-pool.jar /usr/share/tomcat-7/lib/
 
</code>
 
</code>
  
 
== Create the database ==
 
== Create the database ==
 
<code>
 
<code>
su postgres -c psql
+
su postgres -c psql
CREATE DATABASE libreplan;
+
CREATE DATABASE libreplan;
CREATE USER libreplan WITH PASSWORD 'libreplan';
+
CREATE USER libreplan WITH PASSWORD 'libreplan';
GRANT ALL PRIVILEGES ON DATABASE libreplan TO libreplan;
+
GRANT ALL PRIVILEGES ON DATABASE libreplan TO libreplan;
\q
+
 
</code>
 
</code>
  
Line 35: Line 33:
 
== Install the database ==
 
== Install the database ==
 
<code>
 
<code>
psql -h localhost -U libreplan -W libreplan < install.sql
+
psql -h localhost -U libreplan -W libreplan < install.sql
 
</code>
 
</code>
  
== Install the web application as ROOT ==
+
== Install the web application ==
 
<code>
 
<code>
mv /var/lib/tomcat-7/webapps/ROOT /var/lib/tomcat-7/original-webapps-ROOT
+
cp libreplan.war /var/lib/tomcat-7/webapps/
cp libreplan.war /var/lib/tomcat-7/webapps/ROOT.war
+
 
</code>
 
</code>
  
 
== Configure Libreplan ==
 
== Configure Libreplan ==
Create a file '''/etc/tomcat-7-libreplan/Catalina/localhost/ROOT.xml''' with the following contents:
+
Edit '''/etc/tomcat-7-libreplan/Catalina/localhost/libreplan.xml''' and paste this in it:
  
 
<code>
 
<code>
<?xml version="1.0" encoding="UTF-8"?>
+
<?xml version="1.0" encoding="UTF-8"?>
+
 
<Context antiJARLocking="true" path="">
+
<Context antiJARLocking="true" path="">
 
     <Resource name="jdbc/libreplan-ds" auth="Container"
 
     <Resource name="jdbc/libreplan-ds" auth="Container"
 
         type="javax.sql.DataSource"
 
         type="javax.sql.DataSource"
Line 58: Line 55:
 
         driverClassName="org.postgresql.Driver"
 
         driverClassName="org.postgresql.Driver"
 
         url="jdbc:postgresql://localhost/libreplan" />
 
         url="jdbc:postgresql://localhost/libreplan" />
</Context>
+
</Context>
</code>
+
</code>
  
 
'''''NOTE THE LINE THAT HAS TO BE PRESENT''''': ''factory="org.apache.commons.dbcp.BasicDataSourceFactory"''
 
'''''NOTE THE LINE THAT HAS TO BE PRESENT''''': ''factory="org.apache.commons.dbcp.BasicDataSourceFactory"''
Line 65: Line 62:
 
== Start the application ==
 
== Start the application ==
 
<code>
 
<code>
/etc/init.d/tomcat-7 start
+
/etc/init.d/tomcat-7 start
rc-update add tomcat-7 default
+
 
</code>
 
</code>

Please note that all contributions to The Crowdsourced Resource-Based Economy Knowledgebase are considered to be released under the Creative Commons Zero (Public Domain) (see RBEMWiki:Copyrights for details). If you do not want your writing to be edited mercilessly and redistributed at will, then do not submit it here.
You are also promising us that you wrote this yourself, or copied it from a public domain or similar free resource. Do not submit copyrighted work without permission!

Cancel | Editing help (opens in new window)
Personal tools
Namespaces

Variants
Actions
Navigation
Toolbox
Share