Serving a file with no extension from an Azure Web App

Guillermo Rodriguez 0 Reputation points

I'm trying to serve a text file that has no extension from within a Web App.

The file is located in the .well-known folder. Other files (with json extension) from the .well-known folder are accessible, but when I try to access the file with no extension, the app redirects to the home page.

I modified the web.config and added support for 2 mime types with no positive results.

The content of the web.config as it is now is listed below:

?xml version="1.0" encoding="utf-8"?>
  <location path="." inheritInChildApplications="false">
        <add name="aspNetCore" path="*" verb="*" modules="AspNetCoreModuleV2" resourceType="Unspecified" />
      <aspNetCore processPath="dotnet" arguments=".\Slp.Web.dll" stdoutLogEnabled="false" stdoutLogFile=".\logs\stdout" hostingModel="inprocess" />
          <mimeMap fileExtension=".json" mimeType="application/json" />
          <mimeMap fileExtension="." mimeType="application/json" />
Azure Static Web Apps
Azure Static Web Apps
An Azure service that provides streamlined full-stack web app development.
628 questions
{count} votes