View Single Post
  #4  
Old 15th April 2013, 19:49
nackgr nackgr is offline
Member
 
Join Date: Nov 2012
Posts: 31
Thanks: 4
Thanked 0 Times in 0 Posts
Default

i changed to that


now when i click site url goes to

http://e-byte.gr/index.php/install/

but gets

500 Internal Server Error
nginx/1.0.15


thats my php

http://e-byte.gr/php.php


Code:
server {
    listen 80;
    server_name www.e-byte.gr;
    root /var/www/e-byte.gr/web;

    ## allow for html source of super high volume product pages to be put in "static" directory and served without php
    if ($http_host ~ "^(.*)e-byte.gr"){
        set $rule_0 1;
    }
    if ($uri ~ "^(.*)$"){
        set $rule_0 2$rule_0;
    }
    if ($http_referer !~* ".*e-byte.gr"){
        set $rule_0 3$rule_0;
    }
    if (-f $document_root/static$request_uri){
        set $rule_0 4$rule_0;
    }
    if ($rule_0 = "4321"){
        rewrite ^/.*$ /static/$request_uri last;
    }

    ## Images and static content is treated different
    location ~* ^.+.(jpg|jpeg|gif|css|png|js|ico)$ {
            access_log        off;
            expires           30d;
            root /var/www/e-byte.gr/web/;
    }

    location / {
        index index.html index.php; ## Allow a static html file to be shown first
        try_files $uri $uri/ @handler; ## If missing pass the URI to Magento's front handler
        expires 30d; ## Assume all files are cachable
    }

    ## These locations would be hidden by .htaccess normally
    location /app/                { deny all; }
    location /includes/           { deny all; }
    location /lib/                { deny all; }
    location /media/downloadable/ { deny all; }
    location /pkginfo/            { deny all; }
    location /report/config.xml   { deny all; }
    location /var/                { deny all; }
    location /nginx-config/       { deny all; }

    location  /. { ## Disable .htaccess and other hidden files
        return 404;
    }

    location @handler { ## Magento uses a common front handler
        rewrite / /index.php;
    }

    location ~ .php/ { ## Forward paths like /js/index.php/x.js to relevant handler
        rewrite ^(.*.php)/ $1 last;
    }

    location ~ .php$ { ## Execute PHP scripts
        if (!-e $request_filename) { rewrite / /index.php last; } ## Catch 404s that try_files miss

        expires        off; ## Do not cache dynamic content
        fastcgi_pass   127.0.0.1:9035;
        fastcgi_buffer_size 128k;
        fastcgi_buffers 4 256k;
        fastcgi_busy_buffers_size 256k;
        fastcgi_read_timeout 120;
fastcgi_param  MAGE_RUN_CODE default;
fastcgi_param  MAGE_RUN_TYPE store;
        fastcgi_param  SCRIPT_FILENAME  $document_root$fastcgi_script_name;
    

        include        fastcgi_params; ## See /etc/nginx/fastcgi_params
    }

  access_log /var/log/nginx/e-byte.gr-access_log combined;
}

Last edited by nackgr; 15th April 2013 at 19:59.
Reply With Quote