title: Azure App Service "Server Error in '/' Application"
body: <p>I have a business website that has been running perfectly well on IIS using .NET 4.5, but in Azure it fails.</p>
  
  <p>Now before I lead you too far down this rabbit hole, I can make the IIS fault in the same way as the Azure fault detailed below by NOT converting the website to Application. However, for the life of me I cannot find the equivalent option in Azure; how to convert to Application or equivalent?</p>
  
  <p>I have uploaded to Azure using the Azure App Service Migration Assistant. The only alert was:</p>
  
  <blockquote>
    <p>"IIS7+ Schema Compliance: One or more elements and/or attributes are being used which are not defined in Azure App Service IIS schema. Consider using XDT transforms." </p>
  </blockquote>
  
  <p>This links to <a href="https://docs.microsoft.com/en-nz/azure/app-service/web-sites-configure" rel="nofollow noreferrer">https://docs.microsoft.com/en-nz/azure/app-service/web-sites-configure</a> which indicates various Azure Application Settings, which I have played with to no avail. </p>
  
  <pre><code>Server Error in '/' Application.
  
  Configuration Error 
    Description: An error occurred during the processing of a configuration file required to service this request. Please review the specific error details below and modify your configuration file appropriately. 
  
   Parser Error Message: It is an error to use a section registered as allowDefinition='MachineToApplication' beyond application level.  This error can be caused by a virtual directory not being configured as an application in IIS.
  
  Source Error: 
  
  An application error occurred on the server. The current custom error settings for this application prevent the details of the application error from being viewed remotely (for security reasons). It could, however, be viewed by browsers running on the local server machine.
  
  
   Source File:  D:\home\site\wwwroot\peterfinch\service.desktop\web.config    Line:  143 
  </code></pre>
  
  <p>Can anyone please provide any guidance as to what I am missing? many thanks for your time, Peter Finch</p>