Replies: 5 comments 2 replies
-
Hi @ptr727 - I had a go at running a container on a macvlan network, with a specified IP address, updated using watchtower... but the IP address was preserved properly, so I didn't manage to reproduce the problem. (I tried with latest docker, and 25.0.0.) I enabled docker's debug logging - as described at https://docs.docker.com/config/daemon/logs/#enable-debugging ... then, when watchtower re-created the container I saw log lines for "Calling POST" - creating the container, then to disconnect and connect the networks, and finally to start the container. The "form data" log lines following the create and connect POSTs specified the container's old IP addresses (as expected). It might be worth you trying the same thing. Maybe there will be a clue about some docker misbehaviour, or at-least some more info for the watchtower folks. (If you're using docker 25.0.0, it might be worth updating to 25.0.1. The long list of "Aliases" for the container on your "localnet" network looks odd, and there were fixes in that area in 25.0.1. But, as these are user-defined networks, probably not directly related and I didn't see extra Aliases in my attempt to repro with 25.0.0.) |
Beta Was this translation helpful? Give feedback.
-
I retested with 25.0.2, recreated all containers, updated with watchtower, and it seems to work again, I wonder if it may have been due to duplicate MAC's fixed in .2? Wil re-engage if I see it happening again. |
Beta Was this translation helpful? Give feedback.
-
Hi @ptr727 - another user hit this problem and managed to get hold of the debug logs. So, I understand the issue now ... it's a combination of the way Watchtower uses docker's API, and a change to the way a preferred MAC address is configured in Docker/moby 25.x. It's being tracked here ... #47441 (comment) |
Beta Was this translation helpful? Give feedback.
-
Thank you! |
Beta Was this translation helpful? Give feedback.
-
I logged this bug and asked in the docker community forum, got no traction, asking here for guidance.
Since v25 containers that get updated / recreated by watchtower uses the wrong static IP's, it looks like the macvlan section is missing in the config, and the container uses the wrong static IP, causing conflicts.
I've seen a few network related fixes, and a mac fix still not released, is this possibly related?
Beta Was this translation helpful? Give feedback.
All reactions