You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The current implementation of port forwarding in Kathará encounters an issue when the bridged interface is not the first one on a device. This error is related to a Docker Desktop issue (docker/for-mac#6978) that affects port forwarding functionality.
To address this issue, while waiting for an official Docker fix, we propose a possible workaround that involves starting the device with only the bridged interface initially and then dynamically connecting other interfaces using the vconfig/lconfig command.
In the following you can find a quick example, which starts a device with the apache2 service exposed on port 8080 of the host:
tcaiazzi
changed the title
Port forwarding does not work when the bridged interface is not the first one on a device
Port forwarding does not work when the bridged interface is not the first one on a device (MacOS, Windows)
Aug 24, 2023
Sorry, I only posted the screenshot and I didn't explain the situation a little bit more (and I haven't pushed the changes in the lab's branch, now I did).
But this time I played around this a little bit more and what I didn't understand (until now) was that the katara lconfig -n <container> --add A actually adds a new interface to the container "plugged" to the A network, so in order to use it I had to configure it first (assigning a new IP address within that A network, for example).
Sorry for the mistake. Now I know how to configure my lab, until the underlying bug gets fixed.
The current implementation of port forwarding in Kathará encounters an issue when the bridged interface is not the first one on a device. This error is related to a Docker Desktop issue (docker/for-mac#6978) that affects port forwarding functionality.
To address this issue, while waiting for an official Docker fix, we propose a possible workaround that involves starting the device with only the bridged interface initially and then dynamically connecting other interfaces using the
vconfig/lconfig
command.In the following you can find a quick example, which starts a device with the
apache2
service exposed on port8080
of the host:kathara vstart -n pc1 --bridged --port 8080:80 --image kathara/base --exec "/etc/init.d/apache2 start"
Now, you can attach a new interface using the
vconfig
command:In this way, the port forwarding works and you can attach other interfaces to the device.
The text was updated successfully, but these errors were encountered: