Share via

Open a incoming Port in Azure App Service (for OPC UA Server)

Jonas 20 Reputation points
2023-12-12T12:08:28.15+00:00

Hello everyone,

we've hosted a ASP.NET Core 8 Web API in Azure App Service. The App is already up and running and it works as expected. Now we've added a OPC UA Server to our Backend. Locally this OPC UA Server works. To access this Server on the App Service we need a further open incoming Port (preferred Port would be 4840 but any but 80 and 443 possible).

The plan is to be able to access this OPC UA Server via opc.tcp://xy.azurewebsites.net:4840

Unfortunately, I was not able to find any help for this at my researches.

So my question is, is it even possible to open a further incoming Port on a App Service?

If yes, where can I find this settings and what do I need to set up?

Thanks in advance.

Kind Regards

Jonas

Azure App Service
Azure App Service

Azure App Service is a service used to create and deploy scalable, mission-critical web apps.

0 comments No comments

Answer accepted by question author
  1. Bryan Trach 17,842 Reputation points Microsoft Employee Moderator
    2023-12-15T03:18:41.6933333+00:00

    @Jonas Azure App Service (multi-tenant) only allows incoming traffic on ports 80 and 443 for HTTP and HTTPS traffic respectively.

    You can use Azure App Service Containers and expose the port you want though as a workaround. By default, App Service assumes your custom container is listening on port 80. If your container listens to a different port, set the WEBSITES_PORT app setting in your App Service app. (Only for container apps)

    https://learn.microsoft.com/en-us/azure/app-service/configure-custom-container?pivots=container-linux&tabs=debian#configure-port-number

    0 comments No comments

0 additional answers

Sort by: Most helpful

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.