» nginx の記事

~ nginx+php No input file specified problem ~

connie 2013.04.14 | centos | | No Comments
nano /etc/nginx/conf.d/default.conf
location ~ \.php$ {
        root           /usr/share/nginx/html;
        fastcgi_pass   127.0.0.1:9000;
        fastcgi_index  index.php;
        fastcgi_param  SCRIPT_FILENAME   $document_root$fastcgi_script_name;
        include        fastcgi_params;
    }

將fastcgi_param 改為

fastcgi_param SCRIPT_FILENAME /var/www/html$fastcgi_script_name;
service nginx restart

完成

yum --enablerepo=remi install php-pecl-apc php-cli php-pear php-pdo php-mysql php-pecl-mongo php-sqlite php-pecl-memcache php-pecl-memcached php-gd php-mbstring php-mcrypt php-xml php-soap 

 

~ nginx Permission notes ~

connie 2013.04.09 | centos | | No Comments
chmod 755 folder

 

~ nginx setting php sock in ubuntu(android) ~

connie 2013.04.08 | ubuntu | | No Comments
nano /etc/php5/fpm/pool.d/www.conf
;listen = 127.0.0.1:9000
listen = /tmp/php5-fpm.sock
listen.owner = www-data //same as nginx user
listen.group = www-data
listen.mode = 0666
nano /etc/nginx/sites-available/default
location ~ \.php$ {
            fastcgi_pass   unix:/tmp/php5-fpm.sock;
            fastcgi_index  index.php;
            fastcgi_param  SCRIPT_FILENAME  /var/www$fastcgi_script_name;
            include        fastcgi_params;
        }

 

| HOME |