azure-web-sites

Azure web app redirect http to https

蹲街弑〆低调 提交于 2020-07-05 01:53:22
问题 I use Azure cloud with web app and my server side written on nodejs . When web app receive a http request I want to redirect the request to https I found the solution. I put that to my web.config file inside the rules tag <rule name="Force HTTPS" enabled="true"> <match url="(.*)" ignoreCase="false" /> <conditions> <add input="{HTTPS}" pattern="off" /> </conditions> <action type="Redirect" url="https://{HTTP_HOST}/{R:1}" appendQueryString="false" redirectType="Permanent" /> </rule> The problem

Remove response Server header on Azure Web App from the first redirect request to HTTPS

徘徊边缘 提交于 2020-06-29 04:55:08
问题 I’m trying to remove the response Server header from an Azure Web App ( with an ASP Net core application ) After many tries of changing the web.config and removing the header in app code using a middleware, Microsoft doesn’t give up and set the response header to Server: Microsoft-IIS/10.0 :) The problem appears only when I’m trying to access the server on http (not https). Response code from the server is 301, and this is the only response that has the Server header. Checking the logs I was

Azure AD Securing API - GetAccessTokenForUserAsync not include claims roles

送分小仙女□ 提交于 2020-06-29 04:07:48
问题 I have a web site that calls an API. To call the API from the web site I'm getting first a jwt token using GetAccessTokenForUserAsync(scope). My problem is that this method doesn't retrieve user's roles inside the jwt token. My user.identity.claims has a few roles but they are not include in the jwt token. What I'm missing? I'm to trying to including the roles in the jwt token because I need to secure my api methods. For example, a method can be called only by AdminMember, other method only

Does Azure APIM support GraphQL?

删除回忆录丶 提交于 2020-06-28 04:43:12
问题 We have microservices setup with Azure APIM as gateway and routers to all the services in the back. Is there anyway I can introduce GrpahQl before APIM or within APIM ? 回答1: To answer your immediate question, there is no support for GraphQL via Azure APIM to date. Its one of these feature this has been upvoted by me and many others on Azure uservoice @ GraphQL introspective support within API Management / feedback forums. Also see What additional services should Azure provide? 来源: https:/

Blazor in Azure: The list of component records is not valid

血红的双手。 提交于 2020-06-27 10:22:29
问题 When deploying our blazor app to azure, it fails four out of five times with this error (copied from chrome dev tools): [2019-12-16T11:12:55.214Z] Information: Normalizing '_blazor' to 'https://example.com/_blazor'. [2019-12-16T11:12:55.470Z] Information: WebSocket connected to wss://example-web-signalr-service.service.signalr.net/client/?hub=componenthub&asrs.op=%2F_blazor&negotiateVersion=1&asrs_request_id=...&id=...&access_token=... [2019-12-16T11:12:55.548Z] Error: The list of component

Azure App Service deploy Failed to get resource ID for resource type 'Microsoft.Web/Sites'

早过忘川 提交于 2020-06-27 07:47:31
问题 In the last 6 months I have been releasing with a pipeline in Azure DevOps, but today I receive the following error: 2019-09-25T14:24:38.4296875Z ##[section]Starting: Azure App Service Deploy: AS-ServiciosNegocio-API-UAT 2019-09-25T14:24:38.4419797Z ============================================================================== 2019-09-25T14:24:38.4419900Z Task : Azure App Service deploy 2019-09-25T14:24:38.4419986Z Description : Deploy to Azure App Service a web, mobile, or API app using

SignalR Core not using Websockets in Azure App Service

泪湿孤枕 提交于 2020-06-26 04:29:01
问题 I'm working on a SignalR Core web app that uses the following stack: ASP.NET Core 2.1 preview 2 (2.1.0-preview2-final) SignalR Core 1.0 preview 2 (1.0.0-preview2-final) Microsoft.AspNetCore.Cors (2.1.0-preview2-final) Microsoft.AspNetCore.WebSockets (2.1.0-preview2-final) The client is using SignalR NPM package (@aspnet/signalr). The app is configured like so: public void ConfigureServices(IServiceCollection services) { services.AddCors(options => { options.AddPolicy( "CorsPolicy", builder =>

SignalR Core not using Websockets in Azure App Service

*爱你&永不变心* 提交于 2020-06-26 04:28:24
问题 I'm working on a SignalR Core web app that uses the following stack: ASP.NET Core 2.1 preview 2 (2.1.0-preview2-final) SignalR Core 1.0 preview 2 (1.0.0-preview2-final) Microsoft.AspNetCore.Cors (2.1.0-preview2-final) Microsoft.AspNetCore.WebSockets (2.1.0-preview2-final) The client is using SignalR NPM package (@aspnet/signalr). The app is configured like so: public void ConfigureServices(IServiceCollection services) { services.AddCors(options => { options.AddPolicy( "CorsPolicy", builder =>

Azure Functions Temp storage

梦想的初衷 提交于 2020-06-25 08:11:11
问题 When I try to save a file to the Temp storage in Azure Functions directory ( D:\home\data\temp\response.pdf ), I get the following error. Why can't I write to this directory? mscorlib: Exception has been thrown by the target of an invocation. System: An exception occurred during a WebClient request. mscorlib: ***Could not find a part of the path 'D:\home\data\temp\response.pdf'.*** 2017-09-19T07:05:24.353 Function completed (Failure, Id=3aa4b740-ba8a-465c-ad7c-75b38fa2a472, Duration=334ms)

Configuring custom domain on traffic manager and web app

狂风中的少年 提交于 2020-06-25 06:44:50
问题 I refferred this microsoft doc, but it's confusing as mad. https://docs.microsoft.com/en-us/azure/app-service/web-sites-traffic-manager-custom-domain-name First they explain www.contoso.com will be the CNAME for <myapp>.trafficmanager.net . Then when web apps comes to picture they say www.contoso.com will be the CNAME for web app. They don't explain how both will work. When I will add hostname www.contoso.com to web app it is going to override the CNAME record for traffic manager. So next