There are lots of articles already out there about how to set up a new WordPress blog in Azure, but let me give you a few extra tips here to make sure you’re successful. This post will likely grow and expand as I discover more things that I needed to do to make this blog work right.
- Scale to shared mode, required to have the site use a URL that is not *.azurewebsites.net. This site has an example of how to set up the right CNAME records to get this to work. You’re not sure it’s worth it to pay the ~$10/month to pay for shared mode and host your own domain? Put some skin in the game and use it to hold you responsible for making that investment worth it and create some content. And once you do setup that other domain, add the Multidomain Redirect plugin so that all requests for other domains will get redirected to the one you want to use.
- Modify your site config to allow for uploading of large images. Follow the instructions in this article to create the “.user.ini” file and allow image uploads larger than 2 MB. You can add and configure the WP Smush.it plugin to autoscale the images back down. There, now you just made it that much easier to add images to your site without having to worry about the current image size when uploading or the final image size of the files accessed by users loading your pages.
- Scale back RAM usage wherever your can. Limit PHP memory by creating/editing the php.ini file in the root directory of the site and configuring the memory limit so that the site doesn’t hit the relatively low threshold of 512 MB provided by shared mode. I wouldn’t have to worry about this if I scaled to standard mode, but that’s now about 8x more expensive in Azure hosting expenses and my plans are to hold that back as long as possible.
- Configure an Azure-based service to back up your site. Cloud Cellar Automatic Backup is available for free to do site backups so that the untested plugin that you add doesn’t make your site tank. Sure, you might be able to fix it easily enough, but maybe not.
- Add plugins to lighten the load of your site running in Azure. I added Better WordPress Minify and WP Super Cache to help the site provide content to users faster and using less server resources.