You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Oct 12, 2023. It is now read-only.
After i added your function, my azure Functions now fail to deploy.
If the deployment succeeds with a warning message, the httpTriger function is not accessible.
The authentication structure of azure functin seems to have changed recently, but does it require changes to your function?
var BearerStrategy = require("passport-azure-ad").BearerStrategy;
// Modify the below three lines to suit your environment
var tenantID = "*******";
var clientID = "*******";
var appIdURI = "https://supportersystem-demo1-makedataactivity2.peerconnect-supporters-assoc.onmicrosoft.com"; // "https://funcapi.<tenantname>.onmicrosoft.com";
var options = {
identityMetadata: "https://login.microsoftonline.com/" + tenantID + "/v2.0/.well-known/openid-configuration",
clientID: clientID,
issuer: "https://sts.windows.net/" + tenantID + "/",
audience: appIdURI,
loggingLevel: "info",
passReqToCallback: false
};
var bearerStrategy = new BearerStrategy(options, function (token, done) {
done(null, {}, token);
});
const app = express();
app.use(require('morgan')('combined'));
app.use(require('body-parser').urlencoded({ "extended": true }));
app.use(passport.initialize());
passport.use(bearerStrategy);
console.log("bearerStrategy=",bearerStrategy)
console.log("passport=",passport)
// This is where your API methods are exposed
app.get(
"/api",
passport.authenticate("oauth-bearer", { session: false }),
function (req, res) {
var claims = req.authInfo;
console.log("Validated claims: ", JSON.stringify(claims));
console.log("body text: ", JSON.stringify(req.body));
res.status(200).json(claims);
}
);
module.exports = createHandler(app);
App Details
Durable Functions extension version (e.g. v1.8.3): "durable-functions@1.3.3
Azure Functions runtime version (1.0 or 2.0): 2.0
Programming language used: JavaScript(TypeScript)
Screenshots
2020-05-28T05:11:12.6985773Z ##[section]Starting: Azure Functions App Deploy: SupporterSystem-Demo1-MakeDataActivity2
2020-05-28T05:11:12.7001052Z ==============================================================================
2020-05-28T05:11:12.7001415Z Task : Azure Functions
2020-05-28T05:11:12.7001818Z Description : Update a function app with .NET, Python, JavaScript, PowerShell, Java based web applications
2020-05-28T05:11:12.7002157Z Version : 1.163.6
2020-05-28T05:11:12.7002405Z Author : Microsoft Corporation
2020-05-28T05:11:12.7002746Z Help : https://aka.ms/azurefunctiontroubleshooting
2020-05-28T05:11:12.7003097Z ==============================================================================
2020-05-28T05:11:13.5832003Z Got service connection details for Azure App Service:'SupporterSystem-Demo1-MakeDataActivity2'
2020-05-28T05:11:14.7794326Z Trying to update App Service Application settings. Data: {"WEBSITES_ENABLE_APP_SERVICE_STORAGE":"true"}
2020-05-28T05:11:14.8905263Z App Service Application settings are already present.
2020-05-28T05:11:18.5887069Z Package deployment using ZIP Deploy initiated.
2020-05-28T05:12:49.8929289Z ##[error]Failed to deploy web package to App Service.
2020-05-28T05:12:49.8944063Z ##[error]To debug further please check Kudu stack trace URL : https://$SupporterSystem-Demo1-MakeDataActivity2:***@supportersystem-demo1-makedataactivity2.scm.azurewebsites.net/api/vfs/LogFiles/kudu/trace
2020-05-28T05:12:49.8951592Z ##[error]Error: Error: Failed to deploy web package to App Service. Conflict (CODE: 409)
2020-05-28T05:12:53.2965845Z Successfully added release annotation to the Application Insight : supportersystemdemo1AppInsight2
2020-05-28T05:12:56.6738878Z ##[warning]Error: Failed to update deployment history. Error: Bad Request (CODE: 400)
2020-05-28T05:12:57.3543087Z App Service Application URL: http://supportersystem-demo1-makedataactivity2.azurewebsites.net
2020-05-28T05:12:57.3715391Z ##[section]Finishing: Azure Functions App Deploy: SupporterSystem-Demo1-MakeDataActivity2
**** Build extensions**
2020-05-28T05:08:54.5132930Z ##[section]Starting: Build extensions
2020-05-28T05:08:54.5137883Z ==============================================================================
2020-05-28T05:08:54.5138206Z Task : Command line
2020-05-28T05:08:54.5138445Z Description : Run a command line script using Bash on Linux and macOS and cmd.exe on Windows
2020-05-28T05:08:54.5138678Z Version : 2.164.1
2020-05-28T05:08:54.5138868Z Author : Microsoft Corporation
2020-05-28T05:08:54.5139117Z Help : https://docs.microsoft.com/azure/devops/pipelines/tasks/utility/command-line
2020-05-28T05:08:54.5139402Z ==============================================================================
2020-05-28T05:08:54.6451454Z Generating script.
2020-05-28T05:08:54.6466679Z ========================== Starting Command Output ===========================
2020-05-28T05:08:54.6490680Z [command]/bin/bash --noprofile --norc /home/vsts/work/_temp/05d9e0e6-095b-40fa-9ad1-1baa4ba4ae1c.sh
2020-05-28T05:08:58.6534722Z
2020-05-28T05:08:58.7030318Z Welcome to .NET Core 3.1!
2020-05-28T05:08:58.7033316Z ---------------------
2020-05-28T05:08:58.7034862Z SDK Version: 3.1.202
2020-05-28T05:08:58.7036402Z
2020-05-28T05:08:58.7037521Z Telemetry
2020-05-28T05:08:58.7040438Z ---------
2020-05-28T05:08:58.7041773Z The .NET Core tools collect usage data in order to help us improve your experience. The data is anonymous. It is collected by Microsoft and shared with the community. You can opt-out of telemetry by setting the DOTNET_CLI_TELEMETRY_OPTOUT environment variable to '1' or 'true' using your favorite shell.
2020-05-28T05:08:58.7042559Z
2020-05-28T05:08:58.7043443Z Read more about .NET Core CLI Tools telemetry: https://aka.ms/dotnet-cli-telemetry
2020-05-28T05:08:58.7043998Z
2020-05-28T05:08:58.7044746Z ----------------
2020-05-28T05:08:58.7045467Z Explore documentation: https://aka.ms/dotnet-docs
2020-05-28T05:08:58.7046042Z Report issues and find source on GitHub: https://github.com/dotnet/core
2020-05-28T05:08:58.7046764Z Find out what's new: https://aka.ms/dotnet-whats-new
2020-05-28T05:08:58.7047545Z Learn about the installed HTTPS developer cert: https://aka.ms/aspnet-core-https
2020-05-28T05:08:58.7048406Z Use 'dotnet --help' to see available commands or visit: https://aka.ms/dotnet-cli-docs
2020-05-28T05:08:58.7049145Z Write your first app: https://aka.ms/first-net-core-app
2020-05-28T05:08:58.7049778Z --------------------------------------------------------------------------------------
2020-05-28T05:09:00.5519969Z Microsoft (R) Build Engine version 16.5.0+d4cbfca49 for .NET Core
2020-05-28T05:09:00.5525395Z Copyright (C) Microsoft Corporation. All rights reserved.
2020-05-28T05:09:00.5526196Z
2020-05-28T05:09:43.3458825Z /home/vsts/work/1/s/extensions.csproj : warning NU1605: Detected package downgrade: System.Net.NameResolution from 4.3.0 to 4.0.0. Reference the package directly from the project to select a different version.
2020-05-28T05:09:43.3463099Z /home/vsts/work/1/s/extensions.csproj : warning NU1605: extensions -> Microsoft.Azure.WebJobs.Extensions.CosmosDB 3.0.7 -> Microsoft.Azure.DocumentDB.Core 2.9.2 -> System.Net.NetworkInformation 4.1.0 -> System.Net.Sockets 4.1.0 -> runtime.unix.System.Net.Sockets 4.3.0 -> System.Net.NameResolution (>= 4.3.0)
2020-05-28T05:09:43.3469092Z /home/vsts/work/1/s/extensions.csproj : warning NU1605: extensions -> Microsoft.Azure.WebJobs.Extensions.CosmosDB 3.0.7 -> Microsoft.Azure.DocumentDB.Core 2.9.2 -> System.Net.NameResolution (>= 4.0.0)
2020-05-28T05:09:43.4294086Z Restore completed in 36.61 sec for /home/vsts/work/1/s/extensions.csproj.
2020-05-28T05:09:43.6709008Z /home/vsts/work/1/s/extensions.csproj : warning NU1605: Detected package downgrade: System.Net.NameResolution from 4.3.0 to 4.0.0. Reference the package directly from the project to select a different version.
2020-05-28T05:09:43.6720845Z /home/vsts/work/1/s/extensions.csproj : warning NU1605: extensions -> Microsoft.Azure.WebJobs.Extensions.CosmosDB 3.0.7 -> Microsoft.Azure.DocumentDB.Core 2.9.2 -> System.Net.NetworkInformation 4.1.0 -> System.Net.Sockets 4.1.0 -> runtime.unix.System.Net.Sockets 4.3.0 -> System.Net.NameResolution (>= 4.3.0)
2020-05-28T05:09:43.6722725Z /home/vsts/work/1/s/extensions.csproj : warning NU1605: extensions -> Microsoft.Azure.WebJobs.Extensions.CosmosDB 3.0.7 -> Microsoft.Azure.DocumentDB.Core 2.9.2 -> System.Net.NameResolution (>= 4.0.0)
2020-05-28T05:09:50.6981055Z extensions -> /home/vsts/work/1/s/bin/extensions.dll
2020-05-28T05:09:54.6433416Z
2020-05-28T05:09:54.6434314Z Build succeeded.
2020-05-28T05:09:54.6434666Z
2020-05-28T05:09:54.6435502Z /home/vsts/work/1/s/extensions.csproj : warning NU1605: Detected package downgrade: System.Net.NameResolution from 4.3.0 to 4.0.0. Reference the package directly from the project to select a different version.
2020-05-28T05:09:54.6437780Z /home/vsts/work/1/s/extensions.csproj : warning NU1605: extensions -> Microsoft.Azure.WebJobs.Extensions.CosmosDB 3.0.7 -> Microsoft.Azure.DocumentDB.Core 2.9.2 -> System.Net.NetworkInformation 4.1.0 -> System.Net.Sockets 4.1.0 -> runtime.unix.System.Net.Sockets 4.3.0 -> System.Net.NameResolution (>= 4.3.0)
2020-05-28T05:09:54.6439202Z /home/vsts/work/1/s/extensions.csproj : warning NU1605: extensions -> Microsoft.Azure.WebJobs.Extensions.CosmosDB 3.0.7 -> Microsoft.Azure.DocumentDB.Core 2.9.2 -> System.Net.NameResolution (>= 4.0.0)
2020-05-28T05:09:54.6440394Z /home/vsts/work/1/s/extensions.csproj : warning NU1605: Detected package downgrade: System.Net.NameResolution from 4.3.0 to 4.0.0. Reference the package directly from the project to select a different version.
2020-05-28T05:09:54.6441909Z /home/vsts/work/1/s/extensions.csproj : warning NU1605: extensions -> Microsoft.Azure.WebJobs.Extensions.CosmosDB 3.0.7 -> Microsoft.Azure.DocumentDB.Core 2.9.2 -> System.Net.NetworkInformation 4.1.0 -> System.Net.Sockets 4.1.0 -> runtime.unix.System.Net.Sockets 4.3.0 -> System.Net.NameResolution (>= 4.3.0)
2020-05-28T05:09:54.6442973Z /home/vsts/work/1/s/extensions.csproj : warning NU1605: extensions -> Microsoft.Azure.WebJobs.Extensions.CosmosDB 3.0.7 -> Microsoft.Azure.DocumentDB.Core 2.9.2 -> System.Net.NameResolution (>= 4.0.0)
2020-05-28T05:09:54.6443620Z 2 Warning(s)
2020-05-28T05:09:54.6443845Z 0 Error(s)
2020-05-28T05:09:54.6443950Z
2020-05-28T05:09:54.6444096Z Time Elapsed 00:00:53.65
2020-05-28T05:09:54.6677818Z
2020-05-28T05:09:54.6750005Z ##[section]Finishing: Build extensions
_* Failed to load 'api/WebApps_getResourceKeys1' GET._**
_ ERROR MESSAGE at EDGE brouser._**
See Atached Figuare.
Request Id: 5a384ded-7cfc-43d5-8ed7-b869bd724900
Correlation Id: a9a2ddf4-9060-426d-b1b2-88442fc013e5
Timestamp: 2020-05-28T06:09:39Z
Message: AADSTS50011: The reply URL specified in the request does not match the reply URLs configured for the application: '4549e42e-a05f-4276-82f9-7d6bab6995c2'.
*** cnfiguared reply url
The text was updated successfully, but these errors were encountered:
The sample had a major revision and update and so this issue may not be relevant anymore. Please consider taking a look at the revised sample and if you run into any issues, feel free to post again.
Description
After i added your function, my azure Functions now fail to deploy.
If the deployment succeeds with a warning message, the httpTriger function is not accessible.
The authentication structure of azure functin seems to have changed recently, but does it require changes to your function?
Relevant source code snippets
**** /extensions.csproj**
_ /host.json_**
_ index.ts_**
App Details
Durable Functions extension version (e.g. v1.8.3): "durable-functions@1.3.3
Azure Functions runtime version (1.0 or 2.0): 2.0
Programming language used: JavaScript(TypeScript)
Screenshots
**** Build extensions**
_* Failed to load 'api/WebApps_getResourceKeys1' GET._**
_ ERROR MESSAGE at EDGE brouser._**
See Atached Figuare.
*** cnfiguared reply url
The text was updated successfully, but these errors were encountered: