There should not be any changes necessary for the initial install process, or for anything else in the wp-admin area. The only config you need to add for WordPress is to enable non-default permalinks, which don’t affect the install or admin areas.
Have you configured PHP? Or does the PHP not currently run at all on your server?
Thread Starter
vtinq
(@vtinq)
PHP works in most areas. My Nginx.conf root is /var/www. The WordPress install is at /var/www/wordpress. I can do the install with localhost/wordpress/wp-admin/install.php. I can go to the admin page with localhost/wordpress/wp-admin. But when I try to view the site (localhost/wordpress/) or view a post (such as localhost/wordpress/hello-world), I get a blank white page.
I’m not clear on what you mean by the need to enable non-default permalinks. I changed permalinks to numeric, then entered the URL http://localhost/wordpress/archives/1 and Nginx reports “404 Not Found.”
Thread Starter
vtinq
(@vtinq)
Fixed. I forgot I had an index.html file in /var/www/wordpress for testing. I deleted the file, reloaded http://localhost/wordpress/?p=1 and the “Hello World!” post appeared.
For non-default permalinks to work in nginx, you’ll need to add some rules to your conf file. WordPress will auto add rules to an .htaccess for Apache, but nginx can load multiple files from multiple locations, so your specific setup will need to decide where you put the rules.
https://codex.wordpress.org/Nginx#General_WordPress_rules
The main rule needed would be something like this:
location /wordpress {
try_files $uri $uri/ /index.php?$args;
}
This allows it to fallback to the index.php file for non-default rules, so the WordPress system can parse the URL.