OpenTimetool
From Andreida
Download and preparation
So you can create your own html2pdf
apt-get install htmldoc
Create the file
vi /usr/local/bin/html2pdf
With the content
#!/bin/bash htmldoc --webpage -f $2 $1
Allow the execution
chmod a+x /usr/local/bin/html2pdf
Now to the real openTimeTool Url to the download:
http://sourceforge.net/projects/opentimetool/
Get the INSTALL file
Create a folder like
mkdir /var/www/openTimeTool.
Unpack the archive with
tar -xzf openTimetool_x.x.x.tar.gz
Open the INSTALL file and keep it open.
less /var/www/openTimeTool/INSTALL
Prepare the database
First of all, backup your database, just in case
mysqldump -p --all-databases > all-databases.sql
Open the console
mysql -p
Create the database
mysql> create DATABASE openTimetool;
Create a new user who has all rights for this new database
mysql>GRANT ALL PRIVILEGES ON openTimetool.* TO 'username'@'localhost' IDENTIFIED BY 'password' WITH GRANT OPTION; FLUSH PRIVILEGES; mysql>quit;
Import the openTimetool structure into the new database
mysql -uusername -p openTimetool < /var/www/openTimetool/mysql.sql
Create the apache file
Create
touch /etc/apache2/sites-available/ssl-openTimetool
enable it
cd /etc/apache2/sites-enabled ln -s ../sites-available/ssl-openTimetool
put something like this into it
<IfModule mod_ssl.c> <VirtualHost openTimetool.<your-domain>:443> DocumentRoot /var/www/openTimetool/ <Directory /var/www/openTimetool> Options FollowSymLinks AllowOverride All <IfModule mod_php4.c> php_flag register_globals off </IfModule> <IfModule mod_php5.c> php_flag register_globals off </IfModule> <IfModule mod_dir.c> DirectoryIndex index.php </IfModule> </Directory> SSLEngine on SSLCertificateFile /etc/<path>/<file>.cert SSLCertificateKeyFile /etc/<path>/<file>.key </VirtualHost>
Modify .htaccess
Open the file
vi /var/www/openTimetool/htdocs/.htaccess
Change
php_value auto_prepend_file "/srv/www/htdocs/openTimetool/config.php"
To
php_value auto_prepend_file "/var/www/openTimetool/config.php"
Change the php files
cd /var/www/openTimetool
Create the config-local.php from a copy of the default
cp config-local.php.dist config-local.php
Edit the config-local.php
vi config-local.php
Correct
$config->dbDSN = 'mysql://<account>:<password>@localhost/openTimetool';
Create links to the languages, yes for english too
cd /var/www/openTimetool/htdocs ln -s . en ln -s . de
Restart the apache
/etc/init.d/apache2 reload