I don’t think hooks are going to help you. You’re saying that when you run the web-updater your container disconnects from the docker network?
I’m pretty sure that the web-updater does not restart the container–that’s how it’s able to run without shutting down Discourse.