Я развернул сайт с github.com/VirtoCommerce/vc-storefront-core в своей учетной записи Azure, но при переходе на сайт магазина появляется следующая ошибка:
Произошла ошибка при запуске приложения.
.NET Core 4.6.26212.01 X86 v4.0.0.0 | Microsoft.AspNetCore.Hosting версия 2.0.0-rtm-26452 | Microsoft Windows 10.0.14393 | Нужна помощь?
Я подтвердил, что строка подключения к контенту верна, идентификатор приложения и секретный ключ.
Если посмотреть на поток журналов в Azure, это ошибка 500.0, и ссылка, которую он дает для возможных ошибок / решений, на статью поддержки Microsoft
который не предоставляет никакой информации Azure.
Я включил ведение журнала через консоль Kudu, и выдается исключение
`Application startup exception: System.NullReferenceException: Object reference not set to an instance of an object.
at VirtoCommerce.Storefront.Extensions.HostingEnviromentExtension.MapPath(IHostingEnvironment hostEnv, String path) in D:\home\site\repository\VirtoCommerce.Storefront\Extensions\HostingEnviromentExtension.cs:line 12
at VirtoCommerce.Storefront.Startup.<>c__DisplayClass7_0.<ConfigureServices>b__5(FileSystemBlobContentOptions options) in D:\home\site\repository\VirtoCommerce.Storefront\Startup.cs:line 134
at Microsoft.Extensions.Options.ConfigureNamedOptions``1.Configure(String name, TOptions options)
at Microsoft.Extensions.Options.OptionsFactory``1.Create(String name)
at Microsoft.Extensions.Options.OptionsManager``1.<>c__DisplayClass5_0.<Get>b__0()
at System.Lazy``1.ViaFactory(LazyThreadSafetyMode mode)
at System.Lazy``1.ExecutionAndPublication(LazyHelper executionAndPublication, Boolean useDefaultConstructor)
at System.Lazy``1.CreateValue()
at System.Lazy``1.get_Value()
at Microsoft.Extensions.Options.OptionsCache``1.GetOrAdd(String name, Func``1 createOptions)
at Microsoft.Extensions.Options.OptionsManager``1.Get(String name)
at Microsoft.Extensions.Options.OptionsManager``1.get_Value()
at VirtoCommerce.Storefront.Domain.FileSystemContentBlobProvider..ctor(IOptions``1 options, IMemoryCache memoryCache) in D:\home\site\repository\VirtoCommerce.Storefront\Domain\ContentBlobProviders\FileSystemContentBlobProvider.cs:line 25
--- End of stack trace from previous location where exception was thrown ---
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at Microsoft.Extensions.DependencyInjection.ServiceLookup.CallSiteRuntimeResolver.VisitConstructor(ConstructorCallSite constructorCallSite, ServiceProvider provider)
at Microsoft.Extensions.DependencyInjection.ServiceLookup.CallSiteVisitor``2.VisitCallSite(IServiceCallSite callSite, TArgument argument)
at Microsoft.Extensions.DependencyInjection.ServiceLookup.CallSiteRuntimeResolver.VisitScoped(ScopedCallSite scopedCallSite, ServiceProvider provider)
at Microsoft.Extensions.DependencyInjection.ServiceLookup.CallSiteRuntimeResolver.VisitSingleton(SingletonCallSite singletonCallSite, ServiceProvider provider)
at Microsoft.Extensions.DependencyInjection.ServiceLookup.CallSiteVisitor``2.VisitCallSite(IServiceCallSite callSite, TArgument argument)
at Microsoft.Extensions.DependencyInjection.ServiceLookup.CallSiteRuntimeResolver.VisitConstructor(ConstructorCallSite constructorCallSite, ServiceProvider provider)
at Microsoft.Extensions.DependencyInjection.ServiceLookup.CallSiteVisitor``2.VisitCallSite(IServiceCallSite callSite, TArgument argument)
at Microsoft.Extensions.DependencyInjection.ServiceLookup.CallSiteRuntimeResolver.VisitScoped(ScopedCallSite scopedCallSite, ServiceProvider provider)
at Microsoft.Extensions.DependencyInjection.ServiceLookup.CallSiteRuntimeResolver.VisitSingleton(SingletonCallSite singletonCallSite, ServiceProvider provider)
at Microsoft.Extensions.DependencyInjection.ServiceLookup.CallSiteVisitor``2.VisitCallSite(IServiceCallSite callSite, TArgument argument)
at Microsoft.Extensions.DependencyInjection.ServiceProvider.<>c__DisplayClass22_0.<RealizeService>b__0(ServiceProvider provider)
at Microsoft.Extensions.DependencyInjection.ServiceProvider.GetService(Type serviceType)
at Microsoft.Extensions.Internal.ActivatorUtilities.ConstructorMatcher.CreateInstance(IServiceProvider provider)
at Microsoft.Extensions.Internal.ActivatorUtilities.CreateInstance(IServiceProvider provider, Type instanceType, Object[] parameters)
at Microsoft.AspNetCore.Builder.UseMiddlewareExtensions.<>c__DisplayClass4_0.<UseMiddleware>b__0(RequestDelegate next)
at Microsoft.AspNetCore.Builder.Internal.ApplicationBuilder.Build()
at Microsoft.AspNetCore.Hosting.Internal.WebHost.BuildApplication()
crit: Microsoft.AspNetCore.Hosting.Internal.WebHost[6]'