Installing Karamelo on Linux opr any POSIX System
1) Install packages that you need:
Apache (1 or 2) Rewrite module for Apache PHP5 Postgresql 8.1 GD2 graphics libraries for PHP5
On Debian/Ubuntu:
$sudo apt-get install php5 postgresql-8.1 php5-pgsql apache2 libapache2-mod-php5
On OpenSuSE:
$sudo yast2 -i apache2 php5 php5-pgsql postgresql-8.2 php5-gd
On NetBSD use pkgsrc on OpenBSD use pkg_add on Solaris... well, you know what to do.
2) Create PostgreSQL user (you must type the password for postgres user):
$sudo -u postgres createuser -D -A -P karauser
3) Create Database:
$sudo -u postgres createdb -E utf8 -O karauser DBKARAMELO
4) Edit:
$sudo mcedit /etc/postgresql/8.1/main/pg_hba.conf
5) Add the line:
local DBKARAMELO karauser md5
6) Restart:
$sudo /etc/init.d/postgresql restart
6) Switch to user www-data:
$sudo su www-data
7) Download the last CakePHP stable version (current 1.1.18):
8) Extract the file on /var/www.
9) Now you will have a directory like /var/www/cake_1.1.1xxx, rename:
$mv /var/www/cake_1.1.1xxx /var/www/cake
11) Get the karamelo code:
$wget ftp://mononeurona.org/pub/karamelo/karamelo-0.1.tar.bz2
$tar -jxvf karamelo-0.1.tar.bz2
12) Create tables:
$sudo -u postgres psql DBKARAMELO < /var/www/cake/karamelo/config/sql/karamelo_postgres.sql -U karauser -W
you can access the DB with:
$sudo -u postgres psql DBKARAMELO -U karauser -W
13) Open the file /var/www/cake/karamelo/config/database.php.default and save it like "database.php":
14) You must change some lines to get something like this:
var $default = array('driver' => 'postgres',
'connect' => 'pg_connect',
'host' => 'localhost',
'login' => 'karauser',
'password' => '67dgreYTE45TY',
'database' => 'DBKARAMELO',
'prefix' => );
14) Edit your apache2 site:
$sudo mcedit /etc/apache/sites-available/default
make sure your DocumentRoot? and Directory parameters are set on "/var/www/cake/karamelo/webroot", look the example. Save, exit and restart apache2:
$sudo /etc/init.d/apache2 restart
Now you can go to http://localhost and login as administrator:
username: webmaster
password: admin
Change the password on the "My account" screen.
Enjoy!
