Docker volumes backup and restore & Docker networks
Backup and restore docker volumes
Best aricle for volumes backup and restoration
Docker neworks:
- The default network used by docker if we do not specify any option is bridge network
- We can create our own bridge network, Containers on the default bridge network can only access each other by IP addresses, unless you use the --link option, which is considered legacy. On a user-defined bridge network, containers can resolve each other by name or alias.
- We can create bridge network as shown below
If we don't specify any network driver then by default it is bridge and we can define subnet and default gateways by using different flagsf
- we can add container to user defined network 2 ways
- While creating docker container from image using --network or --net flag
2. If a container is already running in default bridge network or any other network,we can add that container to our own network in fly with out stopping container using connect
$docker network connect <container name> <network name>
Comments
Post a Comment