I choose Windows and IIS as my platform. Nothing at all wrong with Linux and Apache or Nginx. I’ve worked with both Linux and Windows over the years and believe that Linux has some of the best advantages as a web platform however, for my preference (and relatively simple use-case), I find a few things are easier in IIS (especially if you’re a Windows engineer): Managing p12 certificates being one.
There are many how-to’s and other documentation out there for WordPress on IIS but most are outdated (IIS 7) or suggest using the IIS Web Platform installer for integrating WordPress. I found it much easier to keep it simple. For anyone interested, here are the components and steps necessary to setup a fast and functional WordPress environment:
Getting the Prererequisites:
- Windows Server 2016 0r 2019 (IIS 10)
- IIS Web Platform Installer, WebPI v5.0 (x64) – for the basics – here
- DAC Framework – here
- Microsoft Visual C++ 2015-2019 Redistributable v14.28.29325 (x64) – here
- PHP Manager for IIS v1.5.0 – here
- PHP v7.4.15 – Non-Thread safe (x64) – here
- PHP imagick v3.4.4-7.4 Non-Thread safe (x64) – here
- MySQL community edition (x64) v8.0.22 (latest version of 8 should work too) – here
- And of course, WordPress 5.6.2 – here
Install Everything:
- Add IIS to your server
- Open Powershell as an Admin and run the following command:
Install-WindowsFeature -name Web-Server -IncludeManagementTools
- Install WebPI, IIS Web Platform Installer
- Install DAC Framework
- Install Microsoft Visual C++ 2015-2019 Redistributable
- Install PHP Manager for IIS
- Install PHP v7.4.15
- Install PHP imagick
- Extract from
php_imagick.zip
thephp_imagick.dll
file, and save it to theext
directory of your PHP installation - Extract from
ImageMagick-….zip
the DLL files located in thebin
folder that start withCORE_RL
orIM_MOD_RL
, and save them to the PHP root directory (where you havephp.exe
), or to a directory in yourPATH
variable - Add this line to your
php.ini
file: extension=php_imagick.dll
- Extract from
8. Install MySQL community edition
Install the MySQL server, Workbench, and Connector/NET. I like to have the MySQL Shell also.
Open the Workbench app and connect to the local SQL server using the credentials you added from the install.
Click the icon in the toolbar for creating a new schema.
Enter the schema name. ‘WordPress’ works nicely. Leave the other settings as default and apply the settings and close.
Configure MySQL:
At the end of the install you’ll be asked to make a couple of base configuration decisions.
Setup your Website and SSL Cert:
I’m not going to go into the steps for this at the moment as there are some variables and considerations which impact this step; specifically Firewall/ reverse web proxy. I’ll write more about it later.
Working….