azure-web-sites

Azure App Service - write to filesystem - ASP.NET web application

天涯浪子 提交于 2019-12-11 12:09:13
问题 I have an ASP.NET web application, created in Visual Studio 2017. In the application there is a form, where the users can upload files. When files are uploaded, I process them and I save them on the filesystem: var photo = Request.Files["file"]; photo.SaveAs("D:\\home"); Everything works perfect locally, but it's not working when I deploy the App on Azure App Services. I read that, on Azure, the path D:\home should be writable. But when I try the code I get this error: Access to the path 'd:

Azure file storage/indexing solution

浪尽此生 提交于 2019-12-11 11:56:57
问题 I'm developing a Web Application, and it is running as an Azure Web App. This application has a section in which a user can navigate a directory, and allows the user to open the files and browse sub-directories in said directory. At the moment, the sub-directories and files are inside "~/Content/Documents" , and I am browsing the directory's by using Directory.GetFiles() and Directory.GetDirectories() ; functions which are provided by System.IO . The files in question would be retrieved and

How can I use the TFS Online <--> Azure Website integration when there are two web apps in the solution

余生长醉 提交于 2019-12-11 11:46:23
问题 I am trying to get continuous integration configured using Azure. The process I have followed is exactly as detailed by Continuous delivery to Windows Azure using Visual Studio Online This process works perfectly! I check-in, it builds, and deploys to the Azure website. However, as soon as I add a second web application to the solution, after the CI build kicks off and then completes, the only thing that gets published to the website is the bin directory of the second web application!

Facebook, Google OAuth fails sometimes on Azure

主宰稳场 提交于 2019-12-11 11:45:36
问题 I am using Asp.Net MVC OAuth login with facebook and google and strange thing that at some period it doesnot work var externalIdentity = HttpContext.GetOwinContext() .Authentication.GetExternalIdentityAsync(DefaultAuthenticationTypes.ExternalCookie); var loginInfo = await AuthenticationManager.GetExternalLoginInfoAsync(); if (loginInfo == null) { return RedirectToAction("Login"); } Seems here it cant get user info and redirect to login page. I cant figure out why or what can cause that. I

Promote Azure Website using Azure Active Directory from staging environment

只愿长相守 提交于 2019-12-11 11:23:56
问题 I have an azure-website authenticated with Azure Active Directory, and my goal is to deploy to a staging slot, which is then promoted to the production environment. However when I deploy to the staging slot it is being treated as a separate application in my Azure AD. When I promote the environment the Reply URL in Azure AD application stays the same, so that my production site is now being redirected back to the staging slot after logging in. It would help if I could configure the

Connect internally to a Virtual Machine with SQL Server from Web Sites using Windows Azure

夙愿已清 提交于 2019-12-11 11:09:48
问题 I am using Windows Azure Web Sites to host my web application and also have a Windows Azure Virtual Machine with SQL Server on it. I would like to connect internally from Windows Azure Web Sites to my Virtual Machine, but using the supplied internal IP address of my Virtual Machine is not working. Is it possible to connect internally from Web Sites to a Virtual Machine? If so, how can I accomplish this? Thanks. 回答1: Nope! The only way to internally connect that different resources is via

Azure Mobile Services and Azure Web Site integration

拈花ヽ惹草 提交于 2019-12-11 10:44:32
问题 I am hosting a REST endpoint using the ASP.NET Web.Api in a Windows Azure web site. I want to allow authenticated access to this api from mobile devices. The Azure mobile services seems to have easy authentication providers as well as other goodies such as push notifications. What would be an effective strategy for using the two in tandem, the web sites to host the REST endpoint and the mobile services to do authentication and push notifications? 回答1: Before you think about anything ahead,

Azure WebSites doesn't return response body for errors

旧街凉风 提交于 2019-12-11 10:27:42
问题 I have the following configuration: Python TornadoWeb application deployed on Azure Web Sites. The application is actually REST API that returns JSON back. However... everything works fine if the response code is 200 but if the response code is anything like 50x or 40x the response doesn't contain any body (although there should still be JSON body with error details). Testing the same code locally directly to Tornado or via NGiNX works. Apparently, IIS filters the body but not really sure

Azure websites complaining Role environment . FAILED TO INITIALIZE

痴心易碎 提交于 2019-12-11 10:06:56
问题 I'm having headaches with Azure website deployment at the moment, someone help please - it has taken me 2 days trying to figure out what exactly has gone wrong: The website is ASP.NET MVC using Azure Storage for storing web pages (custom VirtualPathProvider is implemented) It works perfectly on my local PC however once I deploy it to Azure website, it hangs forever - and when checking the diagnoiss (XXX.scm.azurewebsites.net) there are full loads of errors complaining "Role environment .

Azure Deploy [error]Process 'appcmd.exe' exited with code '4312'

南笙酒味 提交于 2019-12-11 09:36:29
问题 I am trying to do deploy on azure vm but getting below error in the log. Any help will be appreciated. 2019-02-25T14:02:55.2630391Z ##[section]Starting: Manage IISWebsite 2019-02-25T14:02:55.2638264Z ============================================================================== 2019-02-25T14:02:55.2638352Z Task : IIS Web App Manage 2019-02-25T14:02:55.2638426Z Description : Create or update a Website, Web App, Virtual Directories, and Application Pool 2019-02-25T14:02:55.2638480Z Version : 0