How to do it...

Follow these steps:

  1. Create a new custom bridge with the name br0:
       $ docker network create br0 --subnet 192.168.2.1/24
  1. Confirm that the network has been created:
       $ docker network ls

  1. Start a container using the new network and make sure that it is using the correct subnet:
        $ docker container run -d --network br0 --name br0demo redis
$ docker container inspect br0demo

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
18.119.112.7