Support

Admin Tools for WordPress

#39095 Is there an NginX configuration maker for Admin Tools Pro for WordPress

Posted in ‘Admin Tools for WordPress’
This is a public ticket

Everybody will be able to see its contents. Do not include usernames, passwords or any other sensitive information.

Environment Information

WordPress version
6.2.2
PHP version
8.0
Admin Tools version
1.6.1

Latest post by mirphi on Wednesday, 14 June 2023 09:05 CDT

mirphi

Is there an NginX configuration maker for Admin Tools Pro for WordPress? I see in documentation that it exists for Joomla. I'd like to deploy it on my WordPress site but can't find it anywhere in the plugin. Thanks!

nicholas
Akeeba Staff
Manager

No, we have not copied the NginX Conf Maker and Web.Config Maker features into the WordPress version of Admin Tools.

WordPress nominally only supports servers which support .htaccess files, i.e. Apache and LiteSpeed (NOT OpenLiteSpeed, though).

Running WordPress with NginX requires doing a LOT of custom editing in the NginX configuration file to not just import the core WordPress directives (this is trivial and we could handle it automatically), but also everything third party plugins put into the .htaccess using WordPress' API. It is not possible to accurately convert these directives into NginX configuration automatically. It requires human intervention.

If we were to create an NginX Conf Maker for WordPress we'd have the problem that users would expect that the software could magically convert any third party plugin's .htaccess code to NginX configuration OR have us do that manually. The former is impossible, the latter is very expensive β€” depending on the third party plugin, it's anywhere between one and 20 hours which have a cost of $50 / hour due to the specialised work necessary. The average site has two to three such plugins. We'd either have to charge so much that nobody would buy the software, or take a loss which would kill the software. So, we decided to not do this at all. Even more so given the fact that by the time we started working on Admin Tools for WordPress there was no good reason for people to use NginX or IIS over Apache.

The old axiom that NginX is far better performing than Apache is outdated and no longer true. It stopped being true circa 2015, when Apache 2.4 finally had the full set of features to be as fast as NginX: a pre-forking MPM, full PHP FastCGI Process Manager (PHP-FPM) support, memory mapping, and native HTTP/2 support. The first two put Apache in the same class of PHP requests throughput as NginX. The latter put Apache in the same class of static files throughput as NginX.

If you want to close the last remaining performance gap, move all your configuration from the .htaccess to the Apache virtual host definition (basically: just include the site's .htaccess file with Include /path/to/your/site/.htaccess) and disable .htaccess files with AllowOverride None in the main Apache configuration:

<Directory />
AllowOverride None
</Directory>

By doing that, Apache will no longer look for .htaccess files through the entire filesystem tree of every file / directory it is asked to serve, and won't have to parse each and every of these files for each and every request (including requests to static files). In other words, you're disabling the filesystem-intensive feature which makes Apache slower, at the expense of having to reload Apache every time you make a configuration change to your site β€” just like you'd have to do with NginX. What you get in return is a server which is just as fast as NginX and, unlike NginX, is fully supported by WordPress and its plugins.

Nicholas K. Dionysopoulos

Lead Developer and Director

πŸ‡¬πŸ‡·Greek: native πŸ‡¬πŸ‡§English: excellent πŸ‡«πŸ‡·French: basic β€’ πŸ• My time zone is Europe / Athens
Please keep in mind my timezone and cultural differences when reading my replies. Thank you!

mirphi

Thank you for an informative and thorough reply. This information will be useful to others researching hosting servers. Our site happens to be hosted with WP Engine, Nginx server. I have come to rely on and recommend Akeeba for all my Joomla and WordPress sites so this is naturally the first place I looked. We'll work with the webhost to ensure site security and proper configuration.