Archive

Archive for the ‘Linux’ Category

wordpress rewrite for nginx

April 29th, 2010 No comments

Following the my previous post on nginx and php for the search engine friendly URL edit the virtualhost nginx config file and a localtion

server ~/ $ cat /etc/nginx/sites-available/default.conf
server {
        listen   80 default;
        server_name  _;
 
        access_log  /var/log/nginx/localhost.access.log;
 
        server_name_in_redirect  off;
 
        root   /var/www/;
        index  index.php;
 
       location / {
                root   /var/www/;
                index  index.php index.html index.htm;
            if (!-e $request_filename) { # if the file does not exist 
                rewrite  ^/(.*)$  /index.php?q=$1  last;
                break;
            }
 
        }
 
	location ~ \.php$ {
		include /etc/nginx/fastcgi_params;
		fastcgi_param  SCRIPT_FILENAME    $document_root$fastcgi_script_name;
		fastcgi_pass  127.0.0.1:9000;
	}
 
}
Categories: Internet, Linux
Tags: , , ,
1 Star2 Stars3 Stars4 Stars5 Stars (No Ratings Yet)
Loading...

nginx and PHP

April 13th, 2010 No comments

After installing nginx (I will maybe post all steps later). Some basic settings and it is runing. nginx cannot run PHP scripts directly, for this reason you need to use fastcgi.

What do you need for this? 1st the php-cgi installed. To check where it is use

server ~/ : which php-cgi
/usr/bin/php-cgi

Read more…

1 Star2 Stars3 Stars4 Stars5 Stars (No Ratings Yet)
Loading...

nginx

April 1st, 2010 No comments

nginx [engine x] is a HTTP and reverse proxy server, as well as a mail proxy server written by Igor Sysoev. It has been running for more than five years on many heavily loaded Russian sites including Rambler (RamblerMedia.com). According to Netcraft nginx erved or proxied 4.24% busiest sites in January 2010. Here are some of success stories: FastMail.FM, WordPress.com.

I have tried it and it is a must!

1 Star2 Stars3 Stars4 Stars5 Stars (1 votes, average: 5.00 out of 5)
Loading...

xmonad: a tiling window manager

March 13th, 2010 2 comments

Have you ever felt that it is just annoying to use your mouse with a notebook? or that resizing manually windows as you need to see more? If yes Xmonad is for you. It is based on haskell.

It was quite easy to implement and replace metacity under gnome.

It is not so difficult to make it happen. Read more…

1 Star2 Stars3 Stars4 Stars5 Stars (No Ratings Yet)
Loading...

Redmine 0.9.3

February 7th, 2010 No comments

After upgrading couple of new plug-ins are installed.

Here is a basic start up script for gentoo

$!/sbin/runscript
 
depend() {
	need net
}
 
start() {
	ebegin "Starting redmine"
	start-stop-daemon --start --make-pidfile --chuid apache:apache --quiet --name redmine --pidfile /opt/redmine/redmine.pid \
	 --exec /usr/bin/ruby /opt/redmine/script/server webrick -- -e production -d
	eend $?
}
 
 
stop() {
	ebegin "Stopping redmine"
	start-stop-daemon --stop --quiet --pidfile /opt/redmine/redmine.pid
	eend $?
}
1 Star2 Stars3 Stars4 Stars5 Stars (No Ratings Yet)
Loading...