I have Gallery3 working with Nginx. Here’s my setup and some configuration for http://gallery.techish.net/ I no longer am using Gallery3 or nginx. (7/21/2012)
- Nginx 1.0.11
- PHP 5.3.3-7
- PHP5 GD Graphics Library
- Gallery 3.0.2
Nginx virtual host configuration:
server { server_name gallery.techish.net; root /var/www/gallery.techish.net; include /etc/nginx/fastcgi_php; location / { fastcgi_index index.php; fastcgi_split_path_info ^(.+.php)(.*)$; fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name; fastcgi_param PATH_INFO $fastcgi_path_info; include fastcgi_params; index index.php; if (-f $request_filename) { expires max; break; } if (!-e $request_filename) { rewrite ^/(.+)$ /index.php?kohana_uri=$1 last; } } }
I also had to modify Gallery3’s configuration (/application/config/config.php):
$config["index_page"] = "";
Much of the tips came from: http://codex.gallery2.org/Gallery3:Using_NGINX