Forum Discussion

jhb's avatar
jhb
Copper Contributor
May 15, 2025
Solved

Container App - Dapr - Service Bus

Our app is running as Dapr enabled Container App in an Container Apps Environment using Dapr pubsub component for Service Bus messages. Our Service Bus is on the Standard plan without VNET integration. 
The built in Service Bus Firewall does not support ipv6 it just support ipv4, but the daprd sidecar try to access it over ipv6 and get "connection denied".
I have tried to set DAPR_DISABLE_IPV6=true and DAPR_INET=4 environment variables in my container because Windsurf suggested it, but it does not help.

Is there a way to force ipv4 for Dapr in Container Apps Environment? Or any other solution for our problem? Without setting "allow all networks" or changing to Premium tier for the Service Bus.

  • jhb's avatar
    jhb
    May 16, 2025

    Setting the metadata useIPv4=true did not work. The request did not even reach the Service Bus with this setting.
    So I will go with the routing rule solution.

3 Replies

  • jhb's avatar
    jhb
    Copper Contributor

    So you say I can set this in the dapr components of my containar apps environment? I will try.

    I found another solution too: I update the dapr subnet route table to route all service bus calls through our azure firewall and added our public ip's to the service bus built in firewall. 
    Strange thing is that we do not need to do this for other (non-dapr apps) using the service bus.

  • Service Bus firewall only supports IPv4, but Dapr is defaulting to IPv6, you need a way to force Dapr to use IPv4 explicitly:

     

    metadata:
      - name: useIPv4
        value: "true"

     

    • jhb's avatar
      jhb
      Copper Contributor

      Setting the metadata useIPv4=true did not work. The request did not even reach the Service Bus with this setting.
      So I will go with the routing rule solution.

Resources