Quantcast
Channel: ASP.NET Core
Viewing all articles
Browse latest Browse all 9386

ASP.NET CORE 2.0 StaticFiles Options (.well-known)

$
0
0

Dear Sirs.

My code in ASP.NET CORE 1.1 was 

          app.UseStaticFiles();

          app.UseStaticFiles(new StaticFileOptions()

            { 

                FileProvider = new PhysicalFileProvider(

                                    Path.Combine(Directory.GetCurrentDirectory(), @".well-known")),

                RequestPath = new PathString("/.well-known"),

                ServeUnknownFileTypes = true

            });

Does not work in ASP.NET CORE 2.0 (in Azure).

2017-09-25 08:35:48.628 +00:00 [Critical] Microsoft.AspNetCore.Hosting.Internal.WebHost: Application startup exception System.ArgumentException: The directory name D:\home\site\wwwroot\.well-known\ is invalid.

But It work well OK local IIS Express.

What is should do ?

Thank you in advance.

 

 


Viewing all articles
Browse latest Browse all 9386

Trending Articles