Wordpress Multisite get an 502

Discussion in 'Installation/Configuration' started by cyprus, Apr 23, 2012.

  1. maumar

    maumar Member

    Hallo Falko

    what i am trying to do is to insert your directives into conf-custom
    Code:
    /usr/local/ispconfig/server/conf-custom/nginx_vhost.conf.master
    
    it's a bad idea, I know, but only admin can use option tab and this is an issue for my customer.

    I have only a problem, now: I need that
    Code:
    include /var/www/<tmpl_var name='domain'>/web/nginx.conf;
    
    is created empty during hosting creation to avoid "file not found" error.

    How can I do it?

    Mit freundlichen Grüßen
    My best regards
     
  2. PermaNoob

    PermaNoob Member

    Can someone give me the specific code which needs to go in the custom nginx directives field to get wordpress to work on Centos 6.4, nginx, ispconfig 3.0.5.3

    I currently have ERROR 500 on wordpress sites
     
  3. Steveorevo

    Steveorevo Member

    I use these nginx directives in the "options" tab. This is to work like typical post name permalink settings one would use with WordPress on Apache...

    # Secure nginx.conf file
    location /nginx.conf {
    deny all;
    }

    # block s2Member log file ***if you use the s2Member plugin
    location ~ /\.log {
    deny all;
    }

    # Include W3TC nginx.conf file ***if you use w3tc cache
    #include /var/www/clients/client1/web1/web/nginx.conf;

    # Support permalinks
    location / {
    try_files $uri $uri/ /index.php?$args;
    }

    rewrite /wp-admin$ $scheme://$host$uri/ permanent;
    location ~* \.(js|css|png|jpg|jpeg|gif|ico)$ {
    expires max;
    log_not_found off;
    }

    rewrite ^/files/(.+) /wp-includes/ms-files.php?file=$1 last;
    location ^~ /files/ {
    rewrite ^.*/files/(.+)$ /wp-includes/ms-files.php?file=$1 last;
    }

    # Rewrite multisite '.../wp-.*' and '.../*.php'.
    if (!-e $request_filename) {
    rewrite ^/[_0-9a-zA-Z-]+(/wp-.*) $1 last;
    rewrite ^/[_0-9a-zA-Z-]+(/.*\.php)$ $1 last;
    }
     
    Last edited: Nov 6, 2013
  4. PermaNoob

    PermaNoob Member

    Thanks! that got it...however...

    After inserting that code from Steveorevo, the wordpress install worked and completed.

    However, even though I deleted the index.html file, the index.php file won't load--not even if I put in site.com/index.php. Other files in the directory will load, and I put in a text file to make sure nginx was directing to the correct directory.

    nvm, now it started working--I guess it just needed time for the conf updates.
     
    Last edited: Nov 6, 2013

Share This Page