Question about mosquito addon

I am in the process of upgrading my hassio to a nuc.
On the nuc runs debian with docker.
Installed the clear hassio in a container.
Made a snapshot on the pi and put that in the new hassio in the docker container.
The thing is my pi was on 192.x.x.47.
Mosquitto was also on that address.
The nuc is on 192.x.x.41.
When i restored the snapshot on the nuc, after a restart all my mqtt devices worked.
I dont understand how this works because i am on a different ip.

Could it be that mosquitto was running of the pi?
I did not stopp that instance of hass.

I am asking this to know if i shoul change the ip of the nuc to that of the pi once i stop the pi and keep the nuc running.

Yes. Mosquito will still be running in it’s container.


Thanks, now i know what i need to do.

One other thing. What if i would want to revert back to the pi for whatever reason.
Could i do that the same way by just using a snapshot from the nuc?
I see that addons are in separate containers on the docker install. Will the snapshot from that still work on a plain pi install without docker.

Yes. Addons are in their own containers on the pi too.