Pages

Monday, May 10, 2010

server migration -Tips and notes

April 15th 7:04
ssh into the computer
apt-get install apache2
apt-get install mysql-server-5.0
apt-get install php5
apt-get install php5-mysql
--

April 16th 2:58

apt-get update
apt-get upgrade
wget http://downloads.sourceforge.net/project/typo3/TYPO3%20Source%20and%20Dummy/TYPO3%204.3.3/typo3_src-4.3.3.tar.gz?use_mirror=space

wget http://downloads.sourceforge.net/project/typo3/TYPO3%20Source%20and%20Dummy/TYPO3%204.3.3/typo3_src%2Bdummy-4.3.3.zip?use_mirror=nchc

apt-get install zip
apt-get install imagemagick
unzip typo3+dummy....zip

April 27th

mv typo3_dumm.. yourname
cd prion/typo3conf

admin/adminpass

chown -R www-data:www-data typo3temp/
chown -R www-data:www-data typo3conf
chown -R www-data:www-data uploads
chown -R www-data:www-data fileadmin
chown -R www-data:www-data typo3/ext/

### for suhosin patch for php5
apt-get install php5-suhosin
/etc/init.d/apache2 restart

apt-get install php5-gd

vim /etc/php5/apache2/php.ini
vim /etc/php5/conf.d/suhosin.ini
/etc/init.d/apache2 restart


# not needed below
apt-get install dpkg-dev build-essential
cd /usr/src
apt-get source php5
wget http://www.hardened-php.net/hardened-php-signature-key.asc
gpg --import < hardened-php-signature-key.asc
wget http://www.hardened-php.net/suhosin/_media/suhosin-patch-5.2.0-0.9.6.2.patch.gz
gunzip suhosin-patch-5.2.0-0.9.6.2.patch.gz
cd php5-5.2.0
patch -p 1 -i ../suhosin-patch-5.2.0-0.9.6.2.patch
dpkg-buildpackage
### Till here


May 10th

Generating SSL
http://www.akadia.com/services/ssh_test_certificate.html

openssl genrsa -des3 -out server.key 1024
************

openssl req -new -key server.key -out server.csr


cp server.key server.key.org
cp server.key server.key.orig

openssl rsa -in server.key.org -out server.key

mkdir /etc/apache2/ssl
cp server.crt /etc/apache2/ssl/
cp server.key /etc/apache2/ssl/

a2enmod rewrite
a2enmod ssl

add the following lines in virtual host entry

RewriteEngine on
RewriteCond %{SERVER_PORT} ^80$
RewriteRule ^(.*)$ https://your.domain.com$1 [L,R]
RewriteLog "/var/log/apache2/rewrite.log"
RewriteLogLevel 2

SSLEngine on
SSLCertificateFile /usr/local/apache/conf/ssl.crt/server.crt
SSLCertificateKeyFile /usr/local/apache/conf/ssl.key/server.key

No comments:

Post a Comment