Best Practice- Hosting WordPress sites in Azure App Services

MVP

Hi guys,

 

I have multiple WordPress websites, each of them represent different organizations of a parent organization. As of now, each of these websites are hosted in separate App Service Plans and similarly have separate Azure Database for MySQL. 

 

Over the last 1 year, I have realized that the cost of hosting is coming out to be higher than expected and planning to optimize the utilization. Could someone suggest what could be the best approach to optimize the usage? 

 

Thanks for your advice in advance.

3 Replies

@Pradeep Kandel  have you seen this post?

 

https://wordpress.org/support/topic/multi-site-wordpress-site-in-1-single-azure-web-app/

 

I haven't tried it yet, but will give it a try.

 

Thx and good luck! Please post back here if this solves your problem.

 

James

If the WordPress sites are owned by different organisations, I would keep them on separate WebApps, in separate resource groups.

If you combine multiple WordPress instances into the same App Service Plan, the performance of one companies site may affect another companies site (it also depends on how you may charge these companies), but it is an option if you want to save on cost and are comfortable.

* If it's a very light website you could look at WordPress, using the inbuilt SQL DB vs separate MySQL DB.
* Another option is a CDN, put something like Azure CDN or Cloudflare in front of the WebApp, to cache the website, images etc and you may find you can scale down the size of the WebApps, spending time on optimising the cache, CDN can save a lot of hassle and money in the long run.

I'm all for Azure, but a hypothetical question I feel I need to ask is - is it the right hosting platform for the website? If you have websites that don't get changed that often if at all, then maybe GitHub pages, for static sites might be a better (a lot cheaper) option than maintaining WordPress.

Hi, this is a very good question.

Azure deployment wizard are currently pretty dump, and even when deploying of the same Resource Group, Azure will deploy for each WP site:
- a new dedicated app service plan
- a new dedicated virtual network
- a new dedicated app service
- a new dedicated private zone
- a new dedicated MySQL server

The admin should stay in control, and currently it's now really the case, because Azure deployment wizard for Wordpress does not ask you the good questions about how do you want to deploy a new WP site on a given Resource Group where some existing WP infra could already be there.

WP Multi-site is another question.

I would suggest two things:
A) the WP deployment wizard should provide a way to use (at least in an existing Resource Group) existing WP infra (App service plan, MySQL server, private zone, ....) if they exist
B) for already deployed WP on App service, Azure portal should provide a way to "transform" your deployment like a refactoring. e.g. moving an app service with WP from one App service plan to another one in the same Resource Group, moving a MySQL DB from one MySQL server to another one, ...

Do you see others use cases ?