function app does not connect when deployed to a new environment

Matt Elman 20 Reputation points
2025-12-11T22:13:28.55+00:00

We created an Azure Function App and we want to use VNet integration so it can connect to our SQL servers inside its virtual network. 

We successfully created a UAT version of this (using dev resource group, vnet...) and everything works fine.

 

However, when we created a PROD version of the Function App:

  1. Once we enable VNet Integration, the Function App becomes unreachable externally

    The public endpoint immediately returns “Service Unavailable”. 

    Even simple HTTP triggers (e.g., StartSeismicRun) fail to respond.

  1. Disabling VNet Integration, the Function App works, but

    We have to open the SQL port 

    Whitelisting PossibleOutboundIPAddress did not work

  1. UAT version works — Production version does not

    The UAT Function App, running in a different VNet (Fluent_Tech_Development432), works both externally and with SQL.

    When we replicate the same setup in Production, it fails once VNet Integration is enabled.    

Azure Functions
Azure Functions
An Azure service that provides an event-driven serverless compute platform.
{count} votes

1 answer

Sort by: Most helpful
  1. Pravallika KV 4,365 Reputation points Microsoft External Staff Moderator
    2025-12-11T22:37:02.56+00:00

    Hi @Matt Elman ,

    Thanks for reaching out to Microsoft Q&A.

    When you enable VNet Integration, it changes how the Function App handles inbound and outbound traffic. If your Function App becomes unreachable with a "Service Unavailable" error, there are a few areas you could check:

    1. Ensure that your Function App can access the storage account. Access restrictions can prevent the function host from starting. Double-check the connection strings in your app settings.
    2. Since you mentioned that the UAT version works perfectly in its VNet, make sure that the production VNet is set up similarly. Pay attention to any network security group (NSG) rules that might be blocking inbound traffic.
    3. Ensure that your SQL server and external endpoints are accessible from the Function App. You may need to adjust the firewall settings.
    4. If Application Insights is enabled, check the logs for any detailed error messages that could provide insights into the root cause if the issue. This could help identify if it's a code issue or a configuration issue.
    5. Sometimes simply restarting your Function App can help resolve transient issues you might be encountering.

    Hope it helps!


    Please do not forget to click "Accept the answer” and Yes, this can be beneficial to other community members.

    User's image

    If you have any other questions, let me know in the "comments" and I would be happy to help you.

    0 comments No comments

Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.