Editorial Staff Note: This article is written by >azure Benari, the project manager of the Windows http://www.aliyun.com/zixun/aggregation/13357.html Web site team.
When you manage a Web site in Windows Azure Web site (waws), many options are configurable using the Azure portal, and we often add more options. However, as you may already know, some practical options are available only by directly configuring the Web.config file for the Web site. We are confident that you will be happy to hear the news that we have recently announced and provided some new options in web.config.
If you have been managing your Web site for some time in IIS, you may know that IIS has a complex tiered system for managing configurations. The system has multi-tier configuration files, from the top-level Machine.config and applicationhost.config files to Web sites and even folder-specific web.config files.
In the Windows Azure Web site, we have tried to focus configuration changes only on Web.config files by eliminating the complexity of handling other files in the configuration hierarchy.
With recent updates to the Azure Web site, we now offer developers several new options that have been unlocked for web.config. In the past, these options were locked at the site level, which means that you cannot configure them (if you try, the site will report an error).
For example, a common request from an Azure site customer is a MIME type that can adjust dynamic and static content compression. In the standard default installation of the IIS server, the primary profile ApplicationHost.config file has only text/*, message/*, Application/javascript, Application/atom+xml, and The following configuration of the Application/xaml+xml static MIME type:
This section is also locked on the IIS server, so you cannot properly configure additional MIME types or make additional settings at the site-level Web.config file.
On a stand-alone IIS server, you can easily edit and add settings to the ApplicationHost.config file, or unlock the httpcompression section, and then add configuration options at the site level.
As the Azure Web site changes, we've unlocked that part and some other parts, and now you can define your options in the Web.config file on your site. Because of the subtle changes in the Httpcompression section of the Azure Web site, the syntax has been simplified:
As you can see, you do not need to specify a directory or scenario name, but simply list a static or dynamic type of MIME type.
For other parts that we have unlocked, the syntax is similar to the syntax used for regular IIS Web sites.