Table of Contents

Docker - Networking - Change the network of a running container

Disconnect the container from the current network

docker network disconnect network-name container-name

Create another network (optional)

docker network create new-network-name

NOTE: The above command will create a new network and connect it to the bridge driver.


Connect the container to the new network

docker network connect --alias set-alias network-name container-name