kudu: Cannot deploy to Azure function - Kudu gives 'username or password is incorrect'

Repro steps.

-Function Url is https://tiqsubcriptions.azurewebsites.net.

The log/error given by the failure.

Server Error in ‘/’ Application. The user name or password is incorrect. Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

Exception Details: System.IO.IOException: The user name or password is incorrect.

Source Error:

An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.

Stack Trace:

[IOException: The user name or password is incorrect. ] System.IO.__Error.WinIOError(Int32 errorCode, String maybeFullPath) +12701600 System.IO.Directory.InternalCreateDirectory(String fullPath, String path, Object dirSecurityObj, Boolean checkHost) +12468710 System.IO.Directory.InternalCreateDirectoryHelper(String path, Boolean checkHost) +82 System.IO.Directory.CreateDirectory(String path) +33 System.IO.Abstractions.DirectoryWrapper.CreateDirectory(String path) +11 Kudu.Core.Infrastructure.FileSystemHelpers.CreateDirectory(String path) in C:\Kudu Files\Private\src\master\Kudu.Core\Infrastructure\FileSystemHelpers.cs:32 Kudu.Core.Environment.get_DeploymentToolsPath() in C:\Kudu Files\Private\src\master\Kudu.Core\Environment.cs:183 Kudu.Core.Infrastructure.PathUtilityBase.GetPathFolders(IEnvironment environment) in C:\Kudu Files\Private\src\master\Kudu.Core\Infrastructure\PathUtils\PathUtilityBase.cs:23 Kudu.Services.Web.App_Start.NinjectServices.PrependFoldersToPath(IEnvironment environment) in C:\Kudu Files\Private\src\master\Kudu.Services.Web\App_Start\NinjectServices.cs:758 Kudu.Services.Web.App_Start.NinjectServices.RegisterServices(IKernel kernel) in C:\Kudu Files\Private\src\master\Kudu.Services.Web\App_Start\NinjectServices.cs:152 Kudu.Services.Web.App_Start.NinjectServices.CreateKernel() in C:\Kudu Files\Private\src\master\Kudu.Services.Web\App_Start\NinjectServices.cs:129 Ninject.Web.Common.Bootstrapper.Initialize(Func`1 createKernelCallback) +16 Kudu.Services.Web.App_Start.NinjectServices.Start() in C:\Kudu Files\Private\src\master\Kudu.Services.Web\App_Start\NinjectServices.cs:95

[TargetInvocationException: Exception has been thrown by the target of an invocation.] System.RuntimeMethodHandle.InvokeMethod(Object target, Object[] arguments, Signature sig, Boolean constructor) +0 System.Reflection.RuntimeMethodInfo.UnsafeInvokeInternal(Object obj, Object[] parameters, Object[] arguments) +79 System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture) +101 WebActivatorEx.BaseActivationMethodAttribute.InvokeMethod() +73 WebActivatorEx.ActivationManager.RunActivationMethods(Boolean designerMode) +637 WebActivatorEx.ActivationManager.Run() +84

[InvalidOperationException: The pre-application start initialization method Run on type WebActivatorEx.ActivationManager threw an exception with the following error message: Exception has been thrown by the target of an invocation…] System.Web.Compilation.BuildManager.InvokePreStartInitMethodsCore(ICollection1 methods, Func1 setHostingEnvironmentCultures) +615 System.Web.Compilation.BuildManager.InvokePreStartInitMethods(ICollection`1 methods) +141 System.Web.Compilation.BuildManager.CallPreStartInitMethods(String preStartInitListPath, Boolean& isRefAssemblyLoaded) +102 System.Web.Compilation.BuildManager.ExecutePreAppStart() +157 System.Web.Hosting.HostingEnvironment.Initialize(ApplicationManager appManager, IApplicationHost appHost, IConfigMapPathFactory configMapPathFactory, HostingEnvironmentParameters hostingParameters, PolicyLevel policyLevel, Exception appDomainCreationException) +549

[HttpException (0x80004005): The pre-application start initialization method Run on type WebActivatorEx.ActivationManager threw an exception with the following error message: Exception has been thrown by the target of an invocation…] System.Web.HttpRuntime.FirstRequestInit(HttpContext context) +10043436 System.Web.HttpRuntime.EnsureFirstRequestInit(HttpContext context) +95 System.Web.HttpRuntime.ProcessRequestNotificationPrivate(IIS7WorkerRequest wr, HttpContext context) +254

Mention any other details that might be useful.

I tried to deploy from Visual Studio 2017 today and got the “username or password is incorrect” error. The only thing I did relative to the previous successful deployment (24 hours ago) was add a new function to the project.

About this issue

  • Original URL
  • State: closed
  • Created 6 years ago
  • Comments: 16 (7 by maintainers)

Most upvoted comments

Most likely unrelated to Kudu. Check that your WEBSITE_CONTENTAZUREFILECONNECTIONSTRING has a valid storage connection string.