Microsoft Azure Open Source Development Support Team Blog

Support for Open Source Technologies on Microsoft Azure App Service

RewriteRule sample for WordPress in subdirectory

In the case you installed another instance of WordPress in a subdirectory of main WordPress site in Azure web app for Windows, your WordPress installation may be like this,   if use “Post name” Permalink setting, with default web.config, articles in subdirectory might give 404 (not found), for example,   For this problem, you can… Read more

Configure WordPress Database Connection on Azure App Services

Configure WordPress Database Connection on Azure App Services For WordPress sites hosted on Azure App Services, there are two ways to configure database connection in wp-config.php. When you modify database connection for WordPress, verify the connection from wp-config.php. 1. Current WordPress installed on Azure App Services pull database connection information from hosting environment- code in… Read more

HTTP to HTTPS redirect for WordPress on Azure Web App on Linux

If you host WordPress site on Azure Web App on Linux running Apache, here are the steps to implement HTTP to HTTPS redirect: 1. Add RewriteRule in .htaccess in WordPress application root RewriteCond %{HTTP:X-ARR-SSL} ^$ RewriteRule ^(.*)$ https://%{HTTP_HOST}%{REQUEST_URI} [L,R=301] 2. Once this RewriteRule is added, you may see wp-admin page lost style like this, this… Read more

First steps with Bitnami WordPress in Azure VM

If you choose Bitnami WordPress VM from Azure Market, you need to take the following considerations: 1.- Review the username & password for WordPress Application in the installation step. For example, the username is “user”   The password will be shown in the Boot Diagnostics the first time after creating the VM, you need to… Read more

Best Practices for WordPress Security on Azure

This article was put together by Mangesh Sangapu and Yi Wang. Shout-out to Cory Fowler and Sunitha Muthukrishna for additional tips. WordPress Security is often an overlooked feature. Customers are quick to configure their site, but often forget to fine tune the security aspect. Here we have compiled steps that will help make your WordPress site… Read more

WordPress: Redirecting to wrong URL!!

Problem: While trying to browse to, it keeps redirecting to!!   Redirection Scenarios There are a couple situations where one may face the WordPress Redirection issue: Migrated from another host Changed your custom domain name and it’s going to your old domain!   Understanding The Issue This redirection can occur for two reasons: URL… Read more

WordPress MultiSite 404 on Admin Dashboard

If you are experiencing a 404 when switching to the dashboard of a given site, verify the web.config is accurate. We’ve found that older versions of WordPress have incorrect rules within web.config. Try the following web.config: <?xml version=”1.0″ encoding=”UTF-8″?> <configuration> <system.webServer> <rewrite> <rules> <rule name=”WordPress Rule 1″ stopProcessing=”true”> <match url=”^index\.php$” ignoreCase=”false” /> <action type=”None” />… Read more

Media Files – HTTP 404 – Azure Web Apps

You’ve uploaded a media file to your WordPress site and attempt to access the files URL but receive a HTTP 404 error.  You check to make sure that the file is in the correct directly but the error continues to be displayed.  This can occur if the type of file you are attempting to access… Read more

Uploading Large Files to Azure Web Apps

Attempting to upload a file larger than 28.6MB to Azure Web Apps can result in a HTTP 404.13 for WordPress developers or a HTTP 502 for Tomcat Manager. This can be due to the default Request Limits value for the maxAllowedContentLength on IIS which is 30000000 (roughly 28.6MB). To modify this value, add the following… Read more

Enable WordPress Error Logs

Logs can help identify slowness, HTTP 500 Fatal Errors,  WordPress “white screen of death” and other issues your Azure App Service Web App may be experiencing. To enable error logging in WordPress, you will have to make both of the following changes.  Quick Instructions   .user.ini Within wwwroot directory, create a file named .user.ini Add the following… Read more