Note that there are some explanatory texts on larger screens.

plurals
  1. POwordpress site in subdomain on nginx
    primarykey
    data
    text
    <p>I'm having trouble setting up a subdomain with nginx and some wordpress sites.</p> <p>My www.jackalopegames.com domain is working, but I want to set up dev.jackalopegames.com.</p> <p>Here's the config file in my sites-enabled folder:</p> <pre><code>server { listen 80; server_name jackalopegames.com www.jackalopegames.com; include /etc/nginx/fastcgi_php; root /var/sitefolder; index index.php; } server { listen 80; server_name dev.jackalopegames.com; include /etc/nginx/fastcgi_php; root /var/devfolder; index index.php; } </code></pre> <p>The first one <code>server_name jackalopegames.com</code> works, but the second one doesn't. I've looked around a bunch and I'm at a loss as to why this isn't working. Any tips would be appreciated!</p> <p><b>Update:</b></p> <p>I've added the following to my subdomain <code>server {...}</code> with no effect:</p> <pre><code>location / { root /var/dev; index index.php; rewrite ^.*/files/(.*)$ /wp-includes/ms-files.php?file=$1 last; if (!-e $request_filename) { rewrite ^.+/?(/wp-.*) $1 last; rewrite ^.+/?(/.*\.php)$ $1 last; rewrite ^(.+)$ /index.php?q=$1 last; } } location ~* ^.+\.(html|jpg|jpeg|gif|png|ico|css|zip|tgz|gz|rar|bz2|doc|xls|exe|pdf|ppt|txt|tar|mid|midi|wav|bmp|rtf|js)$ { root /var/dev; rewrite ^/.*(/wp-.*/.*\.(html|jpg|jpeg|gif|png|ico|css|zip|tgz|gz|rar|bz2|doc|xls|exe|pdf|ppt|txt|tar|mid|midi|wav|bmp|rtf|js))$ $1 last; rewrite ^.*/files/(.*(html|jpg|jpeg|gif|png|ico|css|zip|tgz|gz|rar|bz2|doc|xls|exe|pdf|ppt|txt|tar|mid|midi|wav|bmp|rtf|js))$/wp-includes/ms-files.php?file=$1 last; expires 30d; break; } location ~ wp\-.*\.php|wp\-admin|\.php$ { include /etc/nginx/fastcgi_params; fastcgi_pass 127.0.0.1:9000; fastcgi_index index.php; fastcgi_param SCRIPT_FILENAME /var/dev$fastcgi_script_name; } } </code></pre>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload