I have created a HttpTrigger using Visual Studio 2017. I can able to debug and able to call the azure function from web browser using below mentioned URL.
localhost:7071/api/Demofunction?name=amit
I have published the Project in a Local Folder in my system. Is it possible to deploy the generated dlls in the Local IIS and call the API from browser? If Yes, then how to do this?
If your primary concern is how to use Azure Functions on premises instead of using azure you can use the Azure Functions Runtime to deploy and run azure functions on premises:
The Azure Functions Runtime provides a new way for you to take advantage of the simplicity and flexibility of the Azure Functions programming model on-premises. Built on the same open source roots as Azure Functions, Azure Functions Runtime is deployed on-premises to provide a nearly identical development experience as the cloud service.
I think you should look to this article:
https://dev.to/gjcampbell/running-azure-functions-in-iis-32a
It seems that you can run .net core V2 Azure Functions on your IIS.
All you have to do is download and install a release (here) from azure-functions GitHub repository (here) and configure your web.config of a pretty empty web site hosted in IIS:
<?xml version="1.0" encoding="utf-8"?>
<configuration>
<system.webServer>
<handlers>
<remove name="aspNetCore" />
<add name="aspNetCore" path="*" verb="*" modules="AspNetCoreModuleV2" resourceType="Unspecified" />
</handlers>
<aspNetCore processPath="C:\hosting\Functions.3.0.14191\3.0.14191\64bit\Microsoft.Azure.WebJobs.Script.WebHost.exe" hostingModel="InProcess">
<environmentVariables>
<environmentVariable name="AzureWebJobsStorage" value="UseDevelopmentStorage=true" />
</environmentVariables>
</aspNetCore>
</system.webServer>
</configuration>
Of course, you will need .NET Core Runtime installed on server as well (download).
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With