I’m testing a container with my application that use UDP (Bacnet Protocol), I receive broadcast and unicast packets inside the container but when i need to send back a broadcast response packet this doesn’t reach the host. The socket is open on “eth0” and only with bridge driver I can receive properly, host not works.
This is my debug info with the packets received and sent
BIP: Received MPDU-> 172.19.0.2:47808 (25 bytes)
BIP: Sending MPDU-> 172.19.255.255:47808 (25 bytes)
IP host pc 192.168.1.73/24 (static)
IP torizon board 192.168.1.209/24 (static)
it seems like broadcast packets not sent back to the network (192.168.1.xx), when i send unicast packet they is sent back to the host properly, for example using Modbus TCP or Modbus UDP.
this is my docker-compose.yaml
version: “3.9”
services:
sert_c-debug:
build:
context: .
dockerfile: Dockerfile.debug
image: ${LOCAL_REGISTRY}:5002/sert_c-debug:${TAG}
#restart: always
ports:
- 2230:2230
- 502:502
- “900:900/udp”
- “47808:47808/udp”
devices:
- “/dev/gpiochip1:/dev/gpiochip1”
- “/dev/gpiochip4:/dev/gpiochip4”
- “/dev/colibri-uarta:/dev/colibri-uarta”
- “/dev/colibri-uartb:/dev/colibri-uartb”
volumes:
- type: bind
source: /home/torizon/SeRT/bootdbg
target: /home/torizon/app/boot
read_only: false
sert_c:
build:
context: .
dockerfile: Dockerfile
image: ${DOCKER_LOGIN}/sert_c:${TAG}
restart: always
network_mode: bridge
ports:
- 502:502
- “900:900/udp”
- “47808:47808/udp”
devices:
- “/dev/gpiochip1:/dev/gpiochip1”
- “/dev/gpiochip4:/dev/gpiochip4”
- “/dev/colibri-uarta:/dev/colibri-uarta”
- “/dev/colibri-uartb:/dev/colibri-uartb”
volumes:
- type: bind
source: /home/torizon/SeRT/bootrel
target: /home/torizon/app/boot
read_only: false