#define READ_VALUE(n, p, i) ((n) >> (p)) & ((1 <<(i)) - 1)
The above macro return the byes of specified position
#define READ_VALUE(n, p, i) ((n) >> (p)) & ((1 <<(i)) - 1)
The above macro return the byes of specified position
apache2
postgresql-9.1.7
or latest
php5
php5-cli
php5-pgsql
php-pear
php5-curl
php5-ldap
php5-gd
postfix
cvs
curl
postfix
// Edit Postgres
config
vim /etc/postgresql/9.1/main/pg_hba.conf
// Use trust
for both
# Database administrative login by UNIX sockets
local
all postgres trust
# "local" is for Unix domain socket
connections only
local all all trust
// Restart
Postgres
etc/init.d/postgresql restart
// Create users
and DB
createuser -SRDU postgres matrix
createuser -SRDU
postgres matrix_secondary
createdb -U postgres -O matrix -E UTF8
squiz_matrix
createlang -U postgres plpgsql squiz_matrix
Install Matrix
mkdir /home/websites
cd /home/websites
//
Checkout and install Matrix
curl -O
http://public-cvs.squiz.net/cgi-bin/viewvc.cgi/mysource_matrix/scripts/dev/checkout.sh?view=co
mv
checkout.sh\?view\=co checkout.sh
sh checkout.sh mysource_4-12-3
Set Domain name
vim /etc/hosts
add the line
Init Matrix
// Init the main config
cd
/home/websites/squiz_matrix
php install/step_01.php
/home/websites/squiz_matrix
// Edit the main config file
vim
data/private/conf/main.inc
// The following configuration settings
need to be completed as a minimum
define('SQ_CONF_SYSTEM_ROOT_URLS',
'www.squizserver.com
');
define('SQ_CONF_DEFAULT_EMAIL',
'sabeesh.cs@sterian.com');
define('SQ_CONF_TECH_EMAIL',
'sabeesh.cs@sterian.com
');
// Edit Database file
vim
data/private/conf/db.inc
// Update the PHP array
$db_conf =
array (
'db' => array
(
'DSN'
=> 'pgsql:dbname=squiz_matrix',
'user'
=> 'matrix',
'password'
=> '',
'type'
=> 'pgsql',
),
'db2'
=> array (
'DSN'
=> 'pgsql:dbname=squiz_matrix',
'user'
=> 'matrix',
'password'
=> '',
'type'
=> 'pgsql',
),
'db3'
=> array (
'DSN'
=> 'pgsql:dbname=squiz_matrix',
'user'
=> 'matrix_secondary',
'password'
=> '',
'type'
=> 'pgsql',
),
'dbcache'
=> NULL,
'dbsearch'
=> NULL,
);
return
$db_conf;
// Init database schema
php install/step_02.php
/home/websites/squiz_matrix
// Install core asset types
php
install/compile_locale.php /home/websites/squiz_matrix
php
install/step_03.php /home/websites/squiz_matrix
php
install/compile_locale.php /home/websites/squiz_matrix
Fix Permissions
Do this process as root user / use sudo
before each command
chmod -R 755 /home/websites/squiz_matrix
cd
/home/websites/squiz_matrix
chown -R www-data:www-data data
cache
chmod -R g+w data cache
Apache
// Edit apache
virtual hosts file
vim /etc/apache2/sites-enabled/000-default
//Remove existing, need to check this
ServerName server.example.com
DocumentRoot
/home/websites/squiz_matrix/core/web
Options -Indexes
FollowSymLinks
Order deny,allow
Deny from all
Order allow,deny
Allow from all
php_flag engine off
Order allow,deny
Deny from all
Order allow,deny
Deny from all
Alias /__fudge /home/websites/squiz_matrix/fudge
Alias
/__data /home/websites/squiz_matrix/data/public
Alias /__lib
/home/websites/squiz_matrix/core/lib
Alias /
/home/websites/squiz_matrix/core/web/index.php/
// Restart apache
/etc/init.d/apache2 restart
Cron Setup
// Edit apache
user cron file
crontab -u www-data -e
( select option 4
for editer )
// Add cron
jobs
*/15 * * * * php
/home/websites/squiz_matrix/core/cron/run.php
0 0 * * *
/home/websites/squiz_matrix/scripts/session_cleanup.sh
/home/websites/squiz_matrix
*/15 * * * * php
/home/websites/squiz_matrix/packages/bulkmail/scripts/run.php
Install JRE
sudo apt-get purge openjdk*
After that, go and download Java JRE package from http://www.oracle.com/technetwork/java/javase/downloads/jre7-downloads-1880261.html .
When prompted, save the download. Please select the 32 or 64 bit
.tar.gzversion file from the list.
After
saving the file, go back to your terminal and run the below commands
to extract the java packages you downloaded.
tar -xvf ~/Downloads/jre-7u13-linux-i586.tar.gz
Next,
create your java 7 folder by running the commands below.
sudo mkdir -p /usr/lib/jvm/jre1.7.0
Then
move all the extracted files and folders into the java 7 folder.
sudo mv jre1.7.0_13/* /usr/lib/jvm/jre1.7.0/
Next,
run the commands below to install / update java 7
sudo update-alternatives --install /usr/bin/java java /usr/lib/jvm/jre1.7.0/bin/java 0
Next,
create a plugin folder in your home directory by running the commands
below.
mkdir ~/.mozilla/plugins
Finally, link the java plugin to your profile.
ln -s /usr/lib/jvm/jre1.7.0/lib/i386/libnpjp2.so ~/.mozilla/plugins/
Load Firefox,
Tools->Add-ons, select java, ( Quick java ) and install.
Load the “
www.squizserver.com
“ and enjoy!