diff --git a/README.md b/README.md index 50b9b8d..2b12179 100644 --- a/README.md +++ b/README.md @@ -25,8 +25,9 @@ This project is part of ASP.NET vNext. You can find samples, documentation and g * Try `k kestrel` to run the application **NOTE: On Mono since SQL client is not available the sample uses an InMemoryStore to run the application. So the changes that you make will not be persisted. -###NTLM authentication & Environment based Startup detection -TODO +###NTLM authentication +More information at src/MusicStore/StartupNtlmAuthentication.cs +**NOTE: Ntlm authentication works only on desktop CLR right now. ### Note: 1. Application is started on different ports on different hosts. To change the port or URL modify ```Helios.cmd``` or project.json commands section in case of self-host and customhost. \ No newline at end of file diff --git a/src/MusicStore/Mocks/Readme.md b/src/MusicStore/Mocks/Readme.md index 53632c2..c8ef0bd 100644 --- a/src/MusicStore/Mocks/Readme.md +++ b/src/MusicStore/Mocks/Readme.md @@ -1 +1 @@ -Only for testing purposes. Not needed for production deployments. \ No newline at end of file +# Mock code added only for testing purposes. Not to be used for production deployments. \ No newline at end of file diff --git a/src/MusicStore/MusicStore.kproj b/src/MusicStore/MusicStore.kproj index 41d8c8b..0d73b2c 100644 --- a/src/MusicStore/MusicStore.kproj +++ b/src/MusicStore/MusicStore.kproj @@ -21,7 +21,6 @@ - diff --git a/src/MusicStore/StartupNtlmAuthentication.cs b/src/MusicStore/StartupNtlmAuthentication.cs index 5fa10aa..dab06ea 100644 --- a/src/MusicStore/StartupNtlmAuthentication.cs +++ b/src/MusicStore/StartupNtlmAuthentication.cs @@ -68,20 +68,9 @@ namespace MusicStore app.UseServices(services => { - //If this type is present - we're on mono - var runningOnMono = Type.GetType("Mono.Runtime") != null; - // Add EF services to the services container - if (runningOnMono) - { - services.AddEntityFramework() - .AddInMemoryStore(); - } - else - { - services.AddEntityFramework() - .AddSqlServer(); - } + services.AddEntityFramework() + .AddSqlServer(); services.AddScoped(); @@ -90,14 +79,7 @@ namespace MusicStore { options.DefaultAdminUserName = configuration.Get("DefaultAdminUsername"); options.DefaultAdminPassword = configuration.Get("DefaultAdminPassword"); - if (runningOnMono) - { - options.UseInMemoryStore(); - } - else - { - options.UseSqlServer(configuration.Get("Data:DefaultConnection:ConnectionString")); - } + options.UseSqlServer(configuration.Get("Data:DefaultConnection:ConnectionString")); }); // Add Identity services to the services container @@ -143,4 +125,4 @@ namespace MusicStore SampleData.InitializeMusicStoreDatabaseAsync(app.ApplicationServices).Wait(); } } -} +} \ No newline at end of file